Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

[media] uvcvideo: Enable UVC 1.5 device detection

UVC 1.5 devices report a bInterfaceProtocol value set to 1 in their
interface descriptors. The uvcvideo driver only matches on
bInterfaceProtocol 0, preventing those devices from being detected.

More changes to the driver are needed for full UVC 1.5 compatibility.
However, at least the UVC 1.5 Microsoft Surface Pro 3 cameras have been
reported to work out of the box with the driver with an updated match
table.

Enable UVC 1.5 support in the match table to support the devices that
can work with the current driver implementation. Devices that can't will
fail, but that's hardly a regression as they're currently not detected
at all anyway.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>

authored by

Laurent Pinchart and committed by
Mauro Carvalho Chehab
8afe97be 1ea7252d

+3 -1
+2 -1
drivers/media/usb/uvc/uvc_driver.c
··· 2540 2540 .bInterfaceProtocol = 0, 2541 2541 .driver_info = UVC_QUIRK_FORCE_Y8 }, 2542 2542 /* Generic USB Video Class */ 2543 - { USB_INTERFACE_INFO(USB_CLASS_VIDEO, 1, 0) }, 2543 + { USB_INTERFACE_INFO(USB_CLASS_VIDEO, 1, UVC_PC_PROTOCOL_UNDEFINED) }, 2544 + { USB_INTERFACE_INFO(USB_CLASS_VIDEO, 1, UVC_PC_PROTOCOL_15) }, 2544 2545 {} 2545 2546 }; 2546 2547
+1
include/uapi/linux/usb/video.h
··· 28 28 29 29 /* A.3. Video Interface Protocol Codes */ 30 30 #define UVC_PC_PROTOCOL_UNDEFINED 0x00 31 + #define UVC_PC_PROTOCOL_15 0x01 31 32 32 33 /* A.5. Video Class-Specific VC Interface Descriptor Subtypes */ 33 34 #define UVC_VC_DESCRIPTOR_UNDEFINED 0x00