Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ASoC: dapm: Add new widget type for constructing DAPM graphs on DSPs.

Add some DAPM widget types to better support the construction of DAPM
graphs within DSPs.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>

authored by

Liam Girdwood and committed by
Mark Brown
8a70b454 2ea659a9

+42 -1
+18
Documentation/sound/soc/dapm.rst
··· 105 105 Special PRE widget (exec before all others) 106 106 Post 107 107 Special POST widget (exec after all others) 108 + Buffer 109 + Inter widget audio data buffer within a DSP. 110 + Scheduler 111 + DSP internal scheduler that schedules component/pipeline processing 112 + work. 113 + Effect 114 + Widget that performs an audio processing effect. 115 + SRC 116 + Sample Rate Converter within DSP or CODEC 117 + ASRC 118 + Asynchronous Sample Rate Converter within DSP or CODEC 119 + Encoder 120 + Widget that encodes audio data from one format (usually PCM) to another 121 + usually more compressed format. 122 + Decoder 123 + Widget that decodes audio data from a compressed format to an 124 + uncompressed format like PCM. 125 + 108 126 109 127 (Widgets are defined in include/sound/soc-dapm.h) 110 128
+7
include/sound/soc-dapm.h
··· 510 510 snd_soc_dapm_dai_out, 511 511 snd_soc_dapm_dai_link, /* link between two DAI structures */ 512 512 snd_soc_dapm_kcontrol, /* Auto-disabled kcontrol */ 513 + snd_soc_dapm_buffer, /* DSP/CODEC internal buffer */ 514 + snd_soc_dapm_scheduler, /* DSP/CODEC internal scheduler */ 515 + snd_soc_dapm_effect, /* DSP/CODEC effect component */ 516 + snd_soc_dapm_src, /* DSP/CODEC SRC component */ 517 + snd_soc_dapm_asrc, /* DSP/CODEC ASRC component */ 518 + snd_soc_dapm_encoder, /* FW/SW audio encoder component */ 519 + snd_soc_dapm_decoder, /* FW/SW audio decoder component */ 513 520 }; 514 521 515 522 enum snd_soc_dapm_subclass {
+9 -1
include/uapi/sound/asoc.h
··· 73 73 #define SND_SOC_TPLG_DAPM_DAI_IN 13 74 74 #define SND_SOC_TPLG_DAPM_DAI_OUT 14 75 75 #define SND_SOC_TPLG_DAPM_DAI_LINK 15 76 - #define SND_SOC_TPLG_DAPM_LAST SND_SOC_TPLG_DAPM_DAI_LINK 76 + #define SND_SOC_TPLG_DAPM_BUFFER 16 77 + #define SND_SOC_TPLG_DAPM_SCHEDULER 17 78 + #define SND_SOC_TPLG_DAPM_EFFECT 18 79 + #define SND_SOC_TPLG_DAPM_SIGGEN 19 80 + #define SND_SOC_TPLG_DAPM_SRC 20 81 + #define SND_SOC_TPLG_DAPM_ASRC 21 82 + #define SND_SOC_TPLG_DAPM_ENCODER 22 83 + #define SND_SOC_TPLG_DAPM_DECODER 23 84 + #define SND_SOC_TPLG_DAPM_LAST SND_SOC_TPLG_DAPM_DECODER 77 85 78 86 /* Header magic number and string sizes */ 79 87 #define SND_SOC_TPLG_MAGIC 0x41536F43 /* ASoC */
+8
sound/soc/soc-topology.c
··· 242 242 {SND_SOC_TPLG_DAPM_DAI_IN, snd_soc_dapm_dai_in}, 243 243 {SND_SOC_TPLG_DAPM_DAI_OUT, snd_soc_dapm_dai_out}, 244 244 {SND_SOC_TPLG_DAPM_DAI_LINK, snd_soc_dapm_dai_link}, 245 + {SND_SOC_TPLG_DAPM_BUFFER, snd_soc_dapm_buffer}, 246 + {SND_SOC_TPLG_DAPM_SCHEDULER, snd_soc_dapm_scheduler}, 247 + {SND_SOC_TPLG_DAPM_EFFECT, snd_soc_dapm_effect}, 248 + {SND_SOC_TPLG_DAPM_SIGGEN, snd_soc_dapm_siggen}, 249 + {SND_SOC_TPLG_DAPM_SRC, snd_soc_dapm_src}, 250 + {SND_SOC_TPLG_DAPM_ASRC, snd_soc_dapm_asrc}, 251 + {SND_SOC_TPLG_DAPM_ENCODER, snd_soc_dapm_encoder}, 252 + {SND_SOC_TPLG_DAPM_DECODER, snd_soc_dapm_decoder}, 245 253 }; 246 254 247 255 static int tplc_chan_get_reg(struct soc_tplg *tplg,