topology: add snd_tplg_load() remove snd_tplg_build_bin_file()

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
This commit is contained in:
Jaroslav Kysela 2019-12-15 16:03:29 +01:00
parent 22b66731f3
commit d52eaba63d
2 changed files with 47 additions and 77 deletions

View file

@ -783,6 +783,15 @@ snd_tplg_t *snd_tplg_new(void);
*/
void snd_tplg_free(snd_tplg_t *tplg);
/**
* \brief Load topology from the text buffer.
* \param tplg Topology instance.
* \param buf Text buffer.
* \param size Text buffer size in bytes.
* \return Zero on success, otherwise a negative error code
*/
int snd_tplg_load(snd_tplg_t *tplg, const char *buf, size_t size);
/**
* \brief Parse and build topology text file into binary file.
* \param tplg Topology instance.
@ -793,17 +802,6 @@ void snd_tplg_free(snd_tplg_t *tplg);
int snd_tplg_build_file(snd_tplg_t *tplg, const char *infile,
const char *outfile);
/**
* \brief Parse and build topology text file into binary file.
* \param tplg Topology instance.
* \param infile Topology text input file to be parsed
* \param bin Binary topology output buffer (malloc).
* \param size Binary topology output buffer size in bytes.
* \return Zero on success, otherwise a negative error code
*/
int snd_tplg_build_bin_file(snd_tplg_t *tplg, const char *infile,
void **bin, size_t *size);
/**
* \brief Enable verbose reporting of binary file output
* \param tplg Topology Instance