summaryrefslogtreecommitdiff
path: root/scripts/Makefile.thinlto
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2026-09-10 17:52:23 +0200
committerTakashi Iwai <tiwai@suse.de>2026-09-12 14:18:14 +0200
commit221253723dc58bb901c3f27a7659823e63fc598c (patch)
treecb3d2f1922d60acdc0a6e91cc7bbc283a3cb5353 /scripts/Makefile.thinlto
parent5cddf63367ef894ba0026dfa2d524346f7048de9 (diff)
downloadlinux-stable-221253723dc58bb901c3f27a7659823e63fc598c.tar.gz
linux-stable-221253723dc58bb901c3f27a7659823e63fc598c.zip
ALSA: bcd2000: Fix race between rawmidi and disconnect
Although we tried to fix the potential UAF issues at USB disconnect on bcd2000 driver, there is still an overlooked case -- namely, when a rawmidi trigger callback has been already running at USB disconnect handling, the in-flight function (e.g. bcd2000_midi_send()) could still access the URB, because the previous URB NULL-check & clearance was considered only for the URB complete callbacks, but not about the parallel rawmidi operations. For addressing the race, this patch introduced a new spinlock that covers each rawmidi operation as well as the rawmidi handling in the complete callback. The URB is cleared with the lock, so it guarantees that the pending rawmidi task already finished or a NULL check is effective. Fixes: 459d3a64766f ("ALSA: bcd2000: clear the URB pointers on disconnect") Link: https://patch.msgid.link/20260910155227.996210-1-tiwai@suse.de Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'scripts/Makefile.thinlto')
0 files changed, 0 insertions, 0 deletions