[RESEND PATCH 0/2] tty: serial: Fix kgdb on qcom-geni-serial when no other UART users

From: Douglas Anderson
Date: Thu Mar 16 2023 - 16:21:26 EST


Today to get kgdb to work on qcom-geni-serial devices you need
_something_ to init/power on the UART. This could either the kernel
console output or an "agetty" running on the port. If nothing else
powers the port then you'll end up getting a silent hang when you try
to enter kgdb.

Let's fix this. The first patch here is for the tty layer to make sure
that we power on the port when we init it for polling. This would be
important for any drivers similar to qcom-geni-serial that actually
need to be powered on. The second patch here hooks up the poll_init()
function for qcom-geni-serial, leveraging an existing function in the
driver that does everything we need.

Originally these two patches were bundled together as pathes 2 and 3
of a 3-patch series. We no longer need the first patch from the
orginal series since we landed a similar patch from Johan [1]
instead. The second two patches are still useful, though, so I've
reposted them alone and added this cover letter.

[1] https://lore.kernel.org/r/20230307164405.14218-1-johan+linaro@xxxxxxxxxx


Douglas Anderson (2):
serial: uart_poll_init() should power on the UART
tty: serial: qcom-geni-serial: Add a poll_init() function

drivers/tty/serial/qcom_geni_serial.c | 1 +
drivers/tty/serial/serial_core.c | 6 ++++++
2 files changed, 7 insertions(+)

--
2.40.0.rc1.284.g88254d51c5-goog