Re: [linux-uvc-devel] [REGRESSION] uvcvideo: Grandstream GUV3100 (2bab:0011) broken on recent kerne
Linux UVC driver and tools
Brought to you by:
pinchartl
|
From: Laurent P. <lau...@id...> - 2025-10-09 09:29:45
|
On Thu, Oct 09, 2025 at 12:22:57PM +0300, Angel4005 wrote: > Hello, > > Thank you very much for your quick and helpful responses! > > I confirm that the problem seems to be related to duplicate IDs in the > descriptor of my Grandstream GUV3100 device. > > Unfortunately, I was unable to test the proposed patch, as kernel > building is beyond my current capabilities. I am not experienced in > such matters and do not want to risk the stability of my system. > > The exact breaking point when the camera stopped working was found: > > * Last known WORKING kernel (GOOD): 6.12.50-1-lts > * First known NON-WORKING kernel (BAD): 6.12.51-1-lts > > I hope this information will help pinpoint the commit that caused the > regression. We know which commit caused the regrassion, but it's hard to fix the issue properly without being able to test on the device. That's why Ricardo asked if the camera can be easily bought from somewhere. > Thank you very much for your help, guidance, and understanding! > > чт, 9 жовт. 2025 р. о 09:55 Ricardo Ribalda <ri...@ch...> пише: > > > > Hi Angel > > > > Thank you very much for the detailed report. > > > > Your device has two entities with the same id: > > VideoControl Interface Descriptor: > > bLength 31 > > bDescriptorType 36 > > bDescriptorSubtype 6 (EXTENSION_UNIT) > > bUnitID 4 > > > > > > ideoControl Interface Descriptor: > > bLength 9 > > bDescriptorType 36 > > bDescriptorSubtype 3 (OUTPUT_TERMINAL) > > bTerminalID 4 > > wTerminalType 0x0101 USB Streaming > > bAssocTerminal 0 > > bSourceID 3 > > iTerminal 0 > > > > And that confuses the code. We have recently introduced a change that > > has probably triggered the regression > > https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/drivers/media/usb/uvc?id=0e2ee70291e64a30fe36960c85294726d34a103e > > > > Do you know the commercial name of the device and if it is available to buy? > > > > Could you try this patch and let me know if it fixes the issue? > > > > diff --git a/drivers/media/usb/uvc/uvc_driver.c > > b/drivers/media/usb/uvc/uvc_driver.c > > index fa61f1d0ea2c..81937501fb0c 100644 > > --- a/drivers/media/usb/uvc/uvc_driver.c > > +++ b/drivers/media/usb/uvc/uvc_driver.c > > @@ -167,11 +167,23 @@ static struct uvc_entity > > *uvc_entity_by_reference(struct uvc_device *dev, > > > > static struct uvc_streaming *uvc_stream_by_id(struct uvc_device *dev, int id) > > { > > - struct uvc_streaming *stream; > > + struct uvc_streaming *stream, *last_entry; > > + unsigned int count = 0; > > > > list_for_each_entry(stream, &dev->streams, list) { > > if (stream->header.bTerminalLink == id) > > return stream; > > + count += 1; > > + last_entry = stream; > > + } > > + > > + /* > > + * If the streaming entity has an invalid id, but it is the only > > + * one available, use it. > > + */ > > + if (count == 1 && id == UVC_INVALID_ENTITY_ID) { > > + dev_err(&dev->intf->dev, "Heuristics triggered\n"); > > + return last_entry; > > } > > > > return NULL; -- Regards, Laurent Pinchart |