]> git.hungrycats.org Git - linux/commit
ALSA: emu10k1: don't deadlock in proc-functions
authorMichael Gernoth <michael@gernoth.net>
Thu, 9 Apr 2015 21:42:15 +0000 (23:42 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 6 May 2015 20:01:52 +0000 (22:01 +0200)
commit3f29324d1345690dde2207d8a1e7b436d4e38f01
tree9234bc12498c7551a2846b235db79e3a5b6fa053
parente17b67c96fa7c21966b9201ec155034dd53a4e55
ALSA: emu10k1: don't deadlock in proc-functions

commit 91bf0c2dcb935a87e5c0795f5047456b965fd143 upstream.

The functions snd_emu10k1_proc_spdif_read and snd_emu1010_fpga_read
acquire the emu_lock before accessing the FPGA. The function used
to access the FPGA (snd_emu1010_fpga_read) also tries to take
the emu_lock which causes a deadlock.
Remove the outer locking in the proc-functions (guarding only the
already safe fpga read) to prevent this deadlock.

[removed superfluous flags variables too -- tiwai]

Signed-off-by: Michael Gernoth <michael@gernoth.net>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
sound/pci/emu10k1/emuproc.c