Skip to content
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

Fixes dma scatter gather test nxp lpc dma #85975

Conversation

hakehuang
Copy link
Collaborator

@hakehuang hakehuang commented Feb 19, 2025

for nxp_lpc_dma source_gather_interval need config in align with times of the data size, otherwise the src address will not inc after one transfer.

also enable lpcxpresso55s36 dma in its feature tag
and add mimxrt685 in the support list

fixes: #85403

@hakehuang
Copy link
Collaborator Author

hakehuang commented Feb 19, 2025

test log for mimxrt685_evk_cm33

*** Booting Zephyr OS build v4.1.0-rc1-84-ge885c8c42f77 ***
Running TESTSUITE dma_m2m_sg
===================================================================
START - test_dma_m2m_sg
DMA memory to memory transfer started
Preparing DMA Controller
Platform does not support dma request channel, using Kconfig DMA_SG_CHANNEL_NR
dma block 0 block_size 8192, source addr 0x10189220, dest addr 0x10181220
set next block pointer to 0x1018dc3c
dma block 1 block_size 8192, source addr 0x10189220, dest addr 0x10183220
set next block pointer to 0x1018dc5c
dma block 2 block_size 8192, source addr 0x10189220, dest addr 0x10185220
set next block pointer to 0x1018dc7c
dma block 3 block_size 8192, source addr 0x10189220, dest addr 0x10187220
Configuring the scatter-gather transfer on channel 0
Starting the transfer on channel 0 and waiting completion
giving xfer_sem
Verify RX buffer should contain the full TX buffer string.
rx_data[0]
rx_data[1]
rx_data[2]
rx_data[3]
Finished: DMA Scatter-Gather
 PASS - test_dma_m2m_sg in 0.076 seconds
===================================================================
TESTSUITE dma_m2m_sg succeeded

------ TESTSUITE SUMMARY START ------

SUITE PASS - 100.00% [dma_m2m_sg]: pass = 1, fail = 0, skip = 0, total = 1 duration = 0.076 seconds
 - PASS - [dma_m2m_sg.test_dma_m2m_sg] duration = 0.076 seconds

------ TESTSUITE SUMMARY END ------

===================================================================
RunID: bec097a1af92d7a2d9426806a405eec6
PROJECT EXECUTION SUCCESSFUL

test log for lpcxpresso55s36

ubuntu@ubuntu-Latitude-7480:~/zephyrproject/zephyr$ cat /home/ubuntu/zephyrproject/zephyr/twister-out/lpcxpresso55s36_lpc55s36/zephyr/tests/drivers/dma/scatter_gather/drivers.dma.scatter_gather/handler.log
*** Booting Zephyr OS build v4.1.0-rc1-86-g2cef7708e82b ***
Running TESTSUITE dma_m2m_sg
===================================================================
START - test_dma_m2m_sg
DMA memory to memory transfer started
Preparing DMA Controller
Platform does not support dma request channel, using Kconfig DMA_SG_CHANNEL_NR
dma block 0 block_size 8192, source addr 0x20008b40, dest addr 0x20000b40
set next block pointer to 0x2000ebf4
dma block 1 block_size 8192, source addr 0x20008b40, dest addr 0x20002b40
set next block pointer to 0x2000ec14
dma block 2 block_size 8192, source addr 0x20008b40, dest addr 0x20004b40
set next block pointer to 0x2000ec34
dma block 3 block_size 8192, source addr 0x20008b40, dest addr 0x20006b40
Configuring the scatter-gather transfer on channel 0
Starting the transfer on channel 0 and waiting completion
giving xfer_sem
Verify RX buffer should contain the full TX buffer string.
rx_data[0]
rx_data[1]
rx_data[2]
rx_data[3]
Finished: DMA Scatter-Gather
 PASS - test_dma_m2m_sg in 0.076 seconds
===================================================================
TESTSUITE dma_m2m_sg succeeded

------ TESTSUITE SUMMARY START ------

SUITE PASS - 100.00% [dma_m2m_sg]: pass = 1, fail = 0, skip = 0, total = 1 duration = 0.076 seconds
 - PASS - [dma_m2m_sg.test_dma_m2m_sg] duration = 0.076 seconds

------ TESTSUITE SUMMARY END ------

===================================================================
RunID: 63fd379bd86fd6238d77c053425069f0
PROJECT EXECUTION SUCCESSFUL

@hakehuang
Copy link
Collaborator Author

@janmft thanks a lot for checking this issue.

@hakehuang hakehuang force-pushed the fixes_dma_scatter_gather_test_nxp_lpc_dma branch from 2cef770 to c1c7870 Compare February 19, 2025 07:45
@hakehuang hakehuang closed this Feb 19, 2025
this board support dma so add for testing.

Signed-off-by: Hake Huang <[email protected]>
source_gather_interval needs to be configed for nxp_lpc_dma

fixes: zephyrproject-rtos#85403

Signed-off-by: Hake Huang <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: DMA Direct Memory Access platform: NXP NXP
Projects
None yet
Development

Successfully merging this pull request may close these issues.

DMA behaves different for i.MXRT1064 and i.MXRT685
3 participants