[alsa-devel] Locking/mutex for snd_pcm_update_hw_ptr0() call
Alan Young
Alan.Young at IEE.org
Mon Nov 7 15:56:00 CET 2016
On 07/11/16 14:15, Clemens Ladisch wrote:
> Alan Young wrote:
>> It is possible that the DMA interrupt handler could call
>> snd_pcm_update_hw_ptr0() while it is part way through a call
>> from snd_pcm_status(), or vice versa?
> The *lock_irq* functions disable interrupts on the current CPU.
>
>
But only on the current CPU? So that would imply that multiple threads
could execute snd_pcm_update_hw_ptr0() simultaneously on multi-CPU systems.
Even on a single-CPU system, I presume that the interrupt handler cannot
be pre-empted by a user-space call such as snd_pcm_status(). Is that
correct?
Alan.
More information about the Alsa-devel
mailing list