dmaengine: ma35d1-pdma: Add MA35D1 PDMA driver
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v3 Latest2 patches 0 repliesNew
- v22 patches 6 repliesSuperseded
- v12 patches 9 repliesSuperseded
Changes in v3 from the cover letter
- Use dma_alloc_coherent() for the hardware SG table instead of kzalloc() + dma_map_single(); defer descriptor free in terminate_all().
- Rename ma35d1_desc_submit() to ma35d1_desc_prep_done(); prep() only prepares the descriptor.
- Rewrite the IRQ handler: read and ack TDSTS/ABTSTS once, then iterate the set bits.
- Address issue identified by Sashiko AI review:
- Terminate the descriptor with vchan_terminate_vdesc() when a cyclic transfer is aborted, avoiding a use-after-free in vchan_complete().
- Request the IRQ after the DMA device is registered.
- Use devm_of_dma_controller_register() and dmaenginem_async_device_register(), and drop remove(); a devm action stops the hardware and kills the tasklets.
Patches in v3 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | dt-bindings: dma: nuvoton,ma35d1-pdma: Document MA35D1 PDMA controllerDocumentation/ | +71 | 0 replies | |
| 2/2 | dmaengine: ma35d1-pdma: Add MA35D1 PDMA driverdrivers/ drivers/ drivers/ | +675 | 0 replies |
Reviews trailers per patch
1 of 2 patches has a Reviewed-by or Acked-by.
| Patch | Krzysztof Kozlowski | Frank Li |
|---|---|---|
| 1/2 | R-b | R-b |
| 2/2 |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH v3 0/2] dmaengine: ma35d1-pdma: Add MA35D1 PDMA driver
This series adds the PDMA controller driver and DT binding for the Nuvoton MA35D1 SoC.
The driver supports memory-to-memory, slave scatter-gather and cyclic transfers.
Tested on the MA35D1 SOM board with Linux v7.4-rc3:
- memory-to-memory with dmatest (2000 iterations of 1MB buffers, no failures)
- slave scatter-gather with a local (not yet submitted) QSPI patch
- cyclic slave with a local (not yet submitted) I2S patch
Changes in v3:
- Use dma_alloc_coherent() for the hardware SG table instead of kzalloc() + dma_map_single(); defer descriptor free in terminate_all().
- Rename ma35d1_desc_submit() to ma35d1_desc_prep_done(); prep() only prepares the descriptor.
- Rewrite the IRQ handler: read and ack TDSTS/ABTSTS once, then iterate the set bits.
- Address issue identified by Sashiko AI review:
- Terminate the descriptor with vchan_terminate_vdesc() when a cyclic transfer is aborted, avoiding a use-after-free in vchan_complete().
- Request the IRQ after the DMA device is registered.
- Use devm_of_dma_controller_register() and dmaenginem_async_device_register(), and drop remove(); a devm action stops the hardware and kills the tasklets.
Changes in v2:
- Address issues identified by Sashiko AI review:
- Program registers on descriptor start instead of prep.
- Fix interrupt completion handling and return IRQ_NONE when idle.
- Set PDMA_TBINTDIS on intermediate memcpy chunks.
- Validate scatter-gather lengths and bus width alignment.
- Fix channel request assignment in of_xlate().
- Safe controller teardown order in remove().
- Drop peripheral timeout support to simplify driver.
- binding: describe the hardware in the description, and drop dma-channels and the dt-bindings header.
- Use a fixed number of 10 channels and trim the includes.
Shan-Chun Hung (2):
dt-bindings: dma: nuvoton,ma35d1-pdma: Document MA35D1 PDMA controller
dmaengine: ma35d1-pdma: Add MA35D1 PDMA driver
.../bindings/dma/nuvoton,ma35d1-pdma.yaml | 71 ++ drivers/dma/Kconfig | 12 + drivers/dma/Makefile | 1 + drivers/dma/ma35d1-pdma.c | 662 ++++++++++++++++++ 4 files changed, 746 insertions(+) create mode 100644 Documentation/devicetree/bindings/dma/nuvoton,ma35d1-pdma.yaml create mode 100644 drivers/dma/ma35d1-pdma.c
Signature · 1 line
2.25.1