diff options
| author | Ye Weihua <yeweihua4@huawei.com> | 2026-11-16 06:48:49 +0000 |
|---|---|---|
| committer | Takashi Iwai <tiwai@suse.de> | 2026-11-16 16:31:16 +0100 |
| commit | bc3d6817c5325e76578cdd75e9c08bdadc5f73c4 (patch) | |
| tree | 08aabe92521fd51c7a17b7e03bbcea218c20ef0a /include/linux/dynamic_queue_limits.h | |
| parent | 156282337a4bc9083d821fa229e85fcaefae38bb (diff) | |
ALSA: pcm: oss: Restore params flag after failed reconfiguration
snd_pcm_runtime_buffer_set_silence() may fail with -EBUSY when a
concurrent PCM transfer is accessing the buffer. The error path
releases runtime->oss.buffer and clears the plugins, but leaves
runtime->oss.params cleared as well. A subsequent small read/write
then skips the reconfiguration and dereferences the released buffer:
Unable to handle kernel NULL pointer dereference at virtual address
0000000000000000
pc : __arch_copy_from_user+0x78/0x23c
lr : snd_pcm_oss_write+0x10c/0x340 [snd_pcm_oss]
Restore runtime->oss.params on the error path so that the next OSS
operation reconfigures and reallocates the buffer.
Fixes: 47c27c9c9c72 ("ALSA: pcm: Improve the fix for race of buffer access at PCM OSS layer")
Cc: stable@vger.kernel.org
Signed-off-by: Ye Weihua <yeweihua4@huawei.com>
Link: https://patch.msgid.link/20261116064850.3540576-1-yeweihua4@huawei.com
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'include/linux/dynamic_queue_limits.h')
0 files changed, 0 insertions, 0 deletions
