Skip to contentSkip to conversation

error in snd_pcm_drain()

DISCUSSION Eliot Blennerhassett 2 participants 2 messages Jul 5, 2007

lore
Share & tools
lore
#0 lore raw

Maybe an error in snd_pcm_drain - not sure what effect it might have...

snd_pcm_group_for_each_entry(s, substream) {
		runtime = s->runtime;
...
	}
	up_read(&snd_pcm_link_rwsem);
	snd_pcm_stream_lock_irq(substream);

/* pcm_native.c around line 1491: */
/* error? runtime has been changed by group_for_each should use substream->runtime instead?
*/

	/* resume pause */
	if (runtime->status->state == SNDRV_PCM_STATE_PAUSED)
		snd_pcm_pause(substream, 0);

--
Eliot

#1 lore raw

At Thu, 05 Jul 2007 19:37:41 +1200,

Quoted 10 lines · Eliot Blennerhassett

Maybe an error in snd_pcm_drain - not sure what effect it might have...

snd_pcm_group_for_each_entry(s, substream) {
		runtime = s->runtime;
...
	}
	up_read(&snd_pcm_link_rwsem);
	snd_pcm_stream_lock_irq(substream);
Quoted 4 lines

/* pcm_native.c around line 1491: */
/* error? runtime has been changed by group_for_each should use substream->runtime instead?
*/

Maybe a bit safer, but in the end it's same because the status of linked streams should be identical.

Takashi

Quoted 13 lines
	/* resume pause */
	if (runtime->status->state == SNDRV_PCM_STATE_PAUSED)
		snd_pcm_pause(substream, 0);

--
Eliot
_______________________________________________
Alsa-devel mailing list
[email protected]
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel