Skip to content

v2 dwc2 DMA alignment_buffer handling #6923

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

Merged
merged 2 commits into from
Jun 24, 2025
Merged

Conversation

P33M
Copy link
Contributor

@P33M P33M commented Jun 23, 2025

Candidate fix for #6911

Both UVC cameras and USB mass-storage are now functional on CM5.

All the Broadcom SoCs use the same SNPS core version (2.80a) so the hardware length bug is present in each.

P33M added 2 commits June 23, 2025 16:48
This incorrectly matches on urb->setup_packet instead of checking the
pipe type, so recycled URBs were incorrectly matched.

A more comprehensive fix is forthcoming.

This reverts commit 2f27224.

Signed-off-by: Jonathan Bell <[email protected]>
The version of the dwc-otg core used in BCM2835 through BCM2712 only does
whole-word writes, as well as needing the documented requirement for DMA
buffers to start on a word boundary.

Also, the alignment method used in the dwc2 driver doesn't handle the
case where the URB has the NO_TRANSFER_DMA_MAP flag set, so reject
buffers that have unaligned DMA start addresses. At least one whole page
should be mapped, so the BCM283x whole-word-write bug should be benign
in this case.

Signed-off-by: Jonathan Bell <[email protected]>
@pelwell pelwell merged commit 5cf83ec into raspberrypi:rpi-6.12.y Jun 24, 2025
11 of 12 checks passed
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.

2 participants