Re: [PATCH v2 0/2] hwtracing: hisi_ptt: Fix reset timeout handling and clean up trace start

From: Jonathan Cameron

Date: Fri Apr 17 2026 - 08:51:04 EST


On Tue, 14 Apr 2026 17:25:03 +0000
"Pradhan, Sanman" <sanman.pradhan@xxxxxxx> wrote:

> From: Sanman Pradhan <psanman@xxxxxxxxxxx>
+CC Sizhe Liu

>
> Patch 1: Propagate the DMA reset timeout error from
> hisi_ptt_wait_dma_reset_done() instead of discarding it. De-assert
> the reset bit and log an error on timeout. Move ctrl->started to the
> successful path so a failed start does not leave the trace marked as
> active.
>
> Patch 2: Remove the unnecessary 16 MiB memset of trace buffers in
> hisi_ptt_trace_start(). The driver only copies data that hardware has
> written, so the zeroing is not needed.
>
> Changes since v1:
> - Patch 1: Return bool from hisi_ptt_wait_dma_reset_done() for
> consistency with the other wait helpers
> - Patch 1: Add pci_err() on timeout
> - Patch 1: De-assert RST before returning on timeout
> - Patch 1: Move ctrl->started to the successful path
> - Dropped "Use the passed buffer index in hisi_ptt_update_aux()" patch
> - Patch 2 is unchanged
>
> Sanman Pradhan (2):
> hwtracing: hisi_ptt: Propagate DMA reset timeout in trace_start()
> hwtracing: hisi_ptt: Remove unnecessary trace buffer zeroing in
> trace_start()
>
> drivers/hwtracing/ptt/hisi_ptt.c | 25 +++++++++++++------------
> 1 file changed, 13 insertions(+), 12 deletions(-)
>