aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorShreyas NC <shreyas.nc@intel.com>2017-08-23 10:03:49 -0400
committerMark Brown <broonie@kernel.org>2017-08-25 09:53:51 -0400
commit3d52a7924172adf651eda8f1c95ff38146059307 (patch)
treed937976b43e470ea24e932bffd6e91e26b3afb04
parent9fc129f6e5de01ce5fccf033485e40dfa429b45c (diff)
ASoC: Intel: uapi: Add new tokens for module common data
The module private data can be modelled independent of its instances so that it can be reused by the module instances. So move module data to common manifest which can be referenced by the module instances. This requires new tokens to be defined to accommodate these changes. The new tokens will specify buffer sizes, DSP cycles and respective indexes corresponding to the pcm params in the topology manifest so that driver need not compute them. Signed-off-by: Shreyas NC <shreyas.nc@intel.com> Signed-off-by: Guneshwor Singh <guneshwor.o.singh@intel.com> Acked-By: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org>
-rw-r--r--include/uapi/sound/snd_sst_tokens.h92
1 files changed, 91 insertions, 1 deletions
diff --git a/include/uapi/sound/snd_sst_tokens.h b/include/uapi/sound/snd_sst_tokens.h
index dedb2056160d..f691e421f5e8 100644
--- a/include/uapi/sound/snd_sst_tokens.h
+++ b/include/uapi/sound/snd_sst_tokens.h
@@ -163,8 +163,71 @@
163 * 163 *
164 * %SKL_TKN_U32_DMA_BUF_SIZE: DMA buffer size in millisec 164 * %SKL_TKN_U32_DMA_BUF_SIZE: DMA buffer size in millisec
165 * 165 *
166 * %SKL_TKN_U32_PIPE_DIR: Specifies pipe direction. Can be
167 * playback/capture.
168 *
169 * %SKL_TKN_U32_NUM_CONFIGS: Number of pipe configs
170 *
171 * %SKL_TKN_U32_PATH_MEM_PGS: Size of memory (in pages) required for pipeline
172 * and its data
173 *
174 * %SKL_TKN_U32_PIPE_CONFIG_ID: Config id for the modules in the pipe
175 * and PCM params supported by that pipe
176 * config. This is used as index to fill
177 * up the pipe config and module config
178 * structure.
179 *
180 * %SKL_TKN_U32_CFG_FREQ:
181 * %SKL_TKN_U8_CFG_CHAN:
182 * %SKL_TKN_U8_CFG_BPS: PCM params (freq, channels, bits per sample)
183 * supported for each of the pipe configs.
184 *
185 * %SKL_TKN_CFG_MOD_RES_ID: Module's resource index for each of the
186 * pipe config
187 *
188 * %SKL_TKN_CFG_MOD_FMT_ID: Module's interface index for each of the
189 * pipe config
190 *
191 * %SKL_TKN_U8_NUM_MOD: Number of modules in the manifest
192 *
193 * %SKL_TKN_MM_U8_MOD_IDX: Current index of the module in the manifest
194 *
195 * %SKL_TKN_MM_U8_NUM_RES: Number of resources for the module
196 *
197 * %SKL_TKN_MM_U8_NUM_INTF: Number of interfaces for the module
198 *
199 * %SKL_TKN_MM_U32_RES_ID: Resource index for the resource info to
200 * be filled into.
201 * A module can support multiple resource
202 * configuration and is represnted as a
203 * resource table. This index is used to
204 * fill information into appropriate index.
205 *
206 * %SKL_TKN_MM_U32_CPS: DSP cycles per second
207 *
208 * %SKL_TKN_MM_U32_DMA_SIZE: Allocated buffer size for gateway DMA
209 *
210 * %SKL_TKN_MM_U32_CPC: DSP cycles allocated per frame
211 *
212 * %SKL_TKN_MM_U32_RES_PIN_ID: Resource pin index in the module
213 *
214 * %SKL_TKN_MM_U32_INTF_PIN_ID: Interface index in the module
215 *
216 * %SKL_TKN_MM_U32_PIN_BUF: Buffer size of the module pin
217 *
218 * %SKL_TKN_MM_U32_FMT_ID: Format index for each of the interface/
219 * format information to be filled into.
220 *
221 * %SKL_TKN_MM_U32_NUM_IN_FMT: Number of input formats
222 * %SKL_TKN_MM_U32_NUM_OUT_FMT: Number of output formats
223 *
166 * module_id and loadable flags dont have tokens as these values will be 224 * module_id and loadable flags dont have tokens as these values will be
167 * read from the DSP FW manifest 225 * read from the DSP FW manifest
226 *
227 * Tokens defined can be used either in the manifest or widget private data.
228 *
229 * SKL_TKN_MM is used as a suffix for all tokens that represent
230 * module data in the manifest.
168 */ 231 */
169enum SKL_TKNS { 232enum SKL_TKNS {
170 SKL_TKN_UUID = 1, 233 SKL_TKN_UUID = 1,
@@ -218,7 +281,34 @@ enum SKL_TKNS {
218 SKL_TKL_U32_D0I3_CAPS, /* Typo added at v4.10 */ 281 SKL_TKL_U32_D0I3_CAPS, /* Typo added at v4.10 */
219 SKL_TKN_U32_D0I3_CAPS = SKL_TKL_U32_D0I3_CAPS, 282 SKL_TKN_U32_D0I3_CAPS = SKL_TKL_U32_D0I3_CAPS,
220 SKL_TKN_U32_DMA_BUF_SIZE, 283 SKL_TKN_U32_DMA_BUF_SIZE,
221 SKL_TKN_MAX = SKL_TKN_U32_DMA_BUF_SIZE, 284
285 SKL_TKN_U32_PIPE_DIRECTION,
286 SKL_TKN_U32_PIPE_CONFIG_ID,
287 SKL_TKN_U32_NUM_CONFIGS,
288 SKL_TKN_U32_PATH_MEM_PGS,
289
290 SKL_TKN_U32_CFG_FREQ,
291 SKL_TKN_U8_CFG_CHAN,
292 SKL_TKN_U8_CFG_BPS,
293 SKL_TKN_CFG_MOD_RES_ID,
294 SKL_TKN_CFG_MOD_FMT_ID,
295 SKL_TKN_U8_NUM_MOD,
296
297 SKL_TKN_MM_U8_MOD_IDX,
298 SKL_TKN_MM_U8_NUM_RES,
299 SKL_TKN_MM_U8_NUM_INTF,
300 SKL_TKN_MM_U32_RES_ID,
301 SKL_TKN_MM_U32_CPS,
302 SKL_TKN_MM_U32_DMA_SIZE,
303 SKL_TKN_MM_U32_CPC,
304 SKL_TKN_MM_U32_RES_PIN_ID,
305 SKL_TKN_MM_U32_INTF_PIN_ID,
306 SKL_TKN_MM_U32_PIN_BUF,
307 SKL_TKN_MM_U32_FMT_ID,
308 SKL_TKN_MM_U32_NUM_IN_FMT,
309 SKL_TKN_MM_U32_NUM_OUT_FMT,
310
311 SKL_TKN_MAX = SKL_TKN_MM_U32_NUM_OUT_FMT,
222}; 312};
223 313
224#endif 314#endif