[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <fd49ed95-bea8-40a4-b493-377fafadcdb3@linaro.org>
Date: Wed, 19 Jun 2024 10:25:11 +0200
From: neil.armstrong@...aro.org
To: Douglas Anderson <dianders@...omium.org>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Jiri Slaby <jirislaby@...nel.org>
Cc: Yicong Yang <yangyicong@...ilicon.com>, Tony Lindgren <tony@...mide.com>,
Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
Johan Hovold <johan+linaro@...nel.org>,
John Ogness <john.ogness@...utronix.de>, linux-arm-msm@...r.kernel.org,
Bjorn Andersson <andersson@...nel.org>,
Konrad Dybcio <konrad.dybcio@...aro.org>,
Ilpo Järvinen <ilpo.jarvinen@...ux.intel.com>,
Stephen Boyd <swboyd@...omium.org>, linux-serial@...r.kernel.org,
linux-kernel@...r.kernel.org,
Uwe Kleine-König <u.kleine-koenig@...gutronix.de>,
Rob Herring <robh@...nel.org>, Thomas Gleixner <tglx@...utronix.de>,
Vijaya Krishna Nivarthi <quic_vnivarth@...cinc.com>
Subject: Re: [PATCH v4 0/8] serial: qcom-geni: Overhaul TX handling to fix
crashes/hangs
On 11/06/2024 00:24, Douglas Anderson wrote:
>
> While trying to reproduce -EBUSY errors that our lab was getting in
> suspend/resume testing, I ended up finding a whole pile of problems
> with the Qualcomm GENI serial driver. I've posted a fix for the -EBUSY
> issue separately [1]. This series is fixing all of the Qualcomm GENI
> problems that I found.
>
> As far as I can tell most of the problems have been in the Qualcomm
> GENI serial driver since inception, but it can be noted that the
> behavior got worse with the new kfifo changes. Previously when the OS
> took data out of the circular queue we'd just spit stale data onto the
> serial port. Now we'll hard lockup. :-P
>
> I've tried to break this series up as much as possible to make it
> easier to understand but the final patch is still a lot of change at
> once. Hopefully it's OK.
>
> [1] https://lore.kernel.org/r/20240530084841.v2.1.I2395e66cf70c6e67d774c56943825c289b9c13e4@changeid
>
> Changes in v4:
> - Add GP_LENGTH field definition.
> - Fix indentation.
> - GENMASK(31, 0) -> GP_LENGTH.
> - Use uart_fifo_timeout_ms() for timeout.
> - tty: serial: Add uart_fifo_timeout_ms()
>
> Changes in v3:
> - 0xffffffff => GENMASK(31, 0)
> - Reword commit message.
> - Use uart_fifo_timeout() for timeout.
>
> Changes in v2:
> - Totally rework / rename patch to handle suspend while active xfer
> - serial: qcom-geni: Fix arg types for qcom_geni_serial_poll_bit()
> - serial: qcom-geni: Fix the timeout in qcom_geni_serial_poll_bit()
> - serial: qcom-geni: Introduce qcom_geni_serial_poll_bitfield()
> - serial: qcom-geni: Just set the watermark level once
> - serial: qcom-geni: Rework TX in FIFO mode to fix hangs/lockups
> - soc: qcom: geni-se: Add GP_LENGTH/IRQ_EN_SET/IRQ_EN_CLEAR registers
>
> Douglas Anderson (8):
> soc: qcom: geni-se: Add GP_LENGTH/IRQ_EN_SET/IRQ_EN_CLEAR registers
> tty: serial: Add uart_fifo_timeout_ms()
> serial: qcom-geni: Fix the timeout in qcom_geni_serial_poll_bit()
> serial: qcom-geni: Fix arg types for qcom_geni_serial_poll_bit()
> serial: qcom-geni: Introduce qcom_geni_serial_poll_bitfield()
> serial: qcom-geni: Just set the watermark level once
> serial: qcom-geni: Fix suspend while active UART xfer
> serial: qcom-geni: Rework TX in FIFO mode to fix hangs/lockups
>
> drivers/tty/serial/qcom_geni_serial.c | 322 +++++++++++++++-----------
> include/linux/serial_core.h | 15 +-
> include/linux/soc/qcom/geni-se.h | 9 +
> 3 files changed, 206 insertions(+), 140 deletions(-)
>
Indeed no more lockup when killing a process on the serial debug console
Tested-by: Neil Armstrong <neil.armstrong@...aro.org> # on SM8650-HDK
Thanks !
Neil
Powered by blists - more mailing lists