ASoC: Allow DAI links to be specified using device tree nodes
[cascardo/linux.git] / include / sound / soc.h
index b21b304..8391b0e 100644 (file)
@@ -231,6 +231,7 @@ enum snd_soc_bias_level {
        SND_SOC_BIAS_ON = 3,
 };
 
+struct device_node;
 struct snd_jack;
 struct snd_soc_card;
 struct snd_soc_pcm_stream;
@@ -266,7 +267,6 @@ enum snd_soc_control_type {
 
 enum snd_soc_compress_type {
        SND_SOC_FLAT_COMPRESSION = 1,
-       SND_SOC_RBTREE_COMPRESSION
 };
 
 enum snd_soc_pcm_subclass {
@@ -592,8 +592,7 @@ struct snd_soc_codec_driver {
        /* driver ops */
        int (*probe)(struct snd_soc_codec *);
        int (*remove)(struct snd_soc_codec *);
-       int (*suspend)(struct snd_soc_codec *,
-                       pm_message_t state);
+       int (*suspend)(struct snd_soc_codec *);
        int (*resume)(struct snd_soc_codec *);
 
        /* Default control and setup, added after probe() is run */
@@ -705,8 +704,11 @@ struct snd_soc_dai_link {
        const char *name;                       /* Codec name */
        const char *stream_name;                /* Stream name */
        const char *codec_name;         /* for multi-codec */
+       const struct device_node *codec_of_node;
        const char *platform_name;      /* for multi-platform */
+       const struct device_node *platform_of_node;
        const char *cpu_dai_name;
+       const struct device_node *cpu_dai_of_node;
        const char *codec_dai_name;
 
        unsigned int dai_fmt;           /* format to set on init */
@@ -815,6 +817,7 @@ struct snd_soc_card {
        int num_dapm_widgets;
        const struct snd_soc_dapm_route *dapm_routes;
        int num_dapm_routes;
+       bool fully_routed;
 
        struct work_struct deferred_resume_work;
 
@@ -962,6 +965,11 @@ static inline bool snd_soc_volsw_is_stereo(struct soc_mixer_control *mc)
 int snd_soc_util_init(void);
 void snd_soc_util_exit(void);
 
+int snd_soc_of_parse_card_name(struct snd_soc_card *card,
+                              const char *propname);
+int snd_soc_of_parse_audio_routing(struct snd_soc_card *card,
+                                  const char *propname);
+
 #include <sound/soc-dai.h>
 
 #ifdef CONFIG_DEBUG_FS