[PATCH 0/2] serial: qcom_geni: Quiesce UART transfers during panic and shutdown
Praveen Talari <[email protected]>
| Newsgroups | org.kernel.vger.linux-serial,org.kernel.vger.linux-arm-msm,org.kernel.vger.linux-kernel |
|---|---|
| Message-ID | <20260715-add_shutdown_and_panic_notifier_serial-v1-0-23e3787c7109@oss.qualcomm.com> |
Active UART DMA transfers can persist beyond VM shutdown or panic scenarios, allowing the DMA engine to continue accessing IOVAs that have already been invalidated during memory teardown. On VM-based platforms, this can result in SMMU context faults and leave the GENI Serial Engine in an undefined state. In panic scenarios, pending transfers may also interfere with reliable panic console output. This series addresses these issues by ensuring ongoing UART TX/RX activity is stopped during both shutdown and panic flows. Patch 1 adds a shutdown callback to quiesce the hardware during reboot or VM shutdown, bringing the UART hardware to an idle state before reset and preventing SMMU faults caused by DMA accesses after VM teardown. Patch 2 adds a panic notifier to stop TX/RX activity during kernel panic, preventing further DMA transactions and ensuring panic console handling is not impacted by stuck transfers. Signed-off-by: Praveen Talari <[email protected]> --- Praveen Talari (2): serial: qcom_geni: Add shutdown callback to quiesce hardware on reboot serial: qcom_geni: Add panic notifier to stop UART on panic drivers/tty/serial/qcom_geni_serial.c | 36 +++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) --- base-commit: cc2b5f627e8ccbae1188ef2d8be3e451d7f933a5 change-id: 20260715-add_shutdown_and_panic_notifier_serial-2666cc2ac30f Best regards, -- Praveen Talari <[email protected]>