aboutsummaryrefslogtreecommitdiffstats
path: root/pcm.c
diff options
context:
space:
mode:
Diffstat (limited to 'pcm.c')
-rw-r--r--pcm.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/pcm.c b/pcm.c
index 04d4396..9324f38 100644
--- a/pcm.c
+++ b/pcm.c
@@ -551,9 +551,14 @@ struct pcm *pcm_open(unsigned int card, unsigned int device,
551 sparams.start_threshold = config->start_threshold; 551 sparams.start_threshold = config->start_threshold;
552 552
553 /* pick a high stop threshold - todo: does this need further tuning */ 553 /* pick a high stop threshold - todo: does this need further tuning */
554 if (!config->stop_threshold) 554 if (!config->stop_threshold) {
555 pcm->config.stop_threshold = sparams.stop_threshold = 555 if (pcm->flags & PCM_IN)
556 config->period_count * config->period_size; 556 pcm->config.stop_threshold = sparams.stop_threshold =
557 config->period_count * config->period_size * 10;
558 else
559 pcm->config.stop_threshold = sparams.stop_threshold =
560 config->period_count * config->period_size;
561 }
557 else 562 else
558 sparams.stop_threshold = config->stop_threshold; 563 sparams.stop_threshold = config->stop_threshold;
559 564