summaryrefslogtreecommitdiff
path: root/sound/usb/quirks-table.h
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2018-12-19 14:04:47 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-01-13 09:51:06 +0100
commitb389f9c4c97ac438174b9409b372208dea62821f (patch)
tree59b6f0f7502b12906706b856189fc4fe1c417ce4 /sound/usb/quirks-table.h
parent8ee6f180d56fe760b275ab7f060c7b12fc05d7b7 (diff)
ALSA: usb-audio: Check mixer unit descriptors more strictly
commit 0bfe5e434e6665b3590575ec3c5e4f86a1ce51c9 upstream. We've had some sanity checks of the mixer unit descriptors but they are too loose and some corner cases are overlooked. Add more strict checks in uac_mixer_unit_get_channels() for avoiding possible OOB accesses by malformed descriptors. This also changes the semantics of uac_mixer_unit_get_channels() slightly. Now it returns zero for the cases where the descriptor lacks of bmControls instead of -EINVAL. Then the caller side skips the mixer creation for such unit while it keeps parsing it. This corresponds to the case like Maya44. Cc: <stable@vger.kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'sound/usb/quirks-table.h')
0 files changed, 0 insertions, 0 deletions