mirror of https://github.com/thesofproject/sof.git
topology: Add support for buffer flags
Flags have been a part of IPC3 for ages, add support for them in the topology. Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
This commit is contained in:
parent
5cf1c9c0d6
commit
285c090a10
|
@ -33,6 +33,7 @@
|
||||||
/* buffers */
|
/* buffers */
|
||||||
#define SOF_TKN_BUF_SIZE 100
|
#define SOF_TKN_BUF_SIZE 100
|
||||||
#define SOF_TKN_BUF_CAPS 101
|
#define SOF_TKN_BUF_CAPS 101
|
||||||
|
#define SOF_TKN_BUF_FLAGS 102
|
||||||
|
|
||||||
/* DAI */
|
/* DAI */
|
||||||
/* Token retired with ABI 3.2, do not use for new capabilities
|
/* Token retired with ABI 3.2, do not use for new capabilities
|
||||||
|
|
|
@ -5,13 +5,16 @@ dnl Define the macro for buffer widget
|
||||||
dnl N_BUFFER(name)
|
dnl N_BUFFER(name)
|
||||||
define(`N_BUFFER', `BUF'PIPELINE_ID`.'$1)
|
define(`N_BUFFER', `BUF'PIPELINE_ID`.'$1)
|
||||||
|
|
||||||
dnl W_BUFFER(name, size, capabilities)
|
dnl W_BUFFER(name, size, capabilities, [core], [flags])
|
||||||
define(`W_BUFFER',
|
define(`W_BUFFER',
|
||||||
`SectionVendorTuples."'N_BUFFER($1)`_tuples" {'
|
`SectionVendorTuples."'N_BUFFER($1)`_tuples" {'
|
||||||
` tokens "sof_buffer_tokens"'
|
` tokens "sof_buffer_tokens"'
|
||||||
` tuples."word" {'
|
` tuples."word" {'
|
||||||
` SOF_TKN_BUF_SIZE' STR($2)
|
` SOF_TKN_BUF_SIZE' STR($2)
|
||||||
` SOF_TKN_BUF_CAPS' STR($3)
|
` SOF_TKN_BUF_CAPS' STR($3)
|
||||||
|
`ifelse(`$#', `5',
|
||||||
|
` SOF_TKN_BUF_FLAGS' STR($5)
|
||||||
|
,` ')'
|
||||||
` }'
|
` }'
|
||||||
`}'
|
`}'
|
||||||
`SectionData."'N_BUFFER($1)`_data" {'
|
`SectionData."'N_BUFFER($1)`_data" {'
|
||||||
|
|
|
@ -30,6 +30,8 @@ static const struct sof_topology_token buffer_tokens[] = {
|
||||||
offsetof(struct sof_ipc_buffer, size), 0},
|
offsetof(struct sof_ipc_buffer, size), 0},
|
||||||
{SOF_TKN_BUF_CAPS, SND_SOC_TPLG_TUPLE_TYPE_WORD, tplg_token_get_uint32_t,
|
{SOF_TKN_BUF_CAPS, SND_SOC_TPLG_TUPLE_TYPE_WORD, tplg_token_get_uint32_t,
|
||||||
offsetof(struct sof_ipc_buffer, caps), 0},
|
offsetof(struct sof_ipc_buffer, caps), 0},
|
||||||
|
{SOF_TKN_BUF_FLAGS, SND_SOC_TPLG_TUPLE_TYPE_WORD, tplg_token_get_uint32_t,
|
||||||
|
offsetof(struct sof_ipc_buffer, flags), 0},
|
||||||
};
|
};
|
||||||
|
|
||||||
static const struct sof_topology_token buffer_comp_tokens[] = {
|
static const struct sof_topology_token buffer_comp_tokens[] = {
|
||||||
|
|
Loading…
Reference in New Issue