Linux USB
 help / color / mirror / Atom feed
From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
To: Oliver Neukum <oneukum@suse.com>
Cc: marco@zatta.me, USB list <linux-usb@vger.kernel.org>
Subject: Re: Something is really broken for Logitech webcams
Date: Thu, 27 Jul 2023 22:38:44 +0300	[thread overview]
Message-ID: <20230727193844.GB16455@pendragon.ideasonboard.com> (raw)
In-Reply-To: <6dcde4c2-9400-44af-c8b4-5e63b947a2bf@suse.com>

Hi Oliver,

On Thu, Jul 27, 2023 at 01:48:28PM +0200, Oliver Neukum wrote:
> Hi,
> 
> looking at bd21f0222adab
> ("USB: Fix chipmunk-like voice when using Logitech C270 for recording audio.")
> we see that it introduced RESET_RESUME for the C270 webcam
> 
> For that camera I asked a user to provide lsusb, which got this
> (a bit shortened)
> 
> Bus 001 Device 004: ID 046d:0825 Logitech, Inc. Webcam C270
> Device Descriptor:
>    bLength                18
>    bDescriptorType         1
>    bcdUSB               2.00
>    bDeviceClass          239 Miscellaneous Device
>    bDeviceSubClass         2
>    bDeviceProtocol         1 Interface Association
>    bMaxPacketSize0        64
>    idVendor           0x046d Logitech, Inc.
>    idProduct          0x0825 Webcam C270
> 
>      Interface Descriptor:
>        bLength                 9
>        bDescriptorType         4
>        bInterfaceNumber        0
>        bAlternateSetting       0
>        bNumEndpoints           1
>        bInterfaceClass        14 Video
>        bInterfaceSubClass      1 Video Control
>        bInterfaceProtocol      0
>        iInterface              0
> 
> So this thing says that it is UVC. That means that it should trigger
> e387ef5c47dde ("usb: Add USB_QUIRK_RESET_RESUME for all Logitech UVC webcams")
> adding the following declaration:
> 
> static const struct usb_device_id usb_interface_quirk_list[] = {
>          /* Logitech UVC Cameras */
>          { USB_VENDOR_AND_INTERFACE_INFO(0x046d, USB_CLASS_VIDEO, 1, 0),
>            .driver_info = USB_QUIRK_RESET_RESUME },
> 
> wich AFAICT matches the device.
> 
> On the face of it, this makes no sense. What is going on here?
> Do we really need to assume that Logitech has been selling a whole slew
> of cameras in both UVC and something else, which we have no driver for,
> but nobody complains?

The first Logitech webcams that were developed against the UVC
specification were not fully UVC-compatible. They were thus advertised
with a vendor-specific class. The uvcvideo driver supports them, you can
find the list in uvc_driver.c:

Logitech Quickcam Fusion			0x08c1
Logitech Quickcam Orbit MP			0x08c2
Logitech Quickcam Pro for Notebook		0x08c3
Logitech Quickcam Pro 5000			0x08c5
Logitech Quickcam OEM Dell Notebook		0x08c6
Logitech Quickcam OEM Cisco VT Camera II	0x08c7

This explains why usb_quirk_list has 6 corresponding entries.

Why Marco's patch is needed, I'm not sure. It seems that the device and
interface quirks are handled at different points of time, maybe that
plays a role ?

> Could somebody please look at this or am I somehow not right in the head?
> 
> And Marco specifically, did you make your patch based on a bisection?

-- 
Regards,

Laurent Pinchart

      parent reply	other threads:[~2023-07-27 19:38 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-07-27 11:48 Something is really broken for Logitech webcams Oliver Neukum
2023-07-27 17:40 ` marco
2023-07-27 19:06   ` Oliver Neukum
2023-07-27 19:38 ` Laurent Pinchart [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230727193844.GB16455@pendragon.ideasonboard.com \
    --to=laurent.pinchart@ideasonboard.com \
    --cc=linux-usb@vger.kernel.org \
    --cc=marco@zatta.me \
    --cc=oneukum@suse.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox