From: Takashi Iwai Date: Mon, 18 Aug 2008 15:11:09 +0000 (+0200) Subject: ALSA: hda - disable delayed period-ack with bdl_pos_adj=0 X-Git-Tag: v2.6.28-rc1~720^2~176 X-Git-Url: http://www.pilppa.org/gitweb/gitweb.cgi?a=commitdiff_plain;h=a62741cf77f41338033553d7cc3fd3145a64ae53;p=linux-2.6-omap-h63xx.git ALSA: hda - disable delayed period-ack with bdl_pos_adj=0 When bdl_pos_adj=0 is given, disable the position-check and the delayed period update mechanism. Usually bdl_pos_adj=0 is set only for the debugging purpose on really broken hardwares. It's better to disable the extra complexity in such a case. Signed-off-by: Takashi Iwai Signed-off-by: Jaroslav Kysela --- diff --git a/sound/pci/hda/hda_intel.c b/sound/pci/hda/hda_intel.c index b2bcd94cf7a..39f22318803 100644 --- a/sound/pci/hda/hda_intel.c +++ b/sound/pci/hda/hda_intel.c @@ -1559,6 +1559,8 @@ static int azx_position_ok(struct azx *chip, struct azx_dev *azx_dev) chip->position_fix = POS_FIX_POSBUF; } + if (!bdl_pos_adj[chip->dev_index]) + return 1; /* no delayed ack */ if (pos % azx_dev->period_bytes > azx_dev->period_bytes / 2) return 0; /* NG - it's below the period boundary */ return 1; /* OK, it's fine */