mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-11-30 15:53:22 -05:00
ALSA: mixer: fix deadlock in snd_mixer_oss_set_volume
commit 3ab7992018455ac63c33e9b3eaa7264e293e40f4 upstream.
In commit 411cef6adfb3 ("ALSA: mixer: oss: Fix racy access to slots")
added mutex protection in snd_mixer_oss_set_volume(). Second
mutex_lock() in same function looks like typo, fix it.
Reported-by: [email protected]
Fixes: 411cef6adfb3 ("ALSA: mixer: oss: Fix racy access to slots")
Cc: <[email protected]>
Signed-off-by: Pavel Skripkin <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Takashi Iwai <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
This commit is contained in:
parent
6225a31b2e
commit
3f6255a91b
1 changed files with 1 additions and 1 deletions
|
|
@ -313,7 +313,7 @@ static int snd_mixer_oss_set_volume(struct snd_mixer_oss_file *fmixer,
|
|||
pslot->volume[1] = right;
|
||||
result = (left & 0xff) | ((right & 0xff) << 8);
|
||||
unlock:
|
||||
mutex_lock(&mixer->reg_mutex);
|
||||
mutex_unlock(&mixer->reg_mutex);
|
||||
return result;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue