android_kernel_google_msm/sound/pci
Dan Carpenter 26ea9e4d43 ALSA: off by one bug in snd_riptide_joystick_probe()
commit e4940626defdf6c92da1052ad3f12741c1a28c90 upstream.

The problem here is that we check:

	if (dev >= SNDRV_CARDS)

Then we increment "dev".

       if (!joystick_port[dev++])

Then we use it as an offset into a array with SNDRV_CARDS elements.

	if (!request_region(joystick_port[dev], 8, "Riptide gameport")) {

This has 3 effects:
1) If you use the module option to specify the joystick port then it has
   to be shifted one space over.
2) The wrong error message will be printed on failure if you have over
   32 cards.
3) Static checkers will correctly complain that are off by one.

Fixes: db1005ec6f ('ALSA: riptide - Fix joystick resource handling')
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Zefan Li <lizefan@huawei.com>
2015-06-19 11:40:14 +08:00
..
ac97 ALSA: ac97 - Fix missing NULL check in snd_ac97_cvol_new() 2012-10-21 09:28:02 -07:00
ali5451 ALSA: ali5451: remove irq enabling in pointer callback 2013-02-28 06:58:59 -08:00
asihpi ALSA: asihpi: Fix unlocked snd_pcm_stop() call 2014-03-11 16:10:09 -07:00
au88x0
aw2
ca0106
cs46xx
cs5535audio
ctxfi
echoaudio
emu10k1 ALSA: emu10k1: Fix deadlock in synth voice lookup 2015-02-02 17:04:50 +08:00
hda ALSA: hda - Fix wrong gpio_dir & gpio_mask hint setups for IDT/STAC codecs 2015-04-14 17:33:49 +08:00
ice1712 ALSA: ice1712: Fix boundary checks in PCM pointer ops 2014-05-06 07:51:40 -07:00
korg1212
lola
lx6464es
mixart
nm256
oxygen ALSA: oxygen: modify adjust_dg_dac_routing function 2014-03-23 21:37:08 -07:00
pcxhr
riptide ALSA: off by one bug in snd_riptide_joystick_probe() 2015-06-19 11:40:14 +08:00
rme9652 ALSA: rme9652: fix a missing comma in channel_map_9636_ds[] 2014-02-06 11:05:47 -08:00
trident
vx222
ymfpci
ad1889.c
ad1889.h
ak4531_codec.c
als300.c
als4000.c
atiixp.c ALSA: atiixp: Fix unlocked snd_pcm_stop() call 2014-03-11 16:10:08 -07:00
atiixp_modem.c ALSA: atiixp: Fix unlocked snd_pcm_stop() call 2014-03-11 16:10:08 -07:00
azt3328.c
azt3328.h
bt87x.c
cmipci.c
cs4281.c
cs5530.c
ens1370.c
ens1371.c
es1938.c
es1968.c
fm801.c
intel8x0.c
intel8x0m.c
Kconfig ALSA: Enable CONFIG_ZONE_DMA for smaller PCI DMA masks 2014-02-06 11:05:47 -08:00
maestro3.c
Makefile
rme32.c ALSA: rme32.c irq enabling after spin_lock_irq 2013-02-28 06:58:59 -08:00
rme96.c
sis7019.c
sis7019.h
sonicvibes.c
via82xx.c
via82xx_modem.c