ALSA: usb-audio: hiface: return correct XRUN indication
PATCH v2 1/1 ALSA: usb-audio: hiface: return correct XRUN indication
Return SNDRV_PCM_POS_XRUN (snd_pcm_uframes_t) instead of SNDRV_PCM_STATE_XRUN (snd_pcm_state_t) from the pointer function of hiface, as expected by snd_pcm_update_hw_ptr0().
Caught by sparse.
Cc Antonio Ospite <[email protected]>
Signed-off-by Eldad Zack <[email protected]>
---
* Corrected commit message
sound/usb/hiface/pcm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
sound/usb/hiface/pcm.c +1 -1
@@ -503,7 +503,7 @@ static snd_pcm_uframes_t hiface_pcm_pointer(struct snd_pcm_substream *alsa_sub)snd_pcm_uframes_t dma_offset;if (rt->panic || !sub) -return SNDRV_PCM_STATE_XRUN ; +return SNDRV_PCM_POS_XRUN ;spin_lock_irqsave (&sub->lock, flags); dma_offset = sub->dma_off;
Signature · 1 line
1.8.1.5
Takashi Iwai
AppliedAt Tue, 23 Jul 2013 11:15:06 +0200,
Quoted 9 lines · Eldad Zack
Return
SNDRV_PCM_POS_XRUN(snd_pcm_uframes_t) instead ofSNDRV_PCM_STATE_XRUN(snd_pcm_state_t) from the pointer function of hiface, as expected bysnd_pcm_update_hw_ptr0().Caught by sparse.
Cc Antonio Ospite <[email protected]>Signed-off-by Eldad Zack <[email protected]>
Thanks, applied.
Takashi
Quoted 22 lines
---
* Corrected commit messagesound/usb/hiface/pcm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)sound/usb/hiface/pcm.c +1
-1@@ -503,7 +503,7 @@ static snd_pcm_uframes_t hiface_pcm_pointer(struct snd_pcm_substream *alsa_sub)snd_pcm_uframes_t dma_offset;if (rt->panic || !sub) -return SNDRV_PCM_STATE_XRUN ; +return SNDRV_PCM_POS_XRUN ;spin_lock_irqsave (&sub->lock, flags); dma_offset = sub->dma_off;Signature · 1 line
1.8.1.5