summaryrefslogtreecommitdiff
path: root/sound/soc
diff options
context:
space:
mode:
authorAndrew Gabbasov <andrew_gabbasov@mentor.com>2019-11-22 11:52:17 -0600
committerTakashi Iwai <tiwai@suse.de>2019-11-22 19:11:23 +0100
commitc037239c2373f79613dac32d0fb20c07f12f719b (patch)
treedd28c629626c8b0347a50113077bc53f9f8781af /sound/soc
parent1e5ddb6ba73894e6186e6379dde870979852af6d (diff)
ALSA: aloop: Remove redundant locking in timer open function
loopback_parse_timer_id() uses snd_card_ref(), that can lock on mutex, also snd_timer_instance_new() uses non-atomic allocation, that can sleep. So, both functions can not be called from loopback_snd_timer_open() with cable->lock spinlock locked. Moreover, most part of loopback_snd_timer_open() function body works when the opposite stream of the same cable does not yet exist, and the current stream is not yet completely open and can't be running, so existing locking of loopback->cable_lock mutex is enough to protect from conflicts with simultaneous opening or closing. Locking of cable->lock spinlock is not needed in this case. Fixes: 26c53379f98d ("ALSA: aloop: Support selection of snd_timer instead of jiffies") Signed-off-by: Andrew Gabbasov <andrew_gabbasov@mentor.com> Link: https://lore.kernel.org/r/20191122175218.17187-1-andrew_gabbasov@mentor.com Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/soc')
0 files changed, 0 insertions, 0 deletions