android_kernel_samsung_msm8976/include/sound
Takashi Iwai 0f8f354d6c ALSA: pcm: Return -EBUSY for OSS ioctls changing busy streams
commit 40cab6e88cb0b6c56d3f30b7491a20e803f948f6 upstream.

OSS PCM stream management isn't modal but it allows ioctls issued at
any time for changing the parameters.  In the previous hardening
patch ("ALSA: pcm: Avoid potential races between OSS ioctls and
read/write"), we covered these races and prevent the corruption by
protecting the concurrent accesses via params_lock mutex.  However,
this means that some ioctls that try to change the stream parameter
(e.g. channels or format) would be blocked until the read/write
finishes, and it may take really long.

Basically changing the parameter while reading/writing is an invalid
operation, hence it's even more user-friendly from the API POV if it
returns -EBUSY in such a situation.

This patch adds such checks in the relevant ioctls with the addition
of read/write access refcount.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
2019-07-27 21:52:25 +02:00
..
ac97_codec.h
aci.h
ad1816a.h
ad1843.h
adau1373.h
adsp_err.h
aess.h
ak4xxx-adda.h
ak4113.h
ak4114.h
ak4117.h
ak4531_codec.h
ak4641.h
alc5623.h
apr_audio-v2.h
apr_audio.h
asequencer.h
asound.h
asoundef.h
atmel-abdac.h
atmel-ac97c.h
audio_cal_utils.h
audio_calibration.h
audio_slimslave.h
compress_driver.h
control.h ALSA: control: Hardening for potential Spectre v1 2019-07-27 21:52:05 +02:00
core.h
cpe_cmi.h
cpe_core.h
cs42l52.h
cs4231-regs.h
cs4271.h
cs8403.h
cs8427.h
da7213.h
da9055.h
designware_i2s.h
dmaengine_pcm.h
emu10k1.h
emu10k1_synth.h
emu8000.h
emu8000_reg.h
emux_legacy.h
emux_synth.h
es1688.h
gus.h
hda_hwdep.h
hwdep.h
i2c.h
info.h
initval.h
jack.h
l3.h
max9768.h
max98088.h
max98090.h
max98095.h
memalloc.h
minors.h
mixer_oss.h
mpu401.h
msm-audio-effects-q6-v2.h
msm-dai-q6-v2.h
msm-slim-dma.h
opl3.h
opl4.h
pcm-indirect.h
pcm.h Merge "ALSA: pcm: use lock to protect substream runtime resource" 2018-01-22 19:30:03 -08:00
pcm_oss.h ALSA: pcm: Return -EBUSY for OSS ioctls changing busy streams 2019-07-27 21:52:25 +02:00
pcm_params.h
pt2258.h
pxa2xx-lib.h
q6adm-v2.h Merge tag 'LA.BR.1.3.6-03910-8976.0' of https://source.codeaurora.org/quic/la/kernel/msm-3.10 into HEAD 2017-05-26 13:28:48 +02:00
q6afe-v2.h
q6asm-v2.h
q6audio-v2.h
q6core.h
q6lsm.h
rawmidi.h ANDROID: sound: rawmidi: Hold lock around realloc 2018-05-26 00:39:34 +02:00
rt5659.h
s3c24xx_uda134x.h
sb.h
sb16_csp.h
seq_device.h
seq_kernel.h ALSA: seq: Avoid invalid lockdep class warning 2019-07-27 21:45:44 +02:00
seq_midi_emul.h
seq_midi_event.h
seq_oss.h
seq_oss_legacy.h
seq_virmidi.h ALSA: seq: Fix copy_from_user() call inside lock 2019-07-27 21:45:36 +02:00
sh_dac_audio.h
sh_fsi.h
simple_card.h
snd_wavefront.h
soc-dai.h
soc-dapm.h
soc-dpcm.h
soc.h
soundfont.h
spear_dma.h
spear_spdif.h
sta32x.h
tas5086.h
tea575x-tuner.h
tea6330t.h
timer.h ALSA: timer: Limit max instances per timer 2019-07-27 21:45:43 +02:00
tlv.h
tlv320aic3x.h
tlv320aic32x4.h
tlv320dac33-plat.h
tpa6130a2-plat.h
uda134x.h
uda1380.h
util_mem.h
voice_params.h
voice_svc.h
vx_core.h
wavefront.h
wm0010.h
wm1250-ev1.h
wm2000.h
wm2200.h
wm5100.h
wm8903.h
wm8904.h
wm8955.h
wm8960.h
wm8962.h
wm8993.h
wm8996.h
wm9081.h
wm9090.h
wss.h