diff options
Diffstat (limited to 'drivers/usb/serial/pl2303.c')
-rw-r--r-- | drivers/usb/serial/pl2303.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/drivers/usb/serial/pl2303.c b/drivers/usb/serial/pl2303.c index e02dc3d643c7..ec6c132a25b5 100644 --- a/drivers/usb/serial/pl2303.c +++ b/drivers/usb/serial/pl2303.c | |||
@@ -878,7 +878,7 @@ static void pl2303_break_ctl(struct tty_struct *tty, int break_state) | |||
878 | dbg("%s - error sending break = %d", __func__, result); | 878 | dbg("%s - error sending break = %d", __func__, result); |
879 | } | 879 | } |
880 | 880 | ||
881 | static void pl2303_shutdown(struct usb_serial *serial) | 881 | static void pl2303_release(struct usb_serial *serial) |
882 | { | 882 | { |
883 | int i; | 883 | int i; |
884 | struct pl2303_private *priv; | 884 | struct pl2303_private *priv; |
@@ -890,7 +890,6 @@ static void pl2303_shutdown(struct usb_serial *serial) | |||
890 | if (priv) { | 890 | if (priv) { |
891 | pl2303_buf_free(priv->buf); | 891 | pl2303_buf_free(priv->buf); |
892 | kfree(priv); | 892 | kfree(priv); |
893 | usb_set_serial_port_data(serial->port[i], NULL); | ||
894 | } | 893 | } |
895 | } | 894 | } |
896 | } | 895 | } |
@@ -927,6 +926,8 @@ static void pl2303_update_line_status(struct usb_serial_port *port, | |||
927 | spin_lock_irqsave(&priv->lock, flags); | 926 | spin_lock_irqsave(&priv->lock, flags); |
928 | priv->line_status = data[status_idx]; | 927 | priv->line_status = data[status_idx]; |
929 | spin_unlock_irqrestore(&priv->lock, flags); | 928 | spin_unlock_irqrestore(&priv->lock, flags); |
929 | if (priv->line_status & UART_BREAK_ERROR) | ||
930 | usb_serial_handle_break(port); | ||
930 | wake_up_interruptible(&priv->delta_msr_wait); | 931 | wake_up_interruptible(&priv->delta_msr_wait); |
931 | } | 932 | } |
932 | 933 | ||
@@ -1037,7 +1038,8 @@ static void pl2303_read_bulk_callback(struct urb *urb) | |||
1037 | if (line_status & UART_OVERRUN_ERROR) | 1038 | if (line_status & UART_OVERRUN_ERROR) |
1038 | tty_insert_flip_char(tty, 0, TTY_OVERRUN); | 1039 | tty_insert_flip_char(tty, 0, TTY_OVERRUN); |
1039 | for (i = 0; i < urb->actual_length; ++i) | 1040 | for (i = 0; i < urb->actual_length; ++i) |
1040 | tty_insert_flip_char(tty, data[i], tty_flag); | 1041 | if (!usb_serial_handle_sysrq_char(port, data[i])) |
1042 | tty_insert_flip_char(tty, data[i], tty_flag); | ||
1041 | tty_flip_buffer_push(tty); | 1043 | tty_flip_buffer_push(tty); |
1042 | } | 1044 | } |
1043 | tty_kref_put(tty); | 1045 | tty_kref_put(tty); |
@@ -1120,7 +1122,7 @@ static struct usb_serial_driver pl2303_device = { | |||
1120 | .write_room = pl2303_write_room, | 1122 | .write_room = pl2303_write_room, |
1121 | .chars_in_buffer = pl2303_chars_in_buffer, | 1123 | .chars_in_buffer = pl2303_chars_in_buffer, |
1122 | .attach = pl2303_startup, | 1124 | .attach = pl2303_startup, |
1123 | .shutdown = pl2303_shutdown, | 1125 | .release = pl2303_release, |
1124 | }; | 1126 | }; |
1125 | 1127 | ||
1126 | static int __init pl2303_init(void) | 1128 | static int __init pl2303_init(void) |