diff options
| author | Jens Axboe <jens.axboe@oracle.com> | 2009-05-22 20:25:34 +0200 |
|---|---|---|
| committer | Jens Axboe <jens.axboe@oracle.com> | 2009-05-22 20:25:34 +0200 |
| commit | e4b636366c00738b9609cda307014d71b1225b7f (patch) | |
| tree | 760b67b3624eda62e943e48ce93635c30a5b47bf /sound/core/pcm_lib.c | |
| parent | b9ed7252d219c1c663944bf03846eabb515dbe75 (diff) | |
| parent | 279e677faa775ad16e75c32e1bf4a37f8158bc61 (diff) | |
Merge branch 'master' into for-2.6.31
Conflicts:
drivers/block/hd.c
drivers/block/mg_disk.c
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Diffstat (limited to 'sound/core/pcm_lib.c')
| -rw-r--r-- | sound/core/pcm_lib.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/sound/core/pcm_lib.c b/sound/core/pcm_lib.c index 63d088f2265f..a2a792c18c40 100644 --- a/sound/core/pcm_lib.c +++ b/sound/core/pcm_lib.c @@ -249,6 +249,12 @@ static int snd_pcm_update_hw_ptr_interrupt(struct snd_pcm_substream *substream) new_hw_ptr = hw_base + pos; } } + /* Skip the jiffies check for hardwares with BATCH flag. + * Such hardware usually just increases the position at each IRQ, + * thus it can't give any strange position. + */ + if (runtime->hw.info & SNDRV_PCM_INFO_BATCH) + goto no_jiffies_check; hdelta = new_hw_ptr - old_hw_ptr; jdelta = jiffies - runtime->hw_ptr_jiffies; if (((hdelta * HZ) / runtime->rate) > jdelta + HZ/100) { @@ -272,6 +278,7 @@ static int snd_pcm_update_hw_ptr_interrupt(struct snd_pcm_substream *substream) hw_base -= hw_base % runtime->buffer_size; delta = 0; } + no_jiffies_check: if (delta > runtime->period_size + runtime->period_size / 2) { hw_ptr_error(substream, "Lost interrupts? " |
