android_kernel_oneplus_msm8998/sound/pci/rme9652
Takashi Iwai 4984b8bb89 ALSA: rme9652: Hardening for potential Spectre v1
commit f526afcd8f71945c23ce581d7864ace93de8a4f7 upstream.

As recently Smatch suggested, one place in RME9652 driver may expand
the array directly from the user-space value with speculation:
  sound/pci/rme9652/rme9652.c:2074 snd_rme9652_channel_info() warn: potential spectre issue 'rme9652->channel_map' (local cap)

This patch puts array_index_nospec() for hardening against it.

BugLink: https://marc.info/?l=linux-kernel&m=152411496503418&w=2
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Cc: <stable@vger.kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-02 07:53:41 -07:00
..
hdsp.c ALSA: hdsp: Fix wrong boolean ctl value accesses 2016-03-09 15:34:54 -08:00
hdspm.c ALSA: hdspm: Hardening for potential Spectre v1 2018-05-02 07:53:41 -07:00
Makefile [ALSA] Changed Jaroslav Kysela's e-mail from perex@suse.cz to perex@perex.cz 2007-10-16 16:51:18 +02:00
rme9652.c ALSA: rme9652: Hardening for potential Spectre v1 2018-05-02 07:53:41 -07:00