diff options
author | Charles Keepax <ckeepax@opensource.cirrus.com> | 2019-10-21 14:58:13 +0100 |
---|---|---|
committer | Lee Jones <lee.jones@linaro.org> | 2019-11-11 08:45:03 +0000 |
commit | 1e624fce3a1ca03fcea167cc43399d0073472edc (patch) | |
tree | c741a350d6568bd18b470f9463a19bb35927abcf /include/linux/mfd/madera | |
parent | c9d93428bf6212a61482a688d8201e66de9c0a0b (diff) |
mfd: madera: Add support for requesting the supply clocks
Add the ability to get the clock for each clock input pin of the chip
and enable MCLK2 since that is expected to be a permanently enabled
32kHz clock.
Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
Diffstat (limited to 'include/linux/mfd/madera')
-rw-r--r-- | include/linux/mfd/madera/core.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/include/linux/mfd/madera/core.h b/include/linux/mfd/madera/core.h index 7ffa696cce7c..ad2c138105d4 100644 --- a/include/linux/mfd/madera/core.h +++ b/include/linux/mfd/madera/core.h @@ -8,6 +8,7 @@ #ifndef MADERA_CORE_H #define MADERA_CORE_H +#include <linux/clk.h> #include <linux/gpio/consumer.h> #include <linux/interrupt.h> #include <linux/mfd/madera/pdata.h> @@ -29,6 +30,13 @@ enum madera_type { CS42L92 = 9, }; +enum { + MADERA_MCLK1, + MADERA_MCLK2, + MADERA_MCLK3, + MADERA_NUM_MCLK +}; + #define MADERA_MAX_CORE_SUPPLIES 2 #define MADERA_MAX_GPIOS 40 @@ -155,6 +163,7 @@ struct snd_soc_dapm_context; * @irq_dev: the irqchip child driver device * @irq_data: pointer to irqchip data for the child irqchip driver * @irq: host irq number from SPI or I2C configuration + * @mclk: Structure holding clock supplies * @out_clamp: indicates output clamp state for each analogue output * @out_shorted: indicates short circuit state for each analogue output * @hp_ena: bitflags of enable state for the headphone outputs @@ -184,6 +193,8 @@ struct madera { struct regmap_irq_chip_data *irq_data; int irq; + struct clk_bulk_data mclk[MADERA_NUM_MCLK]; + unsigned int num_micbias; unsigned int num_childbias[MADERA_MAX_MICBIAS]; |