diff options
author | Takashi Iwai <tiwai@suse.de> | 2021-01-20 22:39:32 +0100 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2021-01-21 12:47:19 +0100 |
commit | 85db1cfb13e37d24be225739dc0e2da478dd2c1c (patch) | |
tree | 89aae4bc54c7c7cbf69a2db5a5833deb922e17d7 /sound/usb/mixer.c | |
parent | 086b957cc17f53f03bae9d2baf930ac51cf68b99 (diff) |
ALSA: usb-audio: Fix "RANGE setting not yet supported" errors
At probing a UAC2/UAC3 device like NUX MG-300 USB interface, we get
error messages "RANGE setting not yet supported". It comes the place
where the driver tries to determine the resolution of mixer volumes
via SET_CUR_RES and GET_CUR_RES verbs. Those verbs aren't supported
on UAC2 and UAC3, hence the driver warns like the above. Although the
driver handles this error and works as expected, it's still ugly to
show such errors unnecessarily.
This patch papers over the errors by applying the resolution detection
only for UAC1 and skipping it for UAC2/UAC3.
Reported-by: Mike Oliphant <oliphant@nostatic.org>
Link: https://lore.kernel.org/r/20210120213932.1971-2-tiwai@suse.de
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/usb/mixer.c')
-rw-r--r-- | sound/usb/mixer.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/usb/mixer.c b/sound/usb/mixer.c index c7da38348035..b1c78db0d470 100644 --- a/sound/usb/mixer.c +++ b/sound/usb/mixer.c @@ -1238,7 +1238,7 @@ static int get_min_max_with_quirks(struct usb_mixer_elem_info *cval, (cval->control << 8) | minchn, &cval->res) < 0) { cval->res = 1; - } else { + } else if (cval->head.mixer->protocol == UAC_VERSION_1) { int last_valid_res = cval->res; while (cval->res > 1) { |