diff options
author | Jia-Ju Bai <baijiaju1990@gmail.com> | 2017-12-13 15:34:36 +0300 |
---|---|---|
committer | Johan Hovold <johan@kernel.org> | 2017-12-14 12:32:29 +0300 |
commit | c7b8f77872c73f69a16528a9eb87afefcccdc18b (patch) | |
tree | 47b57fee74339dea998441d99908b57aa17b25df /drivers/usb/serial/ark3116.c | |
parent | d8a42b1ff8a3755cc710785c7e4b5e59636399ca (diff) | |
download | linux-c7b8f77872c73f69a16528a9eb87afefcccdc18b.tar.xz |
USB: serial: io_edgeport: fix possible sleep-in-atomic
According to drivers/usb/serial/io_edgeport.c, the driver may sleep
under a spinlock.
The function call path is:
edge_bulk_in_callback (acquire the spinlock)
process_rcvd_data
process_rcvd_status
change_port_settings
send_iosp_ext_cmd
write_cmd_usb
usb_kill_urb --> may sleep
To fix it, the redundant usb_kill_urb() is removed from the error path
after usb_submit_urb() fails.
This possible bug is found by my static analysis tool (DSAC) and checked
by my code review.
Signed-off-by: Jia-Ju Bai <baijiaju1990@gmail.com>
Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Johan Hovold <johan@kernel.org>
Diffstat (limited to 'drivers/usb/serial/ark3116.c')
0 files changed, 0 insertions, 0 deletions