aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/serial/ftdi_sio.c
diff options
context:
space:
mode:
authorAlan Cox <alan@linux.intel.com>2009-07-09 08:36:22 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2009-07-10 22:17:22 -0400
commit24a15a62dcb1968bf4ffdae55c88fa934d971180 (patch)
tree39a2231da07c6a47a4b66baf0158591a9739ac8f /drivers/usb/serial/ftdi_sio.c
parent4cd1de0afaaa45309f34d7282ea4c07d9b56a3ff (diff)
tty: Fix USB kref leak
The sysrq code acquired a kref leak. Fix it by passing the tty separately from the caller (thus effectively using the callers kref which all the callers hold anyway) Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/usb/serial/ftdi_sio.c')
-rw-r--r--drivers/usb/serial/ftdi_sio.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/usb/serial/ftdi_sio.c b/drivers/usb/serial/ftdi_sio.c
index 3dc3768ca71c..5f08702f672f 100644
--- a/drivers/usb/serial/ftdi_sio.c
+++ b/drivers/usb/serial/ftdi_sio.c
@@ -2121,7 +2121,7 @@ static void ftdi_process_read(struct work_struct *work)
2121 /* Note that the error flag is duplicated for 2121 /* Note that the error flag is duplicated for
2122 every character received since we don't know 2122 every character received since we don't know
2123 which character it applied to */ 2123 which character it applied to */
2124 if (!usb_serial_handle_sysrq_char(port, 2124 if (!usb_serial_handle_sysrq_char(tty, port,
2125 data[packet_offset + i])) 2125 data[packet_offset + i]))
2126 tty_insert_flip_char(tty, 2126 tty_insert_flip_char(tty,
2127 data[packet_offset + i], 2127 data[packet_offset + i],