(very old) regression in sur40.ko

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello everyone,

I didn't use my sur40 for quite some time, but recently picked up work on it again. After a kernel update to 5.15, I noticed that the video component of the in-tree sur40 driver had apparently stopped working after 5.9 (this was actually noticed by @rwimmer a year ago, but I didn't properly follow up at the time).

This time, I did finally go through with a very tedious 14-step bisection of the issue and ended up at this commit:

https://github.com/torvalds/linux/commit/6eb0233ec2d0df288fe8515d5b0b2b15562e05bb

The issue manifests as a kernel oops in vb2_dma_sg_alloc, resulting in a failed usb_sg_init call (probably because dma_mask and dma_pfn_offset are now unset). How would I have to use the *_sg_* functions in my driver to fix this?

For reference, the code in question is:

	result = usb_sg_init(&sgr, sur40->usbdev,
		usb_rcvbulkpipe(sur40->usbdev, VIDEO_ENDPOINT), 0,
		sgt->sgl, sgt->nents, sur40->pix_fmt.sizeimage, 0);

From looking at the other uses of usb_sg_init, would it be sufficient to change the very last parameter from 0 to either GFP_KERNEL or GFP_NOIO? If yes, which one is correct?

Best, Florian
--
SENT FROM MY DEC VT50 TERMINAL

Attachment: OpenPGP_signature
Description: OpenPGP digital signature


[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]

  Powered by Linux