]> git.karo-electronics.de Git - karo-tx-linux.git/commit
serial/imx: read cts state only after acking cts change irq
authorUwe Kleine-König <u.kleine-koenig@pengutronix.de>
Mon, 11 Apr 2011 08:59:09 +0000 (10:59 +0200)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 9 May 2011 22:54:48 +0000 (15:54 -0700)
commite028e896b4a5adb887533e827b57e842f8b2173f
tree0e3d0e31349bd1d5ff53fe58eb96f8a0eaad3489
parent16b0c220618ffbe2e76cc5b20176c0cf7c3e6888
serial/imx: read cts state only after acking cts change irq

commit 5680e94148a86e8c31fdc5cb0ea0d5c6810c05b0 upstream.

If cts changes between reading the level at the cts input (USR1_RTSS)
and acking the irq (USR1_RTSD) the last edge doesn't generate an irq and
uart_handle_cts_change is called with a outdated value for cts.

The race was introduced by commit

ceca629 ([ARM] 2971/1: i.MX uart handle rts irq)

Reported-by: Arwed Springer <Arwed.Springer@de.trumpf.com>
Tested-by: Arwed Springer <Arwed.Springer@de.trumpf.com>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/serial/imx.c