diff options
author | Takashi Iwai <tiwai@suse.de> | 2021-07-29 09:44:01 +0200 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2021-08-02 09:06:05 +0200 |
commit | 3c69dc9134130deb9682279374d9d97de52b0731 (patch) | |
tree | 7c0c654b680fd82189a0879f6e4d254278872f5d /sound/usb/card.c | |
parent | 44e6fc64dfebf48811219a9c24666b4b87dc0ec5 (diff) | |
download | linux-stable-3c69dc9134130deb9682279374d9d97de52b0731.tar.gz linux-stable-3c69dc9134130deb9682279374d9d97de52b0731.tar.bz2 linux-stable-3c69dc9134130deb9682279374d9d97de52b0731.zip |
ALSA: usb-audio: Move ignore_ctl_error check into quirk_flags
The mixer code has a flag ignore_ctl_error for ignoring the errors
returned from the device wrt mixer accesses, and this is set from the
entries in mixer_maps.c, as well as ignore_ctl_error module option.
Those can be well integrated into the new quirk_flags field, too.
Link: https://lore.kernel.org/r/20210729074404.19728-3-tiwai@suse.de
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/usb/card.c')
-rw-r--r-- | sound/usb/card.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sound/usb/card.c b/sound/usb/card.c index d66a3788111c..9535df39c02f 100644 --- a/sound/usb/card.c +++ b/sound/usb/card.c @@ -804,6 +804,9 @@ static int usb_audio_probe(struct usb_interface *intf, dev_set_drvdata(&dev->dev, chip); + if (ignore_ctl_error) + chip->quirk_flags |= QUIRK_FLAG_IGNORE_CTL_ERROR; + if (chip->quirk_flags & QUIRK_FLAG_DISABLE_AUTOSUSPEND) usb_disable_autosuspend(interface_to_usbdev(intf)); @@ -828,7 +831,7 @@ static int usb_audio_probe(struct usb_interface *intf, err = snd_usb_create_streams(chip, ifnum); if (err < 0) goto __error; - err = snd_usb_create_mixer(chip, ifnum, ignore_ctl_error); + err = snd_usb_create_mixer(chip, ifnum); if (err < 0) goto __error; } |