Skip to content
Commit 81c254a6 authored by Dan Carpenter's avatar Dan Carpenter Committed by Takashi Iwai
Browse files

ALSA: fireface: fix locking bug in ff400_copy_msg_to_user()



The ff400_copy_msg_to_user() function drops the spin lock to call
copy_to_user().  However, if the copy_to_user() fails, then it must
take the lock again before returning.  Failure to take the lock leads
to a double unlock in the caller, hwdep_read().

Fixes: acdebd8b ("ALSA: fireface: implement message parser for Fireface 400")
Signed-off-by: default avatarDan Carpenter <error27@gmail.com>
Acked-by: default avatarTakashi Sakamoto <o-takashi@sakamocchi.jp>
Link: https://lore.kernel.org/r/Y8at+W/7OGvEBY8O@kili


Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
parent 3ee0fe7f
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment