]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit
USB: serial: kobil_sct: fix modem-status error handling
authorJohan Hovold <johan@kernel.org>
Wed, 4 Jul 2018 15:02:18 +0000 (17:02 +0200)
committerJuerg Haefliger <juergh@canonical.com>
Wed, 24 Jul 2019 01:50:38 +0000 (19:50 -0600)
commit606cd7ee411868af14e677229520828a566a50b5
treeed7a08d31010449677c7d443173b7deb47e20b42
parent2726fb8242d76d5335059594a6b609bad5ee998c
USB: serial: kobil_sct: fix modem-status error handling

BugLink: https://bugs.launchpad.net/bugs/1836287
[ Upstream commit a420b5d939ee58f1d950f0ea782834056520aeaa ]

Make sure to return -EIO in case of a short modem-status read request.

While at it, split the debug message to not include the (zeroed)
transfer-buffer content in case of errors.

Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Khalid Elmously <khalid.elmously@canonical.com>
drivers/usb/serial/kobil_sct.c