]> git.baikalelectronics.ru Git - kernel.git/commit
serial: do not restore interrupt state in sysrq helper
authorJohan Hovold <johan@kernel.org>
Fri, 16 Apr 2021 14:05:55 +0000 (16:05 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 22 Apr 2021 10:04:26 +0000 (12:04 +0200)
commit1d2b9dd9cc2e3b90bd9bfd1cbe5d130a3ca6b818
treeeee2f6223ed380cc8ed106f4342213c2ebef469e
parentf6b595ce157e7887ebc08a55767e83e00853ce4f
serial: do not restore interrupt state in sysrq helper

The uart_unlock_and_check_sysrq() helper can be used to defer processing
of sysrq until the interrupt handler has released the port lock and is
about to return.

Since commit 54472742a192 ("genirq: Disable interrupts for force
threaded handlers") interrupt handlers that are not explicitly requested
as threaded are always called with interrupts disabled and there is no
need to save the interrupt state when taking the port lock.

Instead of adding another sysrq helper for when the interrupt state has
not needlessly been saved, drop the state parameter from
uart_unlock_and_check_sysrq() and update its callers to no longer
explicitly disable interrupts in their interrupt handlers.

Cc: Joel Stanley <joel@jms.id.au>
Cc: Andrew Jeffery <andrew@aj.id.au>
Cc: Andy Gross <agross@kernel.org>
Cc: Bjorn Andersson <bjorn.andersson@linaro.org>
Signed-off-by: Johan Hovold <johan@kernel.org>
Link: https://lore.kernel.org/r/20210416140557.25177-2-johan@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/serial/8250/8250_aspeed_vuart.c
drivers/tty/serial/8250/8250_fsl.c
drivers/tty/serial/8250/8250_omap.c
drivers/tty/serial/8250/8250_port.c
drivers/tty/serial/qcom_geni_serial.c
include/linux/serial_core.h