diff options
author | Yu-Hsuan Hsu <yuhsuan@chromium.org> | 2019-09-23 18:29:40 +0200 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2019-11-11 20:42:34 +0100 |
commit | e2db787bdcb4f2722ecf410168f0583764634e45 (patch) | |
tree | 205e2ae14098d47a3f0b0f6aac74b73098103ee8 /sound | |
parent | ASoC: Add DA7213 audio codec as selectable option (diff) | |
download | linux-e2db787bdcb4f2722ecf410168f0583764634e45.tar.xz linux-e2db787bdcb4f2722ecf410168f0583764634e45.zip |
ASoC: Intel: kbl_rt5663_rt5514_max98927: Add dmic format constraint
On KBL platform, the microphone is attached to external codec(rt5514)
instead of PCH. However, TDM slot between PCH and codec is 16 bits only.
In order to avoid setting wrong format, we should add a constraint to
force to use 16 bits format forever.
Signed-off-by: Yu-Hsuan Hsu <yuhsuan@chromium.org>
Acked-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/20190923162940.199580-1-yuhsuan@chromium.org
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound')
-rw-r--r-- | sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c b/sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c index a1056cda3dd7..3e5f6bead229 100644 --- a/sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c +++ b/sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c @@ -465,6 +465,9 @@ static int kabylake_dmic_startup(struct snd_pcm_substream *substream) snd_pcm_hw_constraint_list(runtime, 0, SNDRV_PCM_HW_PARAM_CHANNELS, dmic_constraints); + runtime->hw.formats = SNDRV_PCM_FMTBIT_S16_LE; + snd_pcm_hw_constraint_msbits(runtime, 0, 16, 16); + return snd_pcm_hw_constraint_list(substream->runtime, 0, SNDRV_PCM_HW_PARAM_RATE, &constraints_rates); } |