OSDN Git Service

pcm_hw: Always use delay ioctl in snd_pcm_delay()
authorKai Vehmanen <kvehmanen@eca.cx>
Thu, 10 Sep 2009 22:07:21 +0000 (01:07 +0300)
committerTakashi Iwai <tiwai@suse.de>
Fri, 11 Sep 2009 07:18:36 +0000 (09:18 +0200)
commitecf4b5af8632a17af3c84cfceeaaf0a1609e2928
treefd765487bf12e3b4f3dad58332054c6b1bef9218
parenta4e7033f8d0aec42d8ca29a9e500c50c1627afff
pcm_hw: Always use delay ioctl in snd_pcm_delay()

As the result of snd_pcm_delay() is affected not only by hw_ptr
and appl_ptr, but also by 'runtime->delay' property,
either SNDRV_PCM_IOCTL_DELAY or SNDRV_PCM_IOCTL_STATUS ioctl
must be used to get the correct result.

Previously 'runtime->delay' was ignored in case 'hw->sync_ptr'
was used.

Signed-off-by: Kai Vehmanen <kvehmanen@eca.cx>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
src/pcm/pcm_hw.c