usb-serial: Use tty_port version console instead of usb_serial_port
Replace all instances of using the console variable in struct usb_serial_port with the struct tty_port version. CC: Alan Cox <alan@linux.intel.com> CC: Alan Stern <stern@rowland.harvard.edu> CC: Oliver Neukum <oliver@neukum.org> CC: Andrew Morton <akpm@linux-foundation.org> CC: linux-usb@vger.kernel.org CC: linux-kernel@vger.kernel.org Signed-off-by: Jason Wessel <jason.wessel@windriver.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:

committed by
Greg Kroah-Hartman

parent
9757de3844
commit
bd5afa9eac
@@ -447,7 +447,7 @@ static void flush_and_resubmit_read_urb(struct usb_serial_port *port)
|
||||
/* The per character mucking around with sysrq path it too slow for
|
||||
stuff like 3G modems, so shortcircuit it in the 99.9999999% of cases
|
||||
where the USB serial is not a console anyway */
|
||||
if (!port->console || !port->sysrq)
|
||||
if (!port->port.console || !port->sysrq)
|
||||
tty_insert_flip_string(tty, ch, urb->actual_length);
|
||||
else {
|
||||
/* Push data to tty */
|
||||
@@ -561,7 +561,7 @@ void usb_serial_generic_unthrottle(struct tty_struct *tty)
|
||||
int usb_serial_handle_sysrq_char(struct tty_struct *tty,
|
||||
struct usb_serial_port *port, unsigned int ch)
|
||||
{
|
||||
if (port->sysrq && port->console) {
|
||||
if (port->sysrq && port->port.console) {
|
||||
if (ch && time_before(jiffies, port->sysrq)) {
|
||||
handle_sysrq(ch, tty);
|
||||
port->sysrq = 0;
|
||||
|
Reference in New Issue
Block a user