ARM Sunxi Platform Development
 help / color / mirror / Atom feed
* [PATCH 0/2] dmaengine: sun6i: Fix two bugs in the DMA status path
@ 2026-08-14 13:28 Christian Lugnberg
  2026-08-14 13:28 ` [PATCH 1/2] dmaengine: sun6i: fix non-atomic read of DMA position registers Christian Lugnberg
  2026-08-14 13:28 ` [PATCH 2/2] dmaengine: sun6i: fix null pointer dereference in sun6i_dma_tx_status Christian Lugnberg
  0 siblings, 2 replies; 5+ messages in thread
From: Christian Lugnberg @ 2026-08-14 13:28 UTC (permalink / raw)
  To: vkoul
  Cc: Frank.Li, wens, jernej.skrabec, samuel, dmaengine,
	linux-arm-kernel, linux-sunxi, linux-kernel, Christian Lugnberg

This series fixes two bugs in the sun6i DMA driver's tx_status path.

The first patch fixes a non-atomic read of DMA_CHAN_LLI_ADDR and
DMA_CHAN_CUR_CNT in sun6i_get_chan_size(), introduced when cyclic DMA
support was added. The race causes spurious ALSA xruns on Allwinner H3
(Barix IPAM400), confirmed by observation on kernel 6.12.

The second patch fixes a null pointer dereference in sun6i_dma_tx_status()
where to_sun6i_desc() was called unconditionally on the return value of
vchan_find_desc() before the NULL check, present since the driver was
first introduced.

Both patches are candidates for stable backport.

Christian Lugnberg (2):
  dmaengine: sun6i: fix non-atomic read of DMA position registers
  dmaengine: sun6i: fix null pointer dereference in sun6i_dma_tx_status

 drivers/dma/sun6i-dma.c | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

-- 
2.54.0 (Apple Git-156)


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2026-08-14 13:41 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-08-14 13:28 [PATCH 0/2] dmaengine: sun6i: Fix two bugs in the DMA status path Christian Lugnberg
2026-08-14 13:28 ` [PATCH 1/2] dmaengine: sun6i: fix non-atomic read of DMA position registers Christian Lugnberg
2026-08-14 13:41   ` sashiko-bot
2026-08-14 13:28 ` [PATCH 2/2] dmaengine: sun6i: fix null pointer dereference in sun6i_dma_tx_status Christian Lugnberg
2026-08-14 13:37   ` sashiko-bot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox