Hi Doncho, On Thu, Nov 19, 2020 at 11:52:28AM +0200, Doncho Minkov wrote: > Hello! > > My new webcam does not work on my Manjaro, but works fine on my Windows machine. > > I've read the article at https://www.ideasonboard.org/uvc/faq/ and > tried to troubleshoot it, but to no success. > > Can you help me? I am attaching the logs from lsubs and dmesg. Could you please send the output of 'lsusb -v -d 1bcf:0b40', running as root if possible ('sudo lsusb -v -d 1bcf:0b40' should do) ? [snip] > [ 2.740672] usb 1-4: New USB device found, idVendor=1bcf, idProduct=0b40, bcdDevice= 9.14 > [ 2.740674] usb 1-4: New USB device strings: Mfr=1, Product=2, SerialNumber=3 > [ 2.740674] usb 1-4: Product: 2K FHD camera > [ 2.740675] usb 1-4: Manufacturer: SHENZHENAONI ELECTRONIC CO.,LTD > [ 2.740676] usb 1-4: SerialNumber: AN2020091401 [snip] > [ 4.856500] usb 1-4: 3:1: cannot get freq at ep 0x86 > [ 4.895811] usbcore: registered new interface driver snd-usb-audio > [ 4.900922] uvcvideo: Found UVC 1.10 device 2K FHD camera (1bcf:0b40) Your device claims it implements UVC 1.10. > [ 4.920820] uvcvideo: Failed to query (GET_INFO) UVC control 14 on unit 1: -32 (exp. 1). > [ 4.977348] uvcvideo: UVC non compliance - GET_DEF(PROBE) not supported. Enabling workaround. > [ 4.982821] uvcvideo: Failed to query (129) UVC probe control : 26 (exp. 34). But it handles the probe control as in UVC 1.0a (the size of the control was 26 in UVC 1.0a, and got extended to 34 bytes in UVC 1.10). > [ 4.982836] uvcvideo: Failed to initialize the device (-5). > [ 4.982884] usbcore: registered new interface driver uvcvideo > [ 4.982884] USB Video Class driver (1.1.1) Could you try the following patch ? commit 9f01208d6d06568dabb67fa04efbae2cec51d7a2 Author: Laurent Pinchart <laurent.pinchart@xxxxxxxxxxxxxxxx> Date: Fri Nov 20 12:57:48 2020 +0200 media: uvcvideo: Force UVC version to 1.0a for 1bcf:0b40 The Shenzhen Aoni Electronic Co.,Ltd 2K FHD camera reports a UVC 1.10 version, but implements UVC 1.0a as shown by the UVC probe control being 26 bytes long. Force the UVC version for that device. Signed-off-by: Laurent Pinchart <laurent.pinchart@xxxxxxxxxxxxxxxx> diff --git a/drivers/media/usb/uvc/uvc_driver.c b/drivers/media/usb/uvc/uvc_driver.c index ddb9eaa11be7..05aea3ce2e23 100644 --- a/drivers/media/usb/uvc/uvc_driver.c +++ b/drivers/media/usb/uvc/uvc_driver.c @@ -2274,6 +2274,12 @@ static int uvc_probe(struct usb_interface *intf, "linux-uvc-devel mailing list.\n"); } + if (dev->info->uvc_version) { + dev->uvc_version = dev->info->uvc_version; + uvc_printk(KERN_INFO, "Forcing UVC version to %u.%02x\n", + dev->uvc_version >> 8, dev->uvc_version & 0xff); + } + /* Register the V4L2 device. */ if (v4l2_device_register(&intf->dev, &dev->vdev) < 0) goto error; @@ -2923,6 +2929,17 @@ static const struct usb_device_id uvc_ids[] = { .bInterfaceSubClass = 1, .bInterfaceProtocol = 0, .driver_info = (kernel_ulong_t)&uvc_quirk_probe_minmax }, + /* Shenzhen Aoni Electronic Co.,Ltd 2K FHD camera */ + { .match_flags = USB_DEVICE_ID_MATCH_DEVICE + | USB_DEVICE_ID_MATCH_INT_INFO, + .idVendor = 0x1bcf, + .idProduct = 0x0b40, + .bInterfaceClass = USB_CLASS_VIDEO, + .bInterfaceSubClass = 1, + .bInterfaceProtocol = 0, + .driver_info = (kernel_ulong_t)&(const struct uvc_device_info){ + .uvc_version = 0x010a, + } }, /* SiGma Micro USB Web Camera */ { .match_flags = USB_DEVICE_ID_MATCH_DEVICE | USB_DEVICE_ID_MATCH_INT_INFO, diff --git a/drivers/media/usb/uvc/uvcvideo.h b/drivers/media/usb/uvc/uvcvideo.h index a3dfacf069c4..8ec9eca07f06 100644 --- a/drivers/media/usb/uvc/uvcvideo.h +++ b/drivers/media/usb/uvc/uvcvideo.h @@ -635,6 +635,7 @@ static inline u32 uvc_urb_index(const struct uvc_urb *uvc_urb) struct uvc_device_info { u32 quirks; u32 meta_format; + u16 uvc_version; }; struct uvc_device { -- Regards, Laurent Pinchart