summaryrefslogtreecommitdiff
path: root/sound/soc/intel/skylake/skl-topology.h
diff options
context:
space:
mode:
authorCezary Rojewski <cezary.rojewski@intel.com>2019-07-23 16:58:53 +0200
committerMark Brown <broonie@kernel.org>2019-07-24 19:43:03 +0100
commit84b71067ea840fadee32588aa3967d0d8c4e0b9a (patch)
tree5422edab3f5aa840824bd879c6ccb8fd37bf230c /sound/soc/intel/skylake/skl-topology.h
parentd4e23b7c87e3439f6d0ec0c65ad7f919d6f4c124 (diff)
ASoC: Intel: Skylake: Make MCPS and CPS params obsolete
As per FW Interface Modules Configuration, init instance IPC request requires base initial module configuration. This configuration structure is made of: - cpc (chunks per cycle) - ibs (input buffer size) - obs (output buffer size) - is_pages (memory pages required) - audio_fmt (self explanatory) Skylake topology accepts following tokens: MCPS, CPS and CPC. All of these are directly connected. Moreover, assigning one of these allows to calculate the remaining two. In simplest scenario and assuming 1ms scheduling, following is true: CPS = CPC times 1000 MCPS = CPS times 1000 000 Note: these calculations vary depending on scenario and scheduling requirements. Given the current implementation, userspace is allowed to provide different values for all three causing informational chaos. On top of that, struct skl_base_cfg which represents base module configuration, incorrectly takes CPS param instead of CPC. This ambiguity may lead to user unintentionally providing improper values to DSP firmware and thus impacting module scheduling in unexpected fashion. Fix by making MCPS and CPS topology params obsolete and relying solely on CPC value. Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20190723145854.8527-7-cezary.rojewski@intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/intel/skylake/skl-topology.h')
-rw-r--r--sound/soc/intel/skylake/skl-topology.h4
1 files changed, 1 insertions, 3 deletions
diff --git a/sound/soc/intel/skylake/skl-topology.h b/sound/soc/intel/skylake/skl-topology.h
index e2a2fc5c5545..99a0277191ca 100644
--- a/sound/soc/intel/skylake/skl-topology.h
+++ b/sound/soc/intel/skylake/skl-topology.h
@@ -101,7 +101,7 @@ struct skl_audio_data_format {
} __packed;
struct skl_base_cfg {
- u32 cps;
+ u32 cpc;
u32 ibs;
u32 obs;
u32 is_pages;
@@ -343,7 +343,6 @@ struct skl_module_pin_resources {
struct skl_module_res {
u8 id;
u32 is_pages;
- u32 cps;
u32 ibs;
u32 obs;
u32 dma_buffer_size;
@@ -384,7 +383,6 @@ struct skl_module_cfg {
u8 out_queue_mask;
u8 in_queue;
u8 out_queue;
- u32 mcps;
u32 ibs;
u32 obs;
u8 is_loadable;