tty: serial: imx: disable irq after suspend
authorMaxim Yu. Osipov <mosipov@ilbers.de>
Mon, 14 Aug 2017 14:27:49 +0000 (16:27 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 28 Aug 2017 18:51:22 +0000 (20:51 +0200)
commit81b289cc14ba349cc4707cf664aa1c72d7dff1d7
treee47e7b10e384a998668f5b2bb166e9a18ca64910
parent3d16ddc13c5e56726d05b4eceb766b06483e3686
tty: serial: imx: disable irq after suspend

If any key on console is pressed when board is suspended,
board hangs.

Driver's interrupt handler must be guaranteed not to run while
resume/suspend_noirq() are being executed. See include/linux/pm.h
for details.

Tested on i.MX6 based board.

The idea of this fix is based on commit in official i.MX kernel tree:
http://git.freescale.com/git/cgit.cgi/imx/linux-2.6-imx.git
commit 81e8e7d91d81 ("tty: serial: imx: disable irq after suspend")

Disable rx irq after suspend to avoid interrupt coming in early resume.

Signed-off-by: Fugang Duan <B38611@freescale.com>
Signed-off-by: Maxim Yu. Osipov <mosipov@ilbers.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/serial/imx.c