diff options
Diffstat (limited to 'drivers/usb')
-rw-r--r-- | drivers/usb/serial/ftdi_sio.c | 2 | ||||
-rw-r--r-- | drivers/usb/serial/generic.c | 10 | ||||
-rw-r--r-- | drivers/usb/serial/pl2303.c | 2 | ||||
-rw-r--r-- | drivers/usb/serial/ssu100.c | 2 |
4 files changed, 7 insertions, 9 deletions
diff --git a/drivers/usb/serial/ftdi_sio.c b/drivers/usb/serial/ftdi_sio.c index 63ddb2f65cee..c792c96f590e 100644 --- a/drivers/usb/serial/ftdi_sio.c +++ b/drivers/usb/serial/ftdi_sio.c | |||
@@ -1834,7 +1834,7 @@ static int ftdi_process_packet(struct tty_struct *tty, | |||
1834 | 1834 | ||
1835 | if (port->port.console && port->sysrq) { | 1835 | if (port->port.console && port->sysrq) { |
1836 | for (i = 0; i < len; i++, ch++) { | 1836 | for (i = 0; i < len; i++, ch++) { |
1837 | if (!usb_serial_handle_sysrq_char(tty, port, *ch)) | 1837 | if (!usb_serial_handle_sysrq_char(port, *ch)) |
1838 | tty_insert_flip_char(tty, *ch, flag); | 1838 | tty_insert_flip_char(tty, *ch, flag); |
1839 | } | 1839 | } |
1840 | } else { | 1840 | } else { |
diff --git a/drivers/usb/serial/generic.c b/drivers/usb/serial/generic.c index 0b1a13384c6d..e6833e216fc9 100644 --- a/drivers/usb/serial/generic.c +++ b/drivers/usb/serial/generic.c | |||
@@ -343,7 +343,7 @@ void usb_serial_generic_process_read_urb(struct urb *urb) | |||
343 | tty_insert_flip_string(tty, ch, urb->actual_length); | 343 | tty_insert_flip_string(tty, ch, urb->actual_length); |
344 | else { | 344 | else { |
345 | for (i = 0; i < urb->actual_length; i++, ch++) { | 345 | for (i = 0; i < urb->actual_length; i++, ch++) { |
346 | if (!usb_serial_handle_sysrq_char(tty, port, *ch)) | 346 | if (!usb_serial_handle_sysrq_char(port, *ch)) |
347 | tty_insert_flip_char(tty, *ch, TTY_NORMAL); | 347 | tty_insert_flip_char(tty, *ch, TTY_NORMAL); |
348 | } | 348 | } |
349 | } | 349 | } |
@@ -448,12 +448,11 @@ void usb_serial_generic_unthrottle(struct tty_struct *tty) | |||
448 | EXPORT_SYMBOL_GPL(usb_serial_generic_unthrottle); | 448 | EXPORT_SYMBOL_GPL(usb_serial_generic_unthrottle); |
449 | 449 | ||
450 | #ifdef CONFIG_MAGIC_SYSRQ | 450 | #ifdef CONFIG_MAGIC_SYSRQ |
451 | int usb_serial_handle_sysrq_char(struct tty_struct *tty, | 451 | int usb_serial_handle_sysrq_char(struct usb_serial_port *port, unsigned int ch) |
452 | struct usb_serial_port *port, unsigned int ch) | ||
453 | { | 452 | { |
454 | if (port->sysrq && port->port.console) { | 453 | if (port->sysrq && port->port.console) { |
455 | if (ch && time_before(jiffies, port->sysrq)) { | 454 | if (ch && time_before(jiffies, port->sysrq)) { |
456 | handle_sysrq(ch, tty); | 455 | handle_sysrq(ch); |
457 | port->sysrq = 0; | 456 | port->sysrq = 0; |
458 | return 1; | 457 | return 1; |
459 | } | 458 | } |
@@ -462,8 +461,7 @@ int usb_serial_handle_sysrq_char(struct tty_struct *tty, | |||
462 | return 0; | 461 | return 0; |
463 | } | 462 | } |
464 | #else | 463 | #else |
465 | int usb_serial_handle_sysrq_char(struct tty_struct *tty, | 464 | int usb_serial_handle_sysrq_char(struct usb_serial_port *port, unsigned int ch) |
466 | struct usb_serial_port *port, unsigned int ch) | ||
467 | { | 465 | { |
468 | return 0; | 466 | return 0; |
469 | } | 467 | } |
diff --git a/drivers/usb/serial/pl2303.c b/drivers/usb/serial/pl2303.c index c98f0fb675ba..8ae4c6cbc38a 100644 --- a/drivers/usb/serial/pl2303.c +++ b/drivers/usb/serial/pl2303.c | |||
@@ -789,7 +789,7 @@ static void pl2303_process_read_urb(struct urb *urb) | |||
789 | 789 | ||
790 | if (port->port.console && port->sysrq) { | 790 | if (port->port.console && port->sysrq) { |
791 | for (i = 0; i < urb->actual_length; ++i) | 791 | for (i = 0; i < urb->actual_length; ++i) |
792 | if (!usb_serial_handle_sysrq_char(tty, port, data[i])) | 792 | if (!usb_serial_handle_sysrq_char(port, data[i])) |
793 | tty_insert_flip_char(tty, data[i], tty_flag); | 793 | tty_insert_flip_char(tty, data[i], tty_flag); |
794 | } else { | 794 | } else { |
795 | tty_insert_flip_string_fixed_flag(tty, data, tty_flag, | 795 | tty_insert_flip_string_fixed_flag(tty, data, tty_flag, |
diff --git a/drivers/usb/serial/ssu100.c b/drivers/usb/serial/ssu100.c index 660c31f14999..68c18fdfc6da 100644 --- a/drivers/usb/serial/ssu100.c +++ b/drivers/usb/serial/ssu100.c | |||
@@ -672,7 +672,7 @@ static int ssu100_process_packet(struct tty_struct *tty, | |||
672 | 672 | ||
673 | if (port->port.console && port->sysrq) { | 673 | if (port->port.console && port->sysrq) { |
674 | for (i = 0; i < len; i++, ch++) { | 674 | for (i = 0; i < len; i++, ch++) { |
675 | if (!usb_serial_handle_sysrq_char(tty, port, *ch)) | 675 | if (!usb_serial_handle_sysrq_char(port, *ch)) |
676 | tty_insert_flip_char(tty, *ch, flag); | 676 | tty_insert_flip_char(tty, *ch, flag); |
677 | } | 677 | } |
678 | } else | 678 | } else |