Commit 5f8333f6 authored by Ranjani Sridharan's avatar Ranjani Sridharan Committed by Mark Brown

ASoC: SOF: topology: Rename arguments in sof_parse_tokens()

Rename the count and priv_size arguments in sof_parse_tokens() and add
comments to clarify the arguments.
Signed-off-by: default avatarRanjani Sridharan <ranjani.sridharan@linux.intel.com>
Reviewed-by: default avatarBard Liao <yung-chuan.liao@linux.intel.com>
Reviewed-by: default avatarPéter Ujfalusi <peter.ujfalusi@linux.intel.com>
Reviewed-by: default avatarPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/20220308164344.577647-17-ranjani.sridharan@linux.intel.comSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent e0974a38
...@@ -1024,12 +1024,23 @@ static int sof_parse_token_sets(struct snd_soc_component *scomp, ...@@ -1024,12 +1024,23 @@ static int sof_parse_token_sets(struct snd_soc_component *scomp,
return 0; return 0;
} }
static int sof_parse_tokens(struct snd_soc_component *scomp, /**
void *object, * sof_parse_tokens - Parse one set of tokens
const struct sof_topology_token *tokens, * @scomp: pointer to soc component
int count, * @object: target ipc struct for parsed values
* @tokens: token definition array describing what tokens to parse
* @num_tokens: number of tokens in definition array
* @array: source pointer to consecutive vendor arrays in topology
* @array_size: total size of @array
*
* This function parses a single set of tokens in vendor arrays into
* consecutive ipc structs.
*/
static int sof_parse_tokens(struct snd_soc_component *scomp, void *object,
const struct sof_topology_token *tokens, int num_tokens,
struct snd_soc_tplg_vendor_array *array, struct snd_soc_tplg_vendor_array *array,
int priv_size) int array_size)
{ {
/* /*
* sof_parse_tokens is used when topology contains only a single set of * sof_parse_tokens is used when topology contains only a single set of
...@@ -1037,8 +1048,8 @@ static int sof_parse_tokens(struct snd_soc_component *scomp, ...@@ -1037,8 +1048,8 @@ static int sof_parse_tokens(struct snd_soc_component *scomp,
* sof_parse_token_sets are sets = 1 (only 1 set) and * sof_parse_token_sets are sets = 1 (only 1 set) and
* object_size = 0 (irrelevant). * object_size = 0 (irrelevant).
*/ */
return sof_parse_token_sets(scomp, object, tokens, count, array, return sof_parse_token_sets(scomp, object, tokens, num_tokens, array,
priv_size, 1, 0); array_size, 1, 0);
} }
static void sof_dbg_comp_config(struct snd_soc_component *scomp, static void sof_dbg_comp_config(struct snd_soc_component *scomp,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment