summaryrefslogtreecommitdiffstats
path: root/sound/mips
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2018-09-02 04:22:37 -0400
committerTakashi Iwai <tiwai@suse.de>2018-09-04 06:13:27 -0400
commitdc0d1c4519095a6c6bbd9ec4a808674aba502741 (patch)
tree356914555db5d280f7ffdf61a828f5aa23b75371 /sound/mips
parent38ce57ad164816b432b80feb67d46d53137ff82a (diff)
ALSA: mips: Use SNDRV_PCM_INFO_SYNC_APPLPTR info flag
The recently introduced PCM info flag assures the call of ack ops at each applptr change, and this is mandatory for the indirect PCM helpers. Also, with the proper ack callback, we need no longer prefill at trigger start. The relevant code can be killed. Reviewed-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/mips')
-rw-r--r--sound/mips/hal2.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sound/mips/hal2.c b/sound/mips/hal2.c
index c8904e732aaa..2bd1cb7489ff 100644
--- a/sound/mips/hal2.c
+++ b/sound/mips/hal2.c
@@ -500,7 +500,8 @@ static const struct snd_pcm_hardware hal2_pcm_hw = {
500 .info = (SNDRV_PCM_INFO_MMAP | 500 .info = (SNDRV_PCM_INFO_MMAP |
501 SNDRV_PCM_INFO_MMAP_VALID | 501 SNDRV_PCM_INFO_MMAP_VALID |
502 SNDRV_PCM_INFO_INTERLEAVED | 502 SNDRV_PCM_INFO_INTERLEAVED |
503 SNDRV_PCM_INFO_BLOCK_TRANSFER), 503 SNDRV_PCM_INFO_BLOCK_TRANSFER |
504 SNDRV_PCM_INFO_SYNC_APPLPTR),
504 .formats = SNDRV_PCM_FMTBIT_S16_BE, 505 .formats = SNDRV_PCM_FMTBIT_S16_BE,
505 .rates = SNDRV_PCM_RATE_8000_48000, 506 .rates = SNDRV_PCM_RATE_8000_48000,
506 .rate_min = 8000, 507 .rate_min = 8000,
@@ -577,7 +578,6 @@ static int hal2_playback_trigger(struct snd_pcm_substream *substream, int cmd)
577 case SNDRV_PCM_TRIGGER_START: 578 case SNDRV_PCM_TRIGGER_START:
578 hal2->dac.pcm_indirect.hw_io = hal2->dac.buffer_dma; 579 hal2->dac.pcm_indirect.hw_io = hal2->dac.buffer_dma;
579 hal2->dac.pcm_indirect.hw_data = 0; 580 hal2->dac.pcm_indirect.hw_data = 0;
580 substream->ops->ack(substream);
581 hal2_start_dac(hal2); 581 hal2_start_dac(hal2);
582 break; 582 break;
583 case SNDRV_PCM_TRIGGER_STOP: 583 case SNDRV_PCM_TRIGGER_STOP: