]> git.karo-electronics.de Git - karo-tx-linux.git/commit
ALSA: Fix yet another race in disconnection
authorTakashi Iwai <tiwai@suse.de>
Thu, 24 Mar 2011 08:50:15 +0000 (09:50 +0100)
committerAK <andi@firstfloor.org>
Thu, 31 Mar 2011 18:58:48 +0000 (11:58 -0700)
commited2debec5324a5382823bbfca2d493424f2d78f0
tree0c4b6f986b681e2e7dab397263ee4a4958b41888
parent083dda3eb79e0ec653ed81ffe9cc2c29cc8ab1b8
ALSA: Fix yet another race in disconnection

commit a45e3d6b13e97506b616980c0f122c3389bcefa4 upstream.

This patch fixes a race between snd_card_file_remove() and
snd_card_disconnect().  When the card is added to shutdown_files list
in snd_card_disconnect(), but it's freed in snd_card_file_remove() at
the same time, the shutdown_files list gets corrupted.  The list member
must be freed in snd_card_file_remove() as well.

Reported-and-tested-by: Russ Dill <russ.dill@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Andi Kleen <ak@linux.intel.com>
sound/core/init.c