21 #ifndef __ALSA_TOPOLOGY_H
22 #define __ALSA_TOPOLOGY_H
741 #define SND_TPLG_MAX_CHAN 8
770 #define SND_TPLG_INDEX_ALL 0
773 #define SND_TPLG_CREATE_VERBOSE (1<<0)
774 #define SND_TPLG_CREATE_DAPM_NOSORT (1<<1)
780 const char *snd_tplg_version(void);
817 const char *outfile);
902 struct snd_soc_tplg_private *
priv;
915 struct snd_soc_tplg_private *
priv;
928 struct snd_soc_tplg_private *
priv;
963 struct snd_soc_tplg_private *
priv;
1085 typedef struct snd_tplg_obj_template {
1147 #define SND_TPLG_SAVE_SORT (1<<0)
1148 #define SND_TPLG_SAVE_GROUPS (1<<1)
1149 #define SND_TPLG_SAVE_NOCHECK (1<<16)
1163 int snd_tplg_save(snd_tplg_t *tplg, char **dst, int flags);
Definition: topology.h:751
struct snd_soc_tplg_private * priv
Definition: topology.h:928
const char * ctl
Definition: topology.h:936
const char * name
Definition: topology.h:984
int rate
Definition: topology.h:974
uint64_t formats
Definition: topology.h:985
unsigned char bclk_provider
Definition: topology.h:1029
int items
Definition: topology.h:911
struct snd_tplg_channel_elem channel[SND_TPLG_MAX_CHAN]
Definition: topology.h:858
unsigned int flags
Definition: topology.h:1057
const int ** values
Definition: topology.h:914
Template type to describe a physical link runtime supported hardware config, i.e. hardware audio form...
Definition: topology.h:1023
unsigned int flag_mask
Definition: topology.h:1056
int snd_tplg_decode(snd_tplg_t *tplg, void *bin, size_t size, int dflags)
Decode the binary topology contents.
Definition: decoder.c:43
Template type for enumerated control objects.
Definition: topology.h:908
Template type for single channel mapping.
Definition: topology.h:846
unsigned int rate_min
Definition: topology.h:987
Template type for array of DAPM graph elements.
Definition: topology.h:943
int snd_tplg_build_bin(snd_tplg_t *tplg, void **bin, size_t *size)
Build all registered topology data into memory.
Definition: parser.c:379
unsigned int fsync_rate
Definition: topology.h:1035
Definition: topology.h:764
struct snd_tplg_stream_template * stream
Definition: topology.h:1071
Definition: topology.h:760
Definition: topology.h:761
unsigned int tx_channels
Definition: topology.h:1040
snd_tplg_type
Definition: topology.h:747
struct snd_tplg_pcm_template * pcm
Definition: topology.h:1096
int mask
Definition: topology.h:912
struct snd_tplg_enum_template * enum_ctl
Definition: topology.h:1094
struct snd_tplg_bytes_template * bytes_ctl
Definition: topology.h:1093
Definition: topology.h:757
struct snd_soc_tplg_private * priv
Definition: topology.h:902
struct snd_tplg_channel_map_template * map
Definition: topology.h:910
Definition: topology.h:756
unsigned short reserved
Definition: topology.h:1032
int access
Definition: topology.h:884
unsigned char clock_gated
Definition: topology.h:1026
unsigned int * tx_chanmap
Definition: topology.h:1041
Definition: topology.h:766
unsigned int dai_id
Definition: topology.h:1052
struct snd_tplg_io_ops_template ops
Definition: topology.h:885
struct snd_tplg_tlv_template hdr
Definition: topology.h:837
struct snd_tplg_stream_template stream[0]
Definition: topology.h:1016
snd_tplg_t * snd_tplg_create(int flags)
Create a new topology parser instance.
Definition: parser.c:434
int snd_tplg_add_object(snd_tplg_t *tplg, snd_tplg_obj_template_t *t)
Register topology template object.
Definition: parser.c:324
unsigned char invert_bclk
Definition: topology.h:1027
Definition: topology.h:749
snd_tplg_t * snd_tplg_new(void)
Create a new topology parser instance.
Definition: parser.c:474
unsigned int tx_slots
Definition: topology.h:1038
struct snd_tplg_widget_template * widget
Definition: topology.h:1091
Template type for control objects.
Definition: topology.h:881
int platform_max
Definition: topology.h:900
struct snd_tplg_io_ops_template ext_ops
Definition: topology.h:927
unsigned int length
Definition: topology.h:865
unsigned int tdm_slots
Definition: topology.h:1036
Generic Template Object.
Definition: topology.h:1085
const char * name
Definition: topology.h:1066
unsigned int buffer_size_max
Definition: topology.h:996
struct snd_soc_tplg_private * priv
Definition: topology.h:915
unsigned int rate_max
Definition: topology.h:988
int count
Definition: topology.h:944
unsigned char mclk_direction
Definition: topology.h:1031
const char * dai_name
Definition: topology.h:1005
int format
Definition: topology.h:973
Definition: topology.h:762
struct snd_tplg_ctl_template hdr
Definition: topology.h:909
struct snd_tplg_stream_caps_template * caps[2]
Definition: topology.h:1055
struct snd_tplg snd_tplg_t
Definition: topology.h:744
int id
Definition: topology.h:1024
int reg
Definition: topology.h:848
Template type for TLV Scale objects.
Definition: topology.h:836
int vendor_type
Definition: topology.h:1089
unsigned char fsync_provider
Definition: topology.h:1030
Stream configurations.
Definition: topology.h:971
struct snd_tplg_ctl_template hdr
Definition: topology.h:922
void snd_tplg_free(snd_tplg_t *tplg)
Free a topology parser instance.
Definition: parser.c:479
const char * stream_name
Definition: topology.h:1068
int max
Definition: topology.h:923
unsigned int capture
Definition: topology.h:1009
int default_hw_config_id
Definition: topology.h:1075
int max
Definition: topology.h:899
int buffer_bytes
Definition: topology.h:976
int mute
Definition: topology.h:840
int num_hw_configs
Definition: topology.h:1074
struct snd_tplg_graph_elem elem[0]
Definition: topology.h:945
int num_regs
Definition: topology.h:926
unsigned int bclk_rate
Definition: topology.h:1034
unsigned int * rx_chanmap
Definition: topology.h:1043
struct snd_tplg_mixer_template * mixer
Definition: topology.h:1092
Definition: topology.h:752
#define SND_TPLG_MAX_CHAN
Definition: topology.h:741
struct snd_tplg_hw_config_template * hw_config
Definition: topology.h:1073
unsigned int rx_channels
Definition: topology.h:1042
Template type for PCM (FE DAI & DAI links).
Definition: topology.h:1003
const char ** texts
Definition: topology.h:913
int snd_tplg_build_file(snd_tplg_t *tplg, const char *infile, const char *outfile)
Parse and build topology text file into binary file.
Definition: parser.c:295
int snd_tplg_set_version(snd_tplg_t *tplg, unsigned int version)
Set an optional vendor specific version number.
Definition: parser.c:414
struct snd_soc_tplg_private * priv
Definition: topology.h:1014
unsigned int buffer_size_min
Definition: topology.h:995
const char * src
Definition: topology.h:935
struct snd_tplg_dai_template * dai
Definition: topology.h:1098
Template type for single DAPM graph element.
Definition: topology.h:934
Definition: topology.h:754
int min
Definition: topology.h:838
void snd_tplg_verbose(snd_tplg_t *tplg, int verbose)
Enable verbose reporting of binary file output.
Definition: parser.c:421
struct snd_tplg_stream_caps_template * caps[2]
Definition: topology.h:1011
const char * sink
Definition: topology.h:937
Template type for TLV Scale objects.
Definition: topology.h:921
Template type for object operations mapping.
Definition: topology.h:872
struct snd_tplg_ctl_template hdr
Definition: topology.h:896
int put
Definition: topology.h:874
unsigned int capture
Definition: topology.h:1054
struct snd_tplg_channel_map_template * map
Definition: topology.h:897
int mask
Definition: topology.h:924
unsigned int tdm_slot_width
Definition: topology.h:1037
unsigned int flag_mask
Definition: topology.h:1012
Definition: topology.h:765
unsigned int pcm_id
Definition: topology.h:1006
Template type for all TLV objects.
Definition: topology.h:829
unsigned int periods_max
Definition: topology.h:992
const char * name
Definition: topology.h:883
int id
Definition: topology.h:1067
Template type for physical DAI. It can be used to configure backend DAIs for DPCM.
Definition: topology.h:1050
Definition: topology.h:755
Definition: topology.h:763
unsigned int periods_min
Definition: topology.h:991
unsigned int sig_bits
Definition: topology.h:997
unsigned int rx_slots
Definition: topology.h:1039
Definition: topology.h:758
Definition: topology.h:759
Definition: topology.h:748
int shift
Definition: topology.h:849
const void * data
Definition: topology.h:866
int invert
Definition: topology.h:901
int num_streams
Definition: topology.h:1015
int type
Definition: topology.h:830
unsigned int flag_mask
Definition: topology.h:1077
int size
Definition: topology.h:847
struct snd_tplg_graph_template * graph
Definition: topology.h:1095
Template type for physical DAI Links.
Definition: topology.h:1065
Template type for mixer control objects.
Definition: topology.h:895
int num_streams
Definition: topology.h:1070
struct snd_soc_tplg_private * priv
Definition: topology.h:1058
struct snd_tplg_link_template * link
Definition: topology.h:1097
unsigned int channels_min
Definition: topology.h:989
const char * name
Definition: topology.h:972
unsigned int dai_id
Definition: topology.h:1007
int snd_tplg_set_manifest_data(snd_tplg_t *tplg, const void *data, int len)
Attach private data to topology manifest.
Definition: parser.c:395
unsigned int playback
Definition: topology.h:1008
int type
Definition: topology.h:882
struct snd_tplg_tlv_dbscale_template * tlv_scale
Definition: topology.h:888
int channels
Definition: topology.h:977
int num_channels
Definition: topology.h:857
unsigned int period_size_min
Definition: topology.h:993
Template type for channel mapping.
Definition: topology.h:856
struct snd_soc_tplg_private * priv
Definition: topology.h:1079
unsigned int period_size_max
Definition: topology.h:994
unsigned int compress
Definition: topology.h:1010
int min
Definition: topology.h:898
unsigned int fmt
Definition: topology.h:1025
unsigned int flags
Definition: topology.h:1078
unsigned int playback
Definition: topology.h:1053
unsigned int channels_max
Definition: topology.h:990
int snd_tplg_load(snd_tplg_t *tplg, const char *buf, size_t size)
Load topology from the text buffer.
Definition: parser.c:261
struct snd_tplg_tlv_template * tlv
Definition: topology.h:887
int base
Definition: topology.h:925
int info
Definition: topology.h:875
unsigned int flags
Definition: topology.h:1013
int snd_tplg_build(snd_tplg_t *tplg, const char *outfile)
Build all registered topology data into binary file.
Definition: parser.c:351
int step
Definition: topology.h:839
Definition: topology.h:753
unsigned int rates
Definition: topology.h:986
int index
Definition: topology.h:1087
const char * dai_name
Definition: topology.h:1051
Template type for private data objects.
Definition: topology.h:864
int id
Definition: topology.h:850
Stream Capabilities.
Definition: topology.h:983
int period_bytes
Definition: topology.h:975
int version
Definition: topology.h:1088
unsigned char invert_fsync
Definition: topology.h:1028
unsigned int mclk_rate
Definition: topology.h:1033
Definition: topology.h:750
const char * pcm_name
Definition: topology.h:1004