Skip to contentSkip to conversation

asoc: core - add Digital Audio Interface (DAI) control functions.

PATCH New Liam Girdwood 1 participant 1 message Jul 8, 2008

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/2 asoc: core - add Digital Audio Interface (DAI) control functions.

This patch adds several functions for DAI control and config and replaces the current method of calling function pointers within the DAI struct.

---
 include/sound/soc.h  |   21 ++++++++
 sound/soc/soc-core.c |  140 +++++++++++++++++++++++++++++++++++++++++++++++---
 2 files changed, 153 insertions(+), 8 deletions(-)
include/sound/soc.h +21 -0
index 778e57e..1890d87 100644
@@ -256,6 +256,27 @@ int snd_soc_new_ac97_codec(struct snd_soc_codec *codec,
 	struct snd_ac97_bus_ops *ops, int num);
 void snd_soc_free_ac97_codec(struct snd_soc_codec *codec);
 
+/* Digital Audio Interface clocking API.*/
+int snd_soc_dai_set_sysclk(struct snd_soc_dai *dai, int clk_id,
+	unsigned int freq, int dir);
+
+int snd_soc_dai_set_clkdiv(struct snd_soc_dai *dai,
+	int div_id, int div);
+
+int snd_soc_dai_set_pll(struct snd_soc_dai *dai,
+	int pll_id, unsigned int freq_in, unsigned int freq_out);
+
+/* Digital Audio interface formatting */
+int snd_soc_dai_set_fmt(struct snd_soc_dai *dai, unsigned int fmt);
+
+int snd_soc_dai_set_tdm_slot(struct snd_soc_dai *dai,
+	unsigned int mask, int slots);
+
+int snd_soc_dai_set_tristate(struct snd_soc_dai *dai, int tristate);
+
+/* Digital Audio Interface mute */
+int snd_soc_dai_digital_mute(struct snd_soc_dai *dai, int mute);
+
 /*
  *Controls
  */
sound/soc/soc-core.c +132 -8

170 lines not on this page · raw message

Signature · 1 line
1.5.4.2