android_kernel_motorola_sm6225/sound/usb
Takashi Iwai 1b4ea92e45 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>
2020-12-30 11:25:42 +01:00
..
6fire
bcd2000
caiaq
hiface
line6 ALSA: line6: Sync the pending work cancel at disconnection 2020-07-22 09:32:08 +02:00
misc
usx2y ALSA: usx2y: Fix potential NULL dereference 2020-04-29 16:31:28 +02:00
card.c ALSA: usb-audio: Rewrite registration quirk handling 2020-07-22 09:32:04 +02:00
card.h ALSA: usb-audio: work around streaming quirk for MacroSilicon MS2109 2020-08-19 08:15:04 +02:00
clock.c ALSA: usb-audio: Add clock validity quirk for Denon MC7000/MCX8000 2020-02-19 19:51:54 +01:00
clock.h ALSA: usb-audio: Add clock validity quirk for Denon MC7000/MCX8000 2020-02-19 19:51:54 +01:00
debug.h
endpoint.c Revert "ALSA: usb-audio: Improve frames size computation" 2020-07-09 09:37:12 +02:00
endpoint.h Revert "ALSA: usb-audio: Improve frames size computation" 2020-07-09 09:37:12 +02:00
format.c ALSA: usb-audio: Fix potential out-of-bounds shift 2020-12-30 11:25:42 +01:00
format.h
helper.c
helper.h
Kconfig
Makefile
midi.c ALSA: usb-audio: Fix case when USB MIDI interface has more than one extra endpoint descriptor 2020-10-01 13:14:41 +02:00
midi.h
mixer.c ALSA: usb-audio: Don't create a mixer element with bogus volume range 2020-10-01 13:14:34 +02:00
mixer.h ALSA: usb-audio: Fix OOB access of mixer element list 2020-06-30 23:17:08 -04:00
mixer_maps.c ALSA: usb-audio: Quirks for Gigabyte TRX40 Aorus Master onboard audio 2020-06-03 08:19:39 +02:00
mixer_quirks.c ALSA: usb-audio: Creative USB X-Fi Pro SB1095 volume knob support 2020-08-19 08:15:04 +02:00
mixer_quirks.h
mixer_scarlett.c
mixer_scarlett.h
mixer_us16x08.c ALSA: usb-audio: US16x08: fix value count for level meters 2020-12-08 10:18:55 +01:00
mixer_us16x08.h
pcm.c ALSA: usb-audio: Add implicit feedback quirk for MODX 2020-11-10 12:35:57 +01:00
pcm.h
power.c
power.h
proc.c
proc.h
quirks-table.h ALSA: usb-audio: Update documentation comment for MS2109 quirk 2020-09-03 11:24:31 +02:00
quirks.c ALSA: usb-audio: Add delay quirk for all Logitech USB devices 2020-11-24 13:27:24 +01:00
quirks.h ALSA: usb-audio: Rewrite registration quirk handling 2020-07-22 09:32:04 +02:00
stream.c ALSA: usb-audio: Fix control 'access overflow' errors from chmap 2020-12-30 11:25:42 +01:00
stream.h
usbaudio.h ALSA: usb-audio: Fix inconsistent card PM state after resume 2020-06-22 09:05:02 +02:00
validate.c ALSA: usb-audio: Fix endianess in descriptor validation 2020-02-11 04:33:56 -08:00