Re: [PATCH] ALSA: pcm: retrieve true appl_ptr where stream was unlocked

2013-11-12 Thread Takashi Iwai
At 12 Nov 2013 16:14:17 +, Oskar Schirmer wrote: > > Calculated for data transfer, the local variable appl_ptr is reused, > changed and written back later, though the lock was not held during > the transfer earlier. Admitted, destiny of the lock is not obvious > at all, but this looks much

[PATCH] ALSA: pcm: retrieve true appl_ptr where stream was unlocked

2013-11-12 Thread Oskar Schirmer
Calculated for data transfer, the local variable appl_ptr is reused, changed and written back later, though the lock was not held during the transfer earlier. Admitted, destiny of the lock is not obvious at all, but this looks much like a race condition candidate, so make sure to have some

[PATCH] ALSA: pcm: retrieve true appl_ptr where stream was unlocked

2013-11-12 Thread Oskar Schirmer
Calculated for data transfer, the local variable appl_ptr is reused, changed and written back later, though the lock was not held during the transfer earlier. Admitted, destiny of the lock is not obvious at all, but this looks much like a race condition candidate, so make sure to have some

Re: [PATCH] ALSA: pcm: retrieve true appl_ptr where stream was unlocked

2013-11-12 Thread Takashi Iwai
At 12 Nov 2013 16:14:17 +, Oskar Schirmer wrote: Calculated for data transfer, the local variable appl_ptr is reused, changed and written back later, though the lock was not held during the transfer earlier. Admitted, destiny of the lock is not obvious at all, but this looks much like a