ASoC: add Component level set_sysclk
[sfrench/cifs-2.6.git] / include / sound / soc.h
index 3e0070ed68837a1077ac994e21dc50c4c5e77374..813cdb95e049c16aaeb28ff200d70eb7384f3992 100644 (file)
@@ -795,9 +795,9 @@ struct snd_soc_component_driver {
        int (*suspend)(struct snd_soc_component *);
        int (*resume)(struct snd_soc_component *);
 
-       /* pcm creation and destruction */
-       int (*pcm_new)(struct snd_soc_pcm_runtime *);
-       void (*pcm_free)(struct snd_pcm *);
+       /* component wide operations */
+       int (*set_sysclk)(struct snd_soc_component *component,
+                         int clk_id, int source, unsigned int freq, int dir);
 
        /* DT */
        int (*of_xlate_dai_name)(struct snd_soc_component *component,
@@ -862,16 +862,15 @@ struct snd_soc_component {
        /* Don't use these, use snd_soc_component_get_dapm() */
        struct snd_soc_dapm_context dapm;
 
-       const struct snd_soc_dapm_route *dapm_routes;
-       unsigned int num_dapm_routes;
        struct snd_soc_codec *codec;
 
        int (*probe)(struct snd_soc_component *);
        void (*remove)(struct snd_soc_component *);
        int (*suspend)(struct snd_soc_component *);
        int (*resume)(struct snd_soc_component *);
-       int (*pcm_new)(struct snd_soc_pcm_runtime *);
-       void (*pcm_free)(struct snd_pcm *);
+
+       int (*set_sysclk)(struct snd_soc_component *component,
+                         int clk_id, int source, unsigned int freq, int dir);
 
        /* machine specific init */
        int (*init)(struct snd_soc_component *component);
@@ -1467,6 +1466,10 @@ void snd_soc_component_async_complete(struct snd_soc_component *component);
 int snd_soc_component_test_bits(struct snd_soc_component *component,
        unsigned int reg, unsigned int mask, unsigned int value);
 
+/* component wide operations */
+int snd_soc_component_set_sysclk(struct snd_soc_component *component,
+                       int clk_id, int source, unsigned int freq, int dir);
+
 #ifdef CONFIG_REGMAP
 
 void snd_soc_component_init_regmap(struct snd_soc_component *component,