diff options
author | Subhransu S. Prusty <subhransu.s.prusty@intel.com> | 2017-06-30 16:08:44 +0300 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2017-07-10 21:19:40 +0300 |
commit | 5b43af6d25461d7de293e0704d3b4631dda9b1e8 (patch) | |
tree | f6c02045e69abd69c936e8eb643dbbf2e9755821 /sound | |
parent | b821d298f8864dc3c3d42643812df43289159507 (diff) | |
download | linux-5b43af6d25461d7de293e0704d3b4631dda9b1e8.tar.xz |
ASoC: Intel: Skylake: Fix default dma_buffer_size
If the dma_buffer_size is not defined in topology, fix it to 2ms default
value to make backward compatible.
Fixes: f6e6ab1d16ec ("ASoC: Intel: Skylake: Fix dma buffer size calculation")
Signed-off-by: Subhransu S. Prusty <subhransu.s.prusty@intel.com>
Acked-By: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound')
-rw-r--r-- | sound/soc/intel/skylake/skl-messages.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/sound/soc/intel/skylake/skl-messages.c b/sound/soc/intel/skylake/skl-messages.c index eca85827dbd2..fb2f1f603f3c 100644 --- a/sound/soc/intel/skylake/skl-messages.c +++ b/sound/soc/intel/skylake/skl-messages.c @@ -540,6 +540,14 @@ static void skl_setup_cpr_gateway_cfg(struct skl_sst *ctx, cpr_mconfig->gtw_cfg.dma_buffer_size = mconfig->dma_buffer_size * dma_io_buf; + /* fallback to 2ms default value */ + if (!cpr_mconfig->gtw_cfg.dma_buffer_size) { + if (mconfig->hw_conn_type == SKL_CONN_SOURCE) + cpr_mconfig->gtw_cfg.dma_buffer_size = 2 * mconfig->obs; + else + cpr_mconfig->gtw_cfg.dma_buffer_size = 2 * mconfig->ibs; + } + cpr_mconfig->cpr_feature_mask = 0; cpr_mconfig->gtw_cfg.config_length = 0; |