]> git.baikalelectronics.ru Git - kernel.git/commit
serial: exar: Fix stuck MSIs
authorJan Kiszka <jan.kiszka@siemens.com>
Mon, 24 Apr 2017 10:30:15 +0000 (12:30 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 18 May 2017 14:43:55 +0000 (16:43 +0200)
commitaefed5faa59c766f84fc2ead8dd0bf25cc55e60f
tree8c7214a39078df3767d874c16c5391a468658faa
parentea0c103e1e8b4012faf1197436dc1e67105a32c0
serial: exar: Fix stuck MSIs

After migrating 8250_exar to MSI in 5208374ccf80, we can get stuck
without further interrupts because of the special wake-up event these
chips send. They are only cleared by reading INT0. As we fail to do so
during startup and shutdown, we can leave the interrupt line asserted,
which is fatal with edge-triggered MSIs.

Add the required reading of INT0 to startup and shutdown. Also account
for the fact that a pending wake-up interrupt means we have to return 1
from exar_handle_irq. Drop the unneeded reading of INT1..3 along with
this - those never reset anything.

An alternative approach would have been disabling the wake-up interrupt.
Unfortunately, this feature (REGB[17] = 1) is not available on the
XR17D15X.

Fixes: 5208374ccf80 ("serial: exar: Enable MSI support")
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/serial/8250/8250_port.c