From: Johan Hovold Date: Wed, 29 Oct 2014 08:07:34 +0000 (+0100) Subject: USB: mos7840: replace unnecessary atomic allocations X-Git-Tag: firefly_0821_release~176^2~2679^2~14^2~2 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=9d3801903851a2be51f0b2d85f25f952a7da9969;p=firefly-linux-kernel-4.4.55.git USB: mos7840: replace unnecessary atomic allocations Use GFP_KERNEL instead of GFP_ATOMIC for allocations in set_termios and port-setting helper which both may and do sleep. Signed-off-by: Johan Hovold --- diff --git a/drivers/usb/serial/mos7840.c b/drivers/usb/serial/mos7840.c index 3d88eefdf1d1..220b4be89641 100644 --- a/drivers/usb/serial/mos7840.c +++ b/drivers/usb/serial/mos7840.c @@ -1904,7 +1904,7 @@ static void mos7840_change_port_settings(struct tty_struct *tty, if (mos7840_port->read_urb_busy == false) { mos7840_port->read_urb_busy = true; - status = usb_submit_urb(mos7840_port->read_urb, GFP_ATOMIC); + status = usb_submit_urb(mos7840_port->read_urb, GFP_KERNEL); if (status) { dev_dbg(&port->dev, "usb_submit_urb(read bulk) failed, status = %d\n", status); @@ -1968,7 +1968,7 @@ static void mos7840_set_termios(struct tty_struct *tty, if (mos7840_port->read_urb_busy == false) { mos7840_port->read_urb_busy = true; - status = usb_submit_urb(mos7840_port->read_urb, GFP_ATOMIC); + status = usb_submit_urb(mos7840_port->read_urb, GFP_KERNEL); if (status) { dev_dbg(&port->dev, "usb_submit_urb(read bulk) failed, status = %d\n", status);