aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/linux/mfd/arizona/core.h3
-rw-r--r--include/linux/mfd/arizona/registers.h42
-rw-r--r--include/linux/mfd/wm8994/pdata.h8
-rw-r--r--include/sound/dmaengine_pcm.h27
-rw-r--r--include/sound/soc-dai.h8
-rw-r--r--include/sound/soc.h20
-rw-r--r--include/sound/tas5086.h7
-rw-r--r--include/sound/tegra_wm8903.h26
8 files changed, 104 insertions, 37 deletions
diff --git a/include/linux/mfd/arizona/core.h b/include/linux/mfd/arizona/core.h
index a710255528d7..cc281368dc55 100644
--- a/include/linux/mfd/arizona/core.h
+++ b/include/linux/mfd/arizona/core.h
@@ -100,6 +100,9 @@ struct arizona {
100 struct regmap_irq_chip_data *aod_irq_chip; 100 struct regmap_irq_chip_data *aod_irq_chip;
101 struct regmap_irq_chip_data *irq_chip; 101 struct regmap_irq_chip_data *irq_chip;
102 102
103 bool hpdet_magic;
104 unsigned int hp_ena;
105
103 struct mutex clk_lock; 106 struct mutex clk_lock;
104 int clk32k_ref; 107 int clk32k_ref;
105 108
diff --git a/include/linux/mfd/arizona/registers.h b/include/linux/mfd/arizona/registers.h
index 340355136069..a47fd358016f 100644
--- a/include/linux/mfd/arizona/registers.h
+++ b/include/linux/mfd/arizona/registers.h
@@ -85,12 +85,14 @@
85#define ARIZONA_FLL1_CONTROL_6 0x176 85#define ARIZONA_FLL1_CONTROL_6 0x176
86#define ARIZONA_FLL1_LOOP_FILTER_TEST_1 0x177 86#define ARIZONA_FLL1_LOOP_FILTER_TEST_1 0x177
87#define ARIZONA_FLL1_NCO_TEST_0 0x178 87#define ARIZONA_FLL1_NCO_TEST_0 0x178
88#define ARIZONA_FLL1_CONTROL_7 0x179
88#define ARIZONA_FLL1_SYNCHRONISER_1 0x181 89#define ARIZONA_FLL1_SYNCHRONISER_1 0x181
89#define ARIZONA_FLL1_SYNCHRONISER_2 0x182 90#define ARIZONA_FLL1_SYNCHRONISER_2 0x182
90#define ARIZONA_FLL1_SYNCHRONISER_3 0x183 91#define ARIZONA_FLL1_SYNCHRONISER_3 0x183
91#define ARIZONA_FLL1_SYNCHRONISER_4 0x184 92#define ARIZONA_FLL1_SYNCHRONISER_4 0x184
92#define ARIZONA_FLL1_SYNCHRONISER_5 0x185 93#define ARIZONA_FLL1_SYNCHRONISER_5 0x185
93#define ARIZONA_FLL1_SYNCHRONISER_6 0x186 94#define ARIZONA_FLL1_SYNCHRONISER_6 0x186
95#define ARIZONA_FLL1_SYNCHRONISER_7 0x187
94#define ARIZONA_FLL1_SPREAD_SPECTRUM 0x189 96#define ARIZONA_FLL1_SPREAD_SPECTRUM 0x189
95#define ARIZONA_FLL1_GPIO_CLOCK 0x18A 97#define ARIZONA_FLL1_GPIO_CLOCK 0x18A
96#define ARIZONA_FLL2_CONTROL_1 0x191 98#define ARIZONA_FLL2_CONTROL_1 0x191
@@ -101,12 +103,14 @@
101#define ARIZONA_FLL2_CONTROL_6 0x196 103#define ARIZONA_FLL2_CONTROL_6 0x196
102#define ARIZONA_FLL2_LOOP_FILTER_TEST_1 0x197 104#define ARIZONA_FLL2_LOOP_FILTER_TEST_1 0x197
103#define ARIZONA_FLL2_NCO_TEST_0 0x198 105#define ARIZONA_FLL2_NCO_TEST_0 0x198
106#define ARIZONA_FLL2_CONTROL_7 0x199
104#define ARIZONA_FLL2_SYNCHRONISER_1 0x1A1 107#define ARIZONA_FLL2_SYNCHRONISER_1 0x1A1
105#define ARIZONA_FLL2_SYNCHRONISER_2 0x1A2 108#define ARIZONA_FLL2_SYNCHRONISER_2 0x1A2
106#define ARIZONA_FLL2_SYNCHRONISER_3 0x1A3 109#define ARIZONA_FLL2_SYNCHRONISER_3 0x1A3
107#define ARIZONA_FLL2_SYNCHRONISER_4 0x1A4 110#define ARIZONA_FLL2_SYNCHRONISER_4 0x1A4
108#define ARIZONA_FLL2_SYNCHRONISER_5 0x1A5 111#define ARIZONA_FLL2_SYNCHRONISER_5 0x1A5
109#define ARIZONA_FLL2_SYNCHRONISER_6 0x1A6 112#define ARIZONA_FLL2_SYNCHRONISER_6 0x1A6
113#define ARIZONA_FLL2_SYNCHRONISER_7 0x1A7
110#define ARIZONA_FLL2_SPREAD_SPECTRUM 0x1A9 114#define ARIZONA_FLL2_SPREAD_SPECTRUM 0x1A9
111#define ARIZONA_FLL2_GPIO_CLOCK 0x1AA 115#define ARIZONA_FLL2_GPIO_CLOCK 0x1AA
112#define ARIZONA_MIC_CHARGE_PUMP_1 0x200 116#define ARIZONA_MIC_CHARGE_PUMP_1 0x200
@@ -213,6 +217,8 @@
213#define ARIZONA_PDM_SPK1_CTRL_2 0x491 217#define ARIZONA_PDM_SPK1_CTRL_2 0x491
214#define ARIZONA_PDM_SPK2_CTRL_1 0x492 218#define ARIZONA_PDM_SPK2_CTRL_1 0x492
215#define ARIZONA_PDM_SPK2_CTRL_2 0x493 219#define ARIZONA_PDM_SPK2_CTRL_2 0x493
220#define ARIZONA_SPK_CTRL_2 0x4B5
221#define ARIZONA_SPK_CTRL_3 0x4B6
216#define ARIZONA_DAC_COMP_1 0x4DC 222#define ARIZONA_DAC_COMP_1 0x4DC
217#define ARIZONA_DAC_COMP_2 0x4DD 223#define ARIZONA_DAC_COMP_2 0x4DD
218#define ARIZONA_DAC_COMP_3 0x4DE 224#define ARIZONA_DAC_COMP_3 0x4DE
@@ -1678,6 +1684,13 @@
1678#define ARIZONA_FLL1_FRC_INTEG_VAL_WIDTH 12 /* FLL1_FRC_INTEG_VAL - [11:0] */ 1684#define ARIZONA_FLL1_FRC_INTEG_VAL_WIDTH 12 /* FLL1_FRC_INTEG_VAL - [11:0] */
1679 1685
1680/* 1686/*
1687 * R377 (0x179) - FLL1 Control 7
1688 */
1689#define ARIZONA_FLL1_GAIN_MASK 0x003c /* FLL1_GAIN */
1690#define ARIZONA_FLL1_GAIN_SHIFT 2 /* FLL1_GAIN */
1691#define ARIZONA_FLL1_GAIN_WIDTH 4 /* FLL1_GAIN */
1692
1693/*
1681 * R385 (0x181) - FLL1 Synchroniser 1 1694 * R385 (0x181) - FLL1 Synchroniser 1
1682 */ 1695 */
1683#define ARIZONA_FLL1_SYNC_ENA 0x0001 /* FLL1_SYNC_ENA */ 1696#define ARIZONA_FLL1_SYNC_ENA 0x0001 /* FLL1_SYNC_ENA */
@@ -1724,6 +1737,17 @@
1724#define ARIZONA_FLL1_CLK_SYNC_SRC_WIDTH 4 /* FLL1_CLK_SYNC_SRC - [3:0] */ 1737#define ARIZONA_FLL1_CLK_SYNC_SRC_WIDTH 4 /* FLL1_CLK_SYNC_SRC - [3:0] */
1725 1738
1726/* 1739/*
1740 * R391 (0x187) - FLL1 Synchroniser 7
1741 */
1742#define ARIZONA_FLL1_SYNC_GAIN_MASK 0x003c /* FLL1_SYNC_GAIN */
1743#define ARIZONA_FLL1_SYNC_GAIN_SHIFT 2 /* FLL1_SYNC_GAIN */
1744#define ARIZONA_FLL1_SYNC_GAIN_WIDTH 4 /* FLL1_SYNC_GAIN */
1745#define ARIZONA_FLL1_SYNC_BW 0x0001 /* FLL1_SYNC_BW */
1746#define ARIZONA_FLL1_SYNC_BW_MASK 0x0001 /* FLL1_SYNC_BW */
1747#define ARIZONA_FLL1_SYNC_BW_SHIFT 0 /* FLL1_SYNC_BW */
1748#define ARIZONA_FLL1_SYNC_BW_WIDTH 1 /* FLL1_SYNC_BW */
1749
1750/*
1727 * R393 (0x189) - FLL1 Spread Spectrum 1751 * R393 (0x189) - FLL1 Spread Spectrum
1728 */ 1752 */
1729#define ARIZONA_FLL1_SS_AMPL_MASK 0x0030 /* FLL1_SS_AMPL - [5:4] */ 1753#define ARIZONA_FLL1_SS_AMPL_MASK 0x0030 /* FLL1_SS_AMPL - [5:4] */
@@ -1816,6 +1840,13 @@
1816#define ARIZONA_FLL2_FRC_INTEG_VAL_WIDTH 12 /* FLL2_FRC_INTEG_VAL - [11:0] */ 1840#define ARIZONA_FLL2_FRC_INTEG_VAL_WIDTH 12 /* FLL2_FRC_INTEG_VAL - [11:0] */
1817 1841
1818/* 1842/*
1843 * R409 (0x199) - FLL2 Control 7
1844 */
1845#define ARIZONA_FLL2_GAIN_MASK 0x003c /* FLL2_GAIN */
1846#define ARIZONA_FLL2_GAIN_SHIFT 2 /* FLL2_GAIN */
1847#define ARIZONA_FLL2_GAIN_WIDTH 4 /* FLL2_GAIN */
1848
1849/*
1819 * R417 (0x1A1) - FLL2 Synchroniser 1 1850 * R417 (0x1A1) - FLL2 Synchroniser 1
1820 */ 1851 */
1821#define ARIZONA_FLL2_SYNC_ENA 0x0001 /* FLL2_SYNC_ENA */ 1852#define ARIZONA_FLL2_SYNC_ENA 0x0001 /* FLL2_SYNC_ENA */
@@ -1862,6 +1893,17 @@
1862#define ARIZONA_FLL2_CLK_SYNC_SRC_WIDTH 4 /* FLL2_CLK_SYNC_SRC - [3:0] */ 1893#define ARIZONA_FLL2_CLK_SYNC_SRC_WIDTH 4 /* FLL2_CLK_SYNC_SRC - [3:0] */
1863 1894
1864/* 1895/*
1896 * R423 (0x1A7) - FLL2 Synchroniser 7
1897 */
1898#define ARIZONA_FLL2_SYNC_GAIN_MASK 0x003c /* FLL2_SYNC_GAIN */
1899#define ARIZONA_FLL2_SYNC_GAIN_SHIFT 2 /* FLL2_SYNC_GAIN */
1900#define ARIZONA_FLL2_SYNC_GAIN_WIDTH 4 /* FLL2_SYNC_GAIN */
1901#define ARIZONA_FLL2_SYNC_BW_MASK 0x0001 /* FLL2_SYNC_BW */
1902#define ARIZONA_FLL2_SYNC_BW_MASK 0x0001 /* FLL2_SYNC_BW */
1903#define ARIZONA_FLL2_SYNC_BW_SHIFT 0 /* FLL2_SYNC_BW */
1904#define ARIZONA_FLL2_SYNC_BW_WIDTH 1 /* FLL2_SYNC_BW */
1905
1906/*
1865 * R425 (0x1A9) - FLL2 Spread Spectrum 1907 * R425 (0x1A9) - FLL2 Spread Spectrum
1866 */ 1908 */
1867#define ARIZONA_FLL2_SS_AMPL_MASK 0x0030 /* FLL2_SS_AMPL - [5:4] */ 1909#define ARIZONA_FLL2_SS_AMPL_MASK 0x0030 /* FLL2_SS_AMPL - [5:4] */
diff --git a/include/linux/mfd/wm8994/pdata.h b/include/linux/mfd/wm8994/pdata.h
index 8e21a094836d..68e776594889 100644
--- a/include/linux/mfd/wm8994/pdata.h
+++ b/include/linux/mfd/wm8994/pdata.h
@@ -17,6 +17,7 @@
17 17
18#define WM8994_NUM_LDO 2 18#define WM8994_NUM_LDO 2
19#define WM8994_NUM_GPIO 11 19#define WM8994_NUM_GPIO 11
20#define WM8994_NUM_AIF 3
20 21
21struct wm8994_ldo_pdata { 22struct wm8994_ldo_pdata {
22 /** GPIOs to enable regulator, 0 or less if not available */ 23 /** GPIOs to enable regulator, 0 or less if not available */
@@ -215,6 +216,13 @@ struct wm8994_pdata {
215 * system. 216 * system.
216 */ 217 */
217 bool spkmode_pu; 218 bool spkmode_pu;
219
220 /**
221 * Maximum number of channels clocks will be generated for,
222 * useful for systems where and I2S bus with multiple data
223 * lines is mastered.
224 */
225 int max_channels_clocked[WM8994_NUM_AIF];
218}; 226};
219 227
220#endif 228#endif
diff --git a/include/sound/dmaengine_pcm.h b/include/sound/dmaengine_pcm.h
index b877334bbb0f..95620428a59b 100644
--- a/include/sound/dmaengine_pcm.h
+++ b/include/sound/dmaengine_pcm.h
@@ -32,9 +32,6 @@ snd_pcm_substream_to_dma_direction(const struct snd_pcm_substream *substream)
32 return DMA_DEV_TO_MEM; 32 return DMA_DEV_TO_MEM;
33} 33}
34 34
35void snd_dmaengine_pcm_set_data(struct snd_pcm_substream *substream, void *data);
36void *snd_dmaengine_pcm_get_data(struct snd_pcm_substream *substream);
37
38int snd_hwparams_to_dma_slave_config(const struct snd_pcm_substream *substream, 35int snd_hwparams_to_dma_slave_config(const struct snd_pcm_substream *substream,
39 const struct snd_pcm_hw_params *params, struct dma_slave_config *slave_config); 36 const struct snd_pcm_hw_params *params, struct dma_slave_config *slave_config);
40int snd_dmaengine_pcm_trigger(struct snd_pcm_substream *substream, int cmd); 37int snd_dmaengine_pcm_trigger(struct snd_pcm_substream *substream, int cmd);
@@ -47,4 +44,28 @@ int snd_dmaengine_pcm_close(struct snd_pcm_substream *substream);
47 44
48struct dma_chan *snd_dmaengine_pcm_get_chan(struct snd_pcm_substream *substream); 45struct dma_chan *snd_dmaengine_pcm_get_chan(struct snd_pcm_substream *substream);
49 46
47/**
48 * struct snd_dmaengine_dai_dma_data - DAI DMA configuration data
49 * @addr: Address of the DAI data source or destination register.
50 * @addr_width: Width of the DAI data source or destination register.
51 * @maxburst: Maximum number of words(note: words, as in units of the
52 * src_addr_width member, not bytes) that can be send to or received from the
53 * DAI in one burst.
54 * @slave_id: Slave requester id for the DMA channel.
55 * @filter_data: Custom DMA channel filter data, this will usually be used when
56 * requesting the DMA channel.
57 */
58struct snd_dmaengine_dai_dma_data {
59 dma_addr_t addr;
60 enum dma_slave_buswidth addr_width;
61 u32 maxburst;
62 unsigned int slave_id;
63 void *filter_data;
64};
65
66void snd_dmaengine_pcm_set_config_from_dai_data(
67 const struct snd_pcm_substream *substream,
68 const struct snd_dmaengine_dai_dma_data *dma_data,
69 struct dma_slave_config *config);
70
50#endif 71#endif
diff --git a/include/sound/soc-dai.h b/include/sound/soc-dai.h
index 3d84808952b9..ae9a227d35d3 100644
--- a/include/sound/soc-dai.h
+++ b/include/sound/soc-dai.h
@@ -95,14 +95,6 @@ struct snd_soc_dai_driver;
95struct snd_soc_dai; 95struct snd_soc_dai;
96struct snd_ac97_bus_ops; 96struct snd_ac97_bus_ops;
97 97
98/* Digital Audio Interface registration */
99int snd_soc_register_dai(struct device *dev,
100 struct snd_soc_dai_driver *dai_drv);
101void snd_soc_unregister_dai(struct device *dev);
102int snd_soc_register_dais(struct device *dev,
103 struct snd_soc_dai_driver *dai_drv, size_t count);
104void snd_soc_unregister_dais(struct device *dev, size_t count);
105
106/* Digital Audio Interface clocking API.*/ 98/* Digital Audio Interface clocking API.*/
107int snd_soc_dai_set_sysclk(struct snd_soc_dai *dai, int clk_id, 99int snd_soc_dai_set_sysclk(struct snd_soc_dai *dai, int clk_id,
108 unsigned int freq, int dir); 100 unsigned int freq, int dir);
diff --git a/include/sound/soc.h b/include/sound/soc.h
index f619905f0a65..9eb0e4db4835 100644
--- a/include/sound/soc.h
+++ b/include/sound/soc.h
@@ -324,6 +324,8 @@ struct snd_soc_dai_link;
324struct snd_soc_platform_driver; 324struct snd_soc_platform_driver;
325struct snd_soc_codec; 325struct snd_soc_codec;
326struct snd_soc_codec_driver; 326struct snd_soc_codec_driver;
327struct snd_soc_component;
328struct snd_soc_component_driver;
327struct soc_enum; 329struct soc_enum;
328struct snd_soc_jack; 330struct snd_soc_jack;
329struct snd_soc_jack_zone; 331struct snd_soc_jack_zone;
@@ -377,6 +379,10 @@ int snd_soc_register_codec(struct device *dev,
377 const struct snd_soc_codec_driver *codec_drv, 379 const struct snd_soc_codec_driver *codec_drv,
378 struct snd_soc_dai_driver *dai_drv, int num_dai); 380 struct snd_soc_dai_driver *dai_drv, int num_dai);
379void snd_soc_unregister_codec(struct device *dev); 381void snd_soc_unregister_codec(struct device *dev);
382int snd_soc_register_component(struct device *dev,
383 const struct snd_soc_component_driver *cmpnt_drv,
384 struct snd_soc_dai_driver *dai_drv, int num_dai);
385void snd_soc_unregister_component(struct device *dev);
380int snd_soc_codec_volatile_register(struct snd_soc_codec *codec, 386int snd_soc_codec_volatile_register(struct snd_soc_codec *codec,
381 unsigned int reg); 387 unsigned int reg);
382int snd_soc_codec_readable_register(struct snd_soc_codec *codec, 388int snd_soc_codec_readable_register(struct snd_soc_codec *codec,
@@ -841,6 +847,20 @@ struct snd_soc_platform {
841#endif 847#endif
842}; 848};
843 849
850struct snd_soc_component_driver {
851 const char *name;
852};
853
854struct snd_soc_component {
855 const char *name;
856 int id;
857 int num_dai;
858 struct device *dev;
859 struct list_head list;
860
861 const struct snd_soc_component_driver *driver;
862};
863
844struct snd_soc_dai_link { 864struct snd_soc_dai_link {
845 /* config - must be set by machine driver */ 865 /* config - must be set by machine driver */
846 const char *name; /* Codec name */ 866 const char *name; /* Codec name */
diff --git a/include/sound/tas5086.h b/include/sound/tas5086.h
new file mode 100644
index 000000000000..aac481b7db8f
--- /dev/null
+++ b/include/sound/tas5086.h
@@ -0,0 +1,7 @@
1#ifndef _SND_SOC_CODEC_TAS5086_H_
2#define _SND_SOC_CODEC_TAS5086_H_
3
4#define TAS5086_CLK_IDX_MCLK 0
5#define TAS5086_CLK_IDX_SCLK 1
6
7#endif /* _SND_SOC_CODEC_TAS5086_H_ */
diff --git a/include/sound/tegra_wm8903.h b/include/sound/tegra_wm8903.h
deleted file mode 100644
index 57b202ee97c3..000000000000
--- a/include/sound/tegra_wm8903.h
+++ /dev/null
@@ -1,26 +0,0 @@
1/*
2 * Copyright 2011 NVIDIA, Inc.
3 *
4 * This software is licensed under the terms of the GNU General Public
5 * License version 2, as published by the Free Software Foundation, and
6 * may be copied, distributed, and modified under those terms.
7 *
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 */
14
15#ifndef __SOUND_TEGRA_WM38903_H
16#define __SOUND_TEGRA_WM38903_H
17
18struct tegra_wm8903_platform_data {
19 int gpio_spkr_en;
20 int gpio_hp_det;
21 int gpio_hp_mute;
22 int gpio_int_mic_en;
23 int gpio_ext_mic_en;
24};
25
26#endif