Skip to content

Conversation

@bugadani
Copy link
Contributor

This PR corrects the equation to calculate the required number of DMA descriptors. The driver requires descriptors in sets of 3, one set for each 4092 byte chunk. The former equation ((BUFFERSIZE / 4092) * 3) evaluates to 0 for transfers of size 0..4092, 3 for 4092..8184, etc, which is basically 3 less than required for cases where BUFFERSIZE % 4092 != 0.

Copy link
Contributor

@bjoernQ bjoernQ left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Member

@MabezDev MabezDev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the fix!

@MabezDev MabezDev merged commit 7f80b23 into esp-rs:main Jun 26, 2023
@bugadani bugadani deleted the dma branch June 26, 2023 15:40
SergioGasquez pushed a commit to SergioGasquez/esp-hal that referenced this pull request Jun 28, 2023
MabezDev pushed a commit that referenced this pull request Jul 12, 2023
playfulFence pushed a commit to playfulFence/esp-hal that referenced this pull request Sep 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants