-
Notifications
You must be signed in to change notification settings - Fork 7.9k
drivers: dma: atcdmac300: Upgrade atcdmac driver to support series device #85272
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
drivers: dma: atcdmac300: Upgrade atcdmac driver to support series device #85272
Conversation
e22bc59
to
b22929b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The change in compatible is likely to be a breaking change, are there no andes soc or boards in the tree that need updating? Release notes updated?
@teburd Thank you for your reply. I'm not sure if you're referring to the SoC DTS part — if so, I’ve also updated the Andes AE350 device node(dts/riscv/andes/andes_v5_ae350.dtsi) in this PR. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR upgrades the ATCDMAC driver to support serial devices and improves compatibility by renaming driver identifiers and updating configuration, device tree, and build files. Key changes include:
- Transitioning from ATCDMAC300 to a unified ATCDMACx00 driver with updated register offset handling.
- Updating DT bindings and YAML files to support the new driver version.
- Adjusting test configuration files and build scripts accordingly.
Reviewed Changes
Copilot reviewed 12 out of 12 changed files in this pull request and generated 2 comments.
Show a summary per file
File | Description |
---|---|
tests/drivers/dma/scatter_gather/boards/adp_xc7k_ae350.overlay | Added overlay for scatter_gather test target. |
tests/drivers/dma/scatter_gather/boards/adp_xc7k_ae350.conf | Added config file enabling nocache memory and SoC PMA configuration. |
tests/drivers/dma/loop_transfer/boards/adp_xc7k_ae350.conf tests/drivers/dma/chan_blen_transfer/boards/adp_xc7k_ae350.conf |
Updated test configurations to disable DCACHE support. |
dts/riscv/andes/andes_v5_ae350.dtsi | Changed compatible string and added max-data-width property. |
dts/bindings/dma/andestech,atcdmacx00.yaml | Added new DT binding file for the updated DMA driver. |
dts/bindings/dma/andestech,atcdmac300.yaml | Removed obsolete binding file. |
drivers/dma/dma_andes_atcdmacx00.c | Overhauled source code with new naming, updated register offset computations and chain-block management. |
drivers/dma/Kconfig.andes_atcdmacx00 drivers/dma/Kconfig drivers/dma/CMakeLists.txt |
Updated build configuration and Kconfig to reference the new driver. |
Comments suppressed due to low confidence (1)
drivers/dma/dma_andes_atcdmacx00.c:463
- [nitpick] Consider adding a comment explaining the rationale behind using FIELD_GET for extracting the lower 32 bits of the address to clarify its usage for future maintenance and to ensure correct behavior on both 32- and 64-bit systems.
sys_write32((uint32_t)FIELD_GET(GENMASK(31, 0), (src)), DMA_CH_SRC_ADDR(dev, channel));
@teburd , sorry to bother you. Due to system requirements, I’m kindly requesting your review once again. |
Hi @fkokosinski |
b22929b
to
4e2c4e2
Compare
Rebased code based on changes in PR #90632 for atcdmac300. |
4e2c4e2
to
42e4dde
Compare
@teburd Because PR #90632 has introduced the cache operation for the chain_block (need both DCACHE and CACHE_MANAGEMENT are enabled). To fix the issue, following action was performed in this PR |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Trusting an Andes author knows best here, but the chain struct is a bit hard to grasp the changes on. I see many of the values got moved to the offset struct instead. Some commentary on this would be good to see.
42e4dde
to
0f3235e
Compare
I've updated the board's default config in the test cases. ==> Disabled DCACHE on dma test cases(even the test case support NONCACHE memory) because some Andes SoC don't support the portable noncached memory feature now. |
0f3235e
to
963bd42
Compare
@jimmyzhe, |
Could you also update adp_xc7k/ae350/clic in tests/drivers/dma/chan_blen_transfer, loop_transfer, and scatter_gather? This platform was merged a few weeks ago. |
…vice 1. Upgrade the ATCDMAC driver to make it compatible with multiple ATCDMAC series drivers. 2. Rename the driver from ATCDMAC300 to ATCDMACX00. Signed-off-by: Kevin Wang <kevinwang821020@google.com>
963bd42
to
cb5b8af
Compare
cb5b8af
to
e930c22
Compare
1. Add config and overlay file in test scatter_gather for adp_xc7k_ae350 and adp_xc7k_ae350_clic to support the test case. 2. Modify the config file in test chan_blen_transfer and loop_transfer because the tests do not support the NOCACHE memory configuration, the DCACHE configuration needs to be disabled. Signed-off-by: Kevin Wang <kevinwang821020@google.com>
e930c22
to
fa14b84
Compare
Understood. The relevant source files have been updated and verified. |
Please retry analysis of this Pull-Request directly on SonarQube Cloud |
This PR primarily updates the ATCDMAC driver. The updates include: