mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH v2 0/6] dmaengine: sun6i: fix interrupt routing and channel lifetime
@ 2026-10-23 18:42 James Hilliard
  2026-10-23 18:42 ` [PATCH v2 1/6] dmaengine: sun6i: fix physical channel index in interrupt handler James Hilliard
                   ` (5 more replies)
  0 siblings, 6 replies; 10+ messages in thread
From: James Hilliard @ 2026-10-23 18:42 UTC (permalink / raw)
  To: Vinod Koul, Frank Li, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Arnd Bergmann, Maxime Ripard, Jens Kuske,
	Jean-Francois Moine
  Cc: Hongling Zeng, Chengfeng Ye, Nguyen Minh Tien, dmaengine,
	linux-arm-kernel, linux-sunxi, linux-kernel, James Hilliard,
	stable, Frank Li, Sashiko

Correct interrupt routing and serialize physical-channel ownership across
allocation, completion, pause and termination. Keep paused virtual channels
off the allocator, drain completion callbacks before releasing resources,
and associate cyclic state with the descriptor that owns it.

The first patch carries Hongling Zeng's physical-channel indexing fix [0],
adapted to the configurable interrupt-bank size introduced for A733. The
second handles partially populated banks, including H3's twelve channels.
The remaining patches establish the ownership locking, pause bookkeeping,
callback retirement and per-descriptor cyclic state in that order.

Based on DMAengine next at aff5e6a77fc6, which includes A733 support, with
the posted IRQ-safe locking fix [1], channel pause-bit fix [2], and the
virt-dma synchronization helper from [3] applied first. The synchronization
patch uses that shared helper for the sun6i device_synchronize callback.

[0] https://lore.kernel.org/r/20260706064123.66035-1-zenghongling@kylinos.cn
[1] https://lore.kernel.org/r/20260926171049.841335-1-tien.nguyenminh@embeddedlinux.blog
[2] https://lore.kernel.org/r/20261021-submit-sun6i-dma-pause-bit-v1-v1-1-38d286b69dab@gmail.com
[3] https://lore.kernel.org/r/20261022-submit-mtk-uart-dma-synchronize-v1-v2-1-fdaef0e2edd6@gmail.com

Assisted-by: Codex:gpt-6-astra
Signed-off-by: James Hilliard <james.hilliard1@gmail.com>
---
Changes in v2:
- Clear the active descriptor pointer before handing finite completion to
  virt-dma, replacing the completed-descriptor pointer.
- Release completed physical channels while their virtual channels remain
  paused, and clear the hardware pause request before reassignment.
- Keep the ownership changes in patch 3 and the pause policy in patch 4.
- Link to v1: https://lore.kernel.org/r/20261022-submit-sun6i-dma-lifetime-next-v1-v1-0-01085f684c9f@gmail.com

---
Hongling Zeng (1):
      dmaengine: sun6i: fix physical channel index in interrupt handler

James Hilliard (5):
      dmaengine: sun6i: handle the last partial interrupt bank
      dmaengine: sun6i: serialize channel reassignment with interrupt handling
      dmaengine: sun6i: track paused virtual channels
      dmaengine: sun6i: synchronize callbacks before releasing channel resources
      dmaengine: sun6i: keep cyclic state with the prepared descriptor

 drivers/dma/sun6i-dma.c | 180 +++++++++++++++++++++++++++---------------------
 1 file changed, 103 insertions(+), 77 deletions(-)
---
base-commit: aff5e6a77fc69a7c490246465940d18422d7c631
change-id: 20261022-submit-sun6i-dma-lifetime-next-v1-53c3158f4841
prerequisite-patch-id: d6398447647aa0dbb005b5e6dc6ba96e642efa86
prerequisite-patch-id: f67c1f8d8d9e014cc650f2f37648662430c3b77b
prerequisite-patch-id: 8522878df4ecd4fb007cfd32611359e6eb58a1ef

Best regards,
--  
James Hilliard <james.hilliard1@gmail.com>


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

end of thread, other threads:[~2026-10-23 21:57 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-10-23 18:42 [PATCH v2 0/6] dmaengine: sun6i: fix interrupt routing and channel lifetime James Hilliard
2026-10-23 18:42 ` [PATCH v2 1/6] dmaengine: sun6i: fix physical channel index in interrupt handler James Hilliard
2026-10-23 18:42 ` [PATCH v2 2/6] dmaengine: sun6i: handle the last partial interrupt bank James Hilliard
2026-10-23 20:05   ` Frank Li
2026-10-23 18:42 ` [PATCH v2 3/6] dmaengine: sun6i: serialize channel reassignment with interrupt handling James Hilliard
2026-10-23 20:32   ` Frank Li
2026-10-23 21:57     ` James Hilliard
2026-10-23 18:42 ` [PATCH v2 4/6] dmaengine: sun6i: track paused virtual channels James Hilliard
2026-10-23 18:42 ` [PATCH v2 5/6] dmaengine: sun6i: synchronize callbacks before releasing channel resources James Hilliard
2026-10-23 18:42 ` [PATCH v2 6/6] dmaengine: sun6i: keep cyclic state with the prepared descriptor James Hilliard

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

all inboxes | Powered by JetHome®