ALSA: hda - Add bdl_pos_adj option
authorTakashi Iwai <tiwai@suse.de>
Tue, 10 Jun 2008 15:53:20 +0000 (17:53 +0200)
committerJaroslav Kysela <perex@perex.cz>
Fri, 13 Jun 2008 14:30:20 +0000 (16:30 +0200)
commit675f25d4d3ff6501cbce608bcc2333a56ec4c105
tree96c9fa245e2765179a58bac0b4a75969a7190d8b
parent0a1b42db4bf9db233d1f29795086a9526e84c845
ALSA: hda - Add bdl_pos_adj option

Added a new option, bdl_pos_adj, to adjust the delay of IRQ-wakeup
timing.

Most HD-audio hardwares have a problem that a BDL IRQ is issued before
actually the data and the DMA pointer are updated.
We have already a mechanism to force to delay snd_pcm_period_elapsed()
calls via workq, but this costs much CPU, and typically the delay is
within one sample.  Thus, it's more clever to adjust the BDL entries
instead.

The new option adds the size of the delay in frames.  As default,
it's set to 1 -- that is, one sample delay.  Even the hardware is
really correct, one sample delay is relatively harmless in comparison
with reporting wrong positions.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
sound/pci/hda/hda_intel.c