[007/133] ALSA: usb-audio: 6fire: return correct XRUN indication

Submitted by Kamal Mostafa on Aug. 16, 2013, 10:32 p.m.


Message ID 1376692475-28413-8-git-send-email-kamal@canonical.com
State New
Headers show

Commit Message

Kamal Mostafa Aug. 16, 2013, 10:32 p.m. -stable review patch.  If anyone has any objections, please let me know.


From: Eldad Zack <eldad@fogrefinery.com>

commit be2f93a4c4981b3646b6f98f477154411b8516cb 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: Kamal Mostafa <kamal@canonical.com>
 sound/usb/6fire/pcm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch hide | download patch | download mbox

diff --git a/sound/usb/6fire/pcm.c b/sound/usb/6fire/pcm.c
index 8221ff2..074aaf7 100644
--- a/sound/usb/6fire/pcm.c
+++ b/sound/usb/6fire/pcm.c
@@ -543,7 +543,7 @@  static snd_pcm_uframes_t usb6fire_pcm_pointer(
 	snd_pcm_uframes_t ret;
 	if (rt->panic || !sub)
 	spin_lock_irqsave(&sub->lock, flags);
 	ret = sub->dma_off;