TencentOS-kernel/sound/usb
Takashi Iwai 480c9a03da ALSA: usb-audio: Fix control 'access overflow' errors from chmap
commit c6dde8ffd071aea9d1ce64279178e470977b235c upstream.

The current channel-map control implementation in USB-audio driver may
lead to an error message like
  "control 3:0:0:Playback Channel Map:0: access overflow"
when CONFIG_SND_CTL_VALIDATION is set.  It's because the chmap get
callback clears the whole array no matter which count is set, and
rather the false-positive detection.

This patch fixes the problem by clearing only the needed array range
at usb_chmap_ctl_get().

Cc: <stable@vger.kernel.org>
Link: https://lore.kernel.org/r/20201211130048.6358-1-tiwai@suse.de
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2021-03-16 16:42:20 +08:00
..
6fire Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
bcd2000 Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
caiaq Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
hiface Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
line6 ALSA: line6: Sync the pending work cancel at disconnection 2021-03-16 16:32:06 +08:00
misc Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
usx2y ALSA: usx2y: Fix potential NULL dereference 2021-03-16 16:26:57 +08:00
Kconfig Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
Makefile Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
card.c ALSA: usb-audio: Rewrite registration quirk handling 2021-03-16 16:31:56 +08:00
card.h ALSA: usb-audio: work around streaming quirk for MacroSilicon MS2109 2021-03-16 16:33:51 +08:00
clock.c ALSA: usb-audio: Add support for MOTU MicroBook IIc 2021-03-16 16:31:55 +08:00
clock.h Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
debug.h Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
endpoint.c Revert "ALSA: usb-audio: Improve frames size computation" 2021-03-16 16:31:20 +08:00
endpoint.h Revert "ALSA: usb-audio: Improve frames size computation" 2021-03-16 16:31:20 +08:00
format.c ALSA: usb-audio: Fix potential out-of-bounds shift 2021-03-16 16:42:20 +08:00
format.h Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
helper.c Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
helper.h Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
media.c Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
media.h Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
midi.c ALSA: usb-audio: Fix case when USB MIDI interface has more than one extra endpoint descriptor 2021-03-16 16:37:09 +08:00
midi.h Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
mixer.c ALSA: usb-audio: Don't create a mixer element with bogus volume range 2021-03-16 16:36:53 +08:00
mixer.h ALSA: usb-audio: Fix OOB access of mixer element list 2021-03-16 16:30:52 +08:00
mixer_maps.c ALSA: usb-audio: Quirks for Gigabyte TRX40 Aorus Master onboard audio 2021-03-16 16:28:35 +08:00
mixer_quirks.c ALSA: usb-audio: Creative USB X-Fi Pro SB1095 volume knob support 2021-03-16 16:33:50 +08:00
mixer_quirks.h Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
mixer_scarlett.c Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
mixer_scarlett.h Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
mixer_scarlett_gen2.c Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
mixer_scarlett_gen2.h Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
mixer_us16x08.c ALSA: usb-audio: US16x08: fix value count for level meters 2021-03-16 16:41:58 +08:00
mixer_us16x08.h Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
pcm.c ALSA: usb-audio: Add implicit feedback quirk for MODX 2021-03-16 16:40:21 +08:00
pcm.h Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
power.c Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
power.h Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
proc.c Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
proc.h Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
quirks-table.h ALSA: usb-audio: Update documentation comment for MS2109 quirk 2021-03-16 16:35:20 +08:00
quirks.c ALSA: usb-audio: Add delay quirk for all Logitech USB devices 2021-03-16 16:41:25 +08:00
quirks.h ALSA: usb-audio: Rewrite registration quirk handling 2021-03-16 16:31:56 +08:00
stream.c ALSA: usb-audio: Fix control 'access overflow' errors from chmap 2021-03-16 16:42:20 +08:00
stream.h Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00
usbaudio.h ALSA: usb-audio: Fix inconsistent card PM state after resume 2021-03-16 16:29:02 +08:00
validate.c Init Repo base on linux 5.4.32 long term, and add base tlinux kernel interfaces. 2021-03-16 11:01:34 +08:00