提交 484ca3a3 编写于 作者: H Haipeng YU 提交者: Felipe Balbi

usb: gadget: u_serial: fix switch off blocked

When a device is switched off by software, gserial_cleanup will
be called, and switch off will be blocked in this function
because wake_up_interruptible() in gs_close() can not wake_up
the wait_event() in gserial_cleanup(), it should be changed to
wake_up() to match the wait_event().
Signed-off-by: NHaipeng YU <haipeng.yu@stericsson.com>
Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
Signed-off-by: NFelipe Balbi <balbi@ti.com>
上级 5dbd6935
...@@ -887,7 +887,7 @@ static void gs_close(struct tty_struct *tty, struct file *file) ...@@ -887,7 +887,7 @@ static void gs_close(struct tty_struct *tty, struct file *file)
pr_debug("gs_close: ttyGS%d (%p,%p) done!\n", pr_debug("gs_close: ttyGS%d (%p,%p) done!\n",
port->port_num, tty, file); port->port_num, tty, file);
wake_up_interruptible(&port->port.close_wait); wake_up(&port->port.close_wait);
exit: exit:
spin_unlock_irq(&port->port_lock); spin_unlock_irq(&port->port_lock);
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册