Skip to content

Commit

Permalink
ALSA: usb-audio: 6fire: return correct XRUN indication
Browse files Browse the repository at this point in the history
commit be2f93a upstream.

Return SNDRV_PCM_POS_XRUN (snd_pcm_uframes_t) instead of
SNDRV_PCM_STATE_XRUN (snd_pcm_state_t) from the pointer
function of 6fire, as expected by snd_pcm_update_hw_ptr0().

Caught by sparse.

Signed-off-by: Eldad Zack <eldad@fogrefinery.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Eldad Zack authored and Greg Kroah-Hartman committed Jul 28, 2013
1 parent 39367f4 commit acaeda3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sound/usb/6fire/pcm.c
Original file line number Diff line number Diff line change
@@ -540,7 +540,7 @@ static snd_pcm_uframes_t usb6fire_pcm_pointer(
snd_pcm_uframes_t ret;

if (rt->panic || !sub)
return SNDRV_PCM_STATE_XRUN;
return SNDRV_PCM_POS_XRUN;

spin_lock_irqsave(&sub->lock, flags);
ret = sub->dma_off;

0 comments on commit acaeda3

Please sign in to comment.