[BUG] ALSA: usb-audio: Scarlett 2 mixer driver fails on ehci-pci

Geraldo Nascimento geraldogabriel at gmail.com
Thu May 20 22:00:15 CEST 2021


On Thu, May 20, 2021 at 3:14 PM Geoffrey D. Bennett <g at b4.vu> wrote:
>
> On Tue, May 18, 2021 at 06:41:45PM -0300, Geraldo Nascimento wrote:
> [...]
> > Myself I'd hook printk()'s to both ehci_hcd and xhci_hcd to print
> > every possible variable involved and see if there's any relevant
> > mismatches. Oh and watch with the printk()'s what libusb seems to be
> > doing, too.
> >
> > When you subscribe to linux-usb you *may* want to Cc: Greg
> > Kroah-Hartman with your discoveries so far, he's the USB Subsystem
> > Maintainer and the best one to help you track this down.
>
> Thanks for the pointers!
>
> It turns out that usb_sndctrlpipe() is not short for "USB sound
> control pipe".
>
> diff --git a/sound/usb/mixer_scarlett_gen2.c b/sound/usb/mixer_scarlett_gen2.c
> index 560c2ade829d..dcff3e3a49f3 100644
> --- a/sound/usb/mixer_scarlett_gen2.c
> +++ b/sound/usb/mixer_scarlett_gen2.c
> @@ -635,7 +635,7 @@ static int scarlett2_usb(
>         /* send a second message to get the response */
>
>         err = snd_usb_ctl_msg(mixer->chip->dev,
> -                       usb_sndctrlpipe(mixer->chip->dev, 0),
> +                       usb_rcvctrlpipe(mixer->chip->dev, 0),
>                         SCARLETT2_USB_VENDOR_SPECIFIC_CMD_RESP,
>                         USB_RECIP_INTERFACE | USB_TYPE_CLASS | USB_DIR_IN,
>                         0,
>
> I'll properly submit the patch once I've got confirmation from someone
> else that this fixes the issue.

Good, I also think the correct pipe to use together with USB_DIR_IN is
indeed usb_rcvctrlpipe().

>
> Thanks again,
> Geoffrey.


More information about the Alsa-devel mailing list