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

Permanent fix for vchiq bulk transfer failures on 5.10 #4022

Merged
merged 5 commits into from Dec 23, 2020

Conversation

pelwell
Copy link
Contributor

@pelwell pelwell commented Dec 22, 2020

This fix replaces #4016, reverting the reversions and applying a simple patch to fix the real bug, which was that the userdata for a bulk transfer was not preserved in the common case where a non-blocking transfer was being performed.

@naushir,@6by9 If either of you are in a position to easily give this a spin I'd welcome the feedback, but vchiq_test in all its modes is happy (on 32-bit builds - 64-bit doesn't work with either fix...)

Copy link
Contributor

@6by9 6by9 left a comment

Choose a reason for hiding this comment

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

Looks reasonable but haven't tested it. Will do so tomorrow.

You could drop the initialisation of userdata to NULL seeing as it is now set to a value under all situations.

@popcornmix
Copy link
Collaborator

The fix looks sane to me. Tested it fixes issue with vchiq_test -b 1000

The addition of the local 'userdata' pointer to
vchiq_irq_queue_bulk_tx_rx omitted the case where neither BLOCKING nor
WAITING modes are used, in which case the value provided by the
caller is replaced with a NULL.

Fixes: 4184da4 ("staging: vchiq: fix __user annotations")

Signed-off-by: Phil Elwell <phil@raspberrypi.com>
@pelwell
Copy link
Contributor Author

pelwell commented Dec 22, 2020

I was going to leave the initialisation, but it's been removed now.

@6by9
Copy link
Contributor

6by9 commented Dec 23, 2020

Looks good. raspistill just captured an image for me.

@naushir
Copy link
Contributor

naushir commented Dec 23, 2020

LGTM too. Raspistill and raspivid work as expected.

@popcornmix popcornmix merged commit a2e5a94 into raspberrypi:rpi-5.10.y Dec 23, 2020
popcornmix added a commit to raspberrypi/firmware that referenced this pull request Dec 23, 2020
kernel: Permanent fix for vchiq bulk transfer failures on 5.10
See: raspberrypi/linux#4022
popcornmix added a commit to Hexxeh/rpi-firmware that referenced this pull request Dec 23, 2020
kernel: Permanent fix for vchiq bulk transfer failures on 5.10
See: raspberrypi/linux#4022
@pelwell pelwell deleted the vchiqfix2 branch September 15, 2021 07:57
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.

None yet

4 participants