diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-08-07 20:07:31 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-08-07 20:07:31 -0400 |
commit | faa38b5e0e092914764cdba9f83d31a3f794d182 (patch) | |
tree | b3e5921bdc36378033b4910eb4f29cb0dfc486e0 /include/sound | |
parent | 78417334b5cb6e1f915b8fdcc4fce3f1a1b4420c (diff) | |
parent | 74bf40f0793fed9e01eb6164c2ce63e8c27ca205 (diff) |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6: (214 commits)
ALSA: hda - Add pin-fix for HP dc5750
ALSA: als4000: Fix potentially invalid DMA mode setup
ALSA: als4000: enable burst mode
ALSA: hda - Fix initial capsrc selection in patch_alc269()
ASoC: TWL4030: Capture route runtime DAPM ordering fix
ALSA: hda - Add PC-beep whitelist for an Intel board
ALSA: hda - More relax for pending period handling
ALSA: hda - Define AC_FMT_* constants
ALSA: hda - Fix beep frequency on IDT 92HD73xx and 92HD71Bxx codecs
ALSA: hda - Add support for HDMI HBR passthrough
ALSA: hda - Set Stream Type in Stream Format according to AES0
ALSA: hda - Fix Thinkpad X300 so SPDIF is not exposed
ALSA: hda - FIX to not expose SPDIF on Thinkpad X301, since it does not have the ability to use SPDIF
ASoC: wm9081: fix resource reclaim in wm9081_register error path
ASoC: wm8978: fix a memory leak if a wm8978_register fail
ASoC: wm8974: fix a memory leak if another WM8974 is registered
ASoC: wm8961: fix resource reclaim in wm8961_register error path
ASoC: wm8955: fix resource reclaim in wm8955_register error path
ASoC: wm8940: fix a memory leak if wm8940_register return error
ASoC: wm8904: fix resource reclaim in wm8904_register error path
...
Diffstat (limited to 'include/sound')
-rw-r--r-- | include/sound/asound.h | 6 | ||||
-rw-r--r-- | include/sound/pcm.h | 6 | ||||
-rw-r--r-- | include/sound/sh_fsi.h | 49 | ||||
-rw-r--r-- | include/sound/soc-dapm.h | 2 | ||||
-rw-r--r-- | include/sound/soc.h | 21 | ||||
-rw-r--r-- | include/sound/tlv320dac33-plat.h | 2 | ||||
-rw-r--r-- | include/sound/uda134x.h | 12 |
7 files changed, 90 insertions, 8 deletions
diff --git a/include/sound/asound.h b/include/sound/asound.h index 9f1eecf99e6b..a1803ecea34d 100644 --- a/include/sound/asound.h +++ b/include/sound/asound.h | |||
@@ -212,7 +212,11 @@ typedef int __bitwise snd_pcm_format_t; | |||
212 | #define SNDRV_PCM_FORMAT_S18_3BE ((__force snd_pcm_format_t) 41) /* in three bytes */ | 212 | #define SNDRV_PCM_FORMAT_S18_3BE ((__force snd_pcm_format_t) 41) /* in three bytes */ |
213 | #define SNDRV_PCM_FORMAT_U18_3LE ((__force snd_pcm_format_t) 42) /* in three bytes */ | 213 | #define SNDRV_PCM_FORMAT_U18_3LE ((__force snd_pcm_format_t) 42) /* in three bytes */ |
214 | #define SNDRV_PCM_FORMAT_U18_3BE ((__force snd_pcm_format_t) 43) /* in three bytes */ | 214 | #define SNDRV_PCM_FORMAT_U18_3BE ((__force snd_pcm_format_t) 43) /* in three bytes */ |
215 | #define SNDRV_PCM_FORMAT_LAST SNDRV_PCM_FORMAT_U18_3BE | 215 | #define SNDRV_PCM_FORMAT_G723_24 ((__force snd_pcm_format_t) 44) /* 8 samples in 3 bytes */ |
216 | #define SNDRV_PCM_FORMAT_G723_24_1B ((__force snd_pcm_format_t) 45) /* 1 sample in 1 byte */ | ||
217 | #define SNDRV_PCM_FORMAT_G723_40 ((__force snd_pcm_format_t) 46) /* 8 Samples in 5 bytes */ | ||
218 | #define SNDRV_PCM_FORMAT_G723_40_1B ((__force snd_pcm_format_t) 47) /* 1 sample in 1 byte */ | ||
219 | #define SNDRV_PCM_FORMAT_LAST SNDRV_PCM_FORMAT_G723_40_1B | ||
216 | 220 | ||
217 | #ifdef SNDRV_LITTLE_ENDIAN | 221 | #ifdef SNDRV_LITTLE_ENDIAN |
218 | #define SNDRV_PCM_FORMAT_S16 SNDRV_PCM_FORMAT_S16_LE | 222 | #define SNDRV_PCM_FORMAT_S16 SNDRV_PCM_FORMAT_S16_LE |
diff --git a/include/sound/pcm.h b/include/sound/pcm.h index 6e3a29732dc4..85f1c6bf8566 100644 --- a/include/sound/pcm.h +++ b/include/sound/pcm.h | |||
@@ -174,6 +174,10 @@ struct snd_pcm_ops { | |||
174 | #define SNDRV_PCM_FMTBIT_U18_3LE (1ULL << SNDRV_PCM_FORMAT_U18_3LE) | 174 | #define SNDRV_PCM_FMTBIT_U18_3LE (1ULL << SNDRV_PCM_FORMAT_U18_3LE) |
175 | #define SNDRV_PCM_FMTBIT_S18_3BE (1ULL << SNDRV_PCM_FORMAT_S18_3BE) | 175 | #define SNDRV_PCM_FMTBIT_S18_3BE (1ULL << SNDRV_PCM_FORMAT_S18_3BE) |
176 | #define SNDRV_PCM_FMTBIT_U18_3BE (1ULL << SNDRV_PCM_FORMAT_U18_3BE) | 176 | #define SNDRV_PCM_FMTBIT_U18_3BE (1ULL << SNDRV_PCM_FORMAT_U18_3BE) |
177 | #define SNDRV_PCM_FMTBIT_G723_24 (1ULL << SNDRV_PCM_FORMAT_G723_24) | ||
178 | #define SNDRV_PCM_FMTBIT_G723_24_1B (1ULL << SNDRV_PCM_FORMAT_G723_24_1B) | ||
179 | #define SNDRV_PCM_FMTBIT_G723_40 (1ULL << SNDRV_PCM_FORMAT_G723_40) | ||
180 | #define SNDRV_PCM_FMTBIT_G723_40_1B (1ULL << SNDRV_PCM_FORMAT_G723_40_1B) | ||
177 | 181 | ||
178 | #ifdef SNDRV_LITTLE_ENDIAN | 182 | #ifdef SNDRV_LITTLE_ENDIAN |
179 | #define SNDRV_PCM_FMTBIT_S16 SNDRV_PCM_FMTBIT_S16_LE | 183 | #define SNDRV_PCM_FMTBIT_S16 SNDRV_PCM_FMTBIT_S16_LE |
@@ -313,7 +317,7 @@ struct snd_pcm_runtime { | |||
313 | struct snd_pcm_mmap_control *control; | 317 | struct snd_pcm_mmap_control *control; |
314 | 318 | ||
315 | /* -- locking / scheduling -- */ | 319 | /* -- locking / scheduling -- */ |
316 | unsigned int twake: 1; /* do transfer (!poll) wakeup */ | 320 | snd_pcm_uframes_t twake; /* do transfer (!poll) wakeup if non-zero */ |
317 | wait_queue_head_t sleep; /* poll sleep */ | 321 | wait_queue_head_t sleep; /* poll sleep */ |
318 | wait_queue_head_t tsleep; /* transfer sleep */ | 322 | wait_queue_head_t tsleep; /* transfer sleep */ |
319 | struct fasync_struct *fasync; | 323 | struct fasync_struct *fasync; |
diff --git a/include/sound/sh_fsi.h b/include/sound/sh_fsi.h index c0227361a876..9d51d6f35893 100644 --- a/include/sound/sh_fsi.h +++ b/include/sound/sh_fsi.h | |||
@@ -12,6 +12,9 @@ | |||
12 | * published by the Free Software Foundation. | 12 | * published by the Free Software Foundation. |
13 | */ | 13 | */ |
14 | 14 | ||
15 | #define FSI_PORT_A 0 | ||
16 | #define FSI_PORT_B 1 | ||
17 | |||
15 | /* flags format | 18 | /* flags format |
16 | 19 | ||
17 | * 0xABCDEEFF | 20 | * 0xABCDEEFF |
@@ -55,12 +58,14 @@ | |||
55 | #define SH_FSI_GET_IFMT(x) ((x >> 8) & SH_FSI_FMT_MASK) | 58 | #define SH_FSI_GET_IFMT(x) ((x >> 8) & SH_FSI_FMT_MASK) |
56 | #define SH_FSI_GET_OFMT(x) ((x >> 0) & SH_FSI_FMT_MASK) | 59 | #define SH_FSI_GET_OFMT(x) ((x >> 0) & SH_FSI_FMT_MASK) |
57 | 60 | ||
58 | #define SH_FSI_FMT_MONO (1 << 0) | 61 | #define SH_FSI_FMT_MONO 0 |
59 | #define SH_FSI_FMT_MONO_DELAY (1 << 1) | 62 | #define SH_FSI_FMT_MONO_DELAY 1 |
60 | #define SH_FSI_FMT_PCM (1 << 2) | 63 | #define SH_FSI_FMT_PCM 2 |
61 | #define SH_FSI_FMT_I2S (1 << 3) | 64 | #define SH_FSI_FMT_I2S 3 |
62 | #define SH_FSI_FMT_TDM (1 << 4) | 65 | #define SH_FSI_FMT_TDM 4 |
63 | #define SH_FSI_FMT_TDM_DELAY (1 << 5) | 66 | #define SH_FSI_FMT_TDM_DELAY 5 |
67 | #define SH_FSI_FMT_SPDIF 6 | ||
68 | |||
64 | 69 | ||
65 | #define SH_FSI_IFMT_TDM_CH(x) \ | 70 | #define SH_FSI_IFMT_TDM_CH(x) \ |
66 | (SH_FSI_IFMT(TDM) | SH_FSI_SET_CH_I(x)) | 71 | (SH_FSI_IFMT(TDM) | SH_FSI_SET_CH_I(x)) |
@@ -72,9 +77,41 @@ | |||
72 | #define SH_FSI_OFMT_TDM_DELAY_CH(x) \ | 77 | #define SH_FSI_OFMT_TDM_DELAY_CH(x) \ |
73 | (SH_FSI_OFMT(TDM_DELAY) | SH_FSI_SET_CH_O(x)) | 78 | (SH_FSI_OFMT(TDM_DELAY) | SH_FSI_SET_CH_O(x)) |
74 | 79 | ||
80 | |||
81 | /* | ||
82 | * set_rate return value | ||
83 | * | ||
84 | * see ACKMD/BPFMD on | ||
85 | * ACK_MD (FSI2) | ||
86 | * CKG1 (FSI) | ||
87 | * | ||
88 | * err: return value < 0 | ||
89 | * | ||
90 | * 0x-00000AB | ||
91 | * | ||
92 | * A: ACKMD value | ||
93 | * B: BPFMD value | ||
94 | */ | ||
95 | |||
96 | #define SH_FSI_ACKMD_MASK (0xF << 0) | ||
97 | #define SH_FSI_ACKMD_512 (1 << 0) | ||
98 | #define SH_FSI_ACKMD_256 (2 << 0) | ||
99 | #define SH_FSI_ACKMD_128 (3 << 0) | ||
100 | #define SH_FSI_ACKMD_64 (4 << 0) | ||
101 | #define SH_FSI_ACKMD_32 (5 << 0) | ||
102 | |||
103 | #define SH_FSI_BPFMD_MASK (0xF << 4) | ||
104 | #define SH_FSI_BPFMD_512 (1 << 4) | ||
105 | #define SH_FSI_BPFMD_256 (2 << 4) | ||
106 | #define SH_FSI_BPFMD_128 (3 << 4) | ||
107 | #define SH_FSI_BPFMD_64 (4 << 4) | ||
108 | #define SH_FSI_BPFMD_32 (5 << 4) | ||
109 | #define SH_FSI_BPFMD_16 (6 << 4) | ||
110 | |||
75 | struct sh_fsi_platform_info { | 111 | struct sh_fsi_platform_info { |
76 | unsigned long porta_flags; | 112 | unsigned long porta_flags; |
77 | unsigned long portb_flags; | 113 | unsigned long portb_flags; |
114 | int (*set_rate)(int is_porta, int rate); /* for master mode */ | ||
78 | }; | 115 | }; |
79 | 116 | ||
80 | extern struct snd_soc_dai fsi_soc_dai[2]; | 117 | extern struct snd_soc_dai fsi_soc_dai[2]; |
diff --git a/include/sound/soc-dapm.h b/include/sound/soc-dapm.h index 66ff4c124dbd..c5d9987bc897 100644 --- a/include/sound/soc-dapm.h +++ b/include/sound/soc-dapm.h | |||
@@ -273,6 +273,8 @@ | |||
273 | #define SND_SOC_DAPM_POST_PMD 0x8 /* after widget power down */ | 273 | #define SND_SOC_DAPM_POST_PMD 0x8 /* after widget power down */ |
274 | #define SND_SOC_DAPM_PRE_REG 0x10 /* before audio path setup */ | 274 | #define SND_SOC_DAPM_PRE_REG 0x10 /* before audio path setup */ |
275 | #define SND_SOC_DAPM_POST_REG 0x20 /* after audio path setup */ | 275 | #define SND_SOC_DAPM_POST_REG 0x20 /* after audio path setup */ |
276 | #define SND_SOC_DAPM_PRE_POST_PMD \ | ||
277 | (SND_SOC_DAPM_PRE_PMD | SND_SOC_DAPM_POST_PMD) | ||
276 | 278 | ||
277 | /* convenience event type detection */ | 279 | /* convenience event type detection */ |
278 | #define SND_SOC_DAPM_EVENT_ON(e) \ | 280 | #define SND_SOC_DAPM_EVENT_ON(e) \ |
diff --git a/include/sound/soc.h b/include/sound/soc.h index 697e7ffe39d7..65e9d03ed4f5 100644 --- a/include/sound/soc.h +++ b/include/sound/soc.h | |||
@@ -170,6 +170,21 @@ | |||
170 | .get = xhandler_get, .put = xhandler_put, \ | 170 | .get = xhandler_get, .put = xhandler_put, \ |
171 | .private_value = (unsigned long)&xenum } | 171 | .private_value = (unsigned long)&xenum } |
172 | 172 | ||
173 | #define SOC_DOUBLE_R_SX_TLV(xname, xreg_left, xreg_right, xshift,\ | ||
174 | xmin, xmax, tlv_array) \ | ||
175 | { .iface = SNDRV_CTL_ELEM_IFACE_MIXER, .name = (xname), \ | ||
176 | .access = SNDRV_CTL_ELEM_ACCESS_TLV_READ | \ | ||
177 | SNDRV_CTL_ELEM_ACCESS_READWRITE, \ | ||
178 | .tlv.p = (tlv_array), \ | ||
179 | .info = snd_soc_info_volsw_2r_sx, \ | ||
180 | .get = snd_soc_get_volsw_2r_sx, \ | ||
181 | .put = snd_soc_put_volsw_2r_sx, \ | ||
182 | .private_value = (unsigned long)&(struct soc_mixer_control) \ | ||
183 | {.reg = xreg_left, \ | ||
184 | .rreg = xreg_right, .shift = xshift, \ | ||
185 | .min = xmin, .max = xmax} } | ||
186 | |||
187 | |||
173 | /* | 188 | /* |
174 | * Simplified versions of above macros, declaring a struct and calculating | 189 | * Simplified versions of above macros, declaring a struct and calculating |
175 | * ARRAY_SIZE internally | 190 | * ARRAY_SIZE internally |
@@ -329,6 +344,12 @@ int snd_soc_put_volsw_s8(struct snd_kcontrol *kcontrol, | |||
329 | struct snd_ctl_elem_value *ucontrol); | 344 | struct snd_ctl_elem_value *ucontrol); |
330 | int snd_soc_limit_volume(struct snd_soc_codec *codec, | 345 | int snd_soc_limit_volume(struct snd_soc_codec *codec, |
331 | const char *name, int max); | 346 | const char *name, int max); |
347 | int snd_soc_info_volsw_2r_sx(struct snd_kcontrol *kcontrol, | ||
348 | struct snd_ctl_elem_info *uinfo); | ||
349 | int snd_soc_get_volsw_2r_sx(struct snd_kcontrol *kcontrol, | ||
350 | struct snd_ctl_elem_value *ucontrol); | ||
351 | int snd_soc_put_volsw_2r_sx(struct snd_kcontrol *kcontrol, | ||
352 | struct snd_ctl_elem_value *ucontrol); | ||
332 | 353 | ||
333 | /** | 354 | /** |
334 | * struct snd_soc_jack_pin - Describes a pin to update based on jack detection | 355 | * struct snd_soc_jack_pin - Describes a pin to update based on jack detection |
diff --git a/include/sound/tlv320dac33-plat.h b/include/sound/tlv320dac33-plat.h index 3f428d53195b..6c6649656798 100644 --- a/include/sound/tlv320dac33-plat.h +++ b/include/sound/tlv320dac33-plat.h | |||
@@ -15,6 +15,8 @@ | |||
15 | 15 | ||
16 | struct tlv320dac33_platform_data { | 16 | struct tlv320dac33_platform_data { |
17 | int power_gpio; | 17 | int power_gpio; |
18 | int mode1_latency; /* latency caused by the i2c writes in us */ | ||
19 | int auto_fifo_config; /* FIFO config based on the period size */ | ||
18 | int keep_bclk; /* Keep the BCLK running in FIFO modes */ | 20 | int keep_bclk; /* Keep the BCLK running in FIFO modes */ |
19 | u8 burst_bclkdiv; | 21 | u8 burst_bclkdiv; |
20 | }; | 22 | }; |
diff --git a/include/sound/uda134x.h b/include/sound/uda134x.h index 509efb050176..e475659bd3be 100644 --- a/include/sound/uda134x.h +++ b/include/sound/uda134x.h | |||
@@ -18,6 +18,18 @@ struct uda134x_platform_data { | |||
18 | struct l3_pins l3; | 18 | struct l3_pins l3; |
19 | void (*power) (int); | 19 | void (*power) (int); |
20 | int model; | 20 | int model; |
21 | /* | ||
22 | ALSA SOC usually puts the device in standby mode when it's not used | ||
23 | for sometime. If you unset is_powered_on_standby the driver will | ||
24 | turn off the ADC/DAC when this callback is invoked and turn it back | ||
25 | on when needed. Unfortunately this will result in a very light bump | ||
26 | (it can be audible only with good earphones). If this bothers you | ||
27 | set is_powered_on_standby, you will have slightly higher power | ||
28 | consumption. Please note that sending the L3 command for ADC is | ||
29 | enough to make the bump, so it doesn't make difference if you | ||
30 | completely take off power from the codec. | ||
31 | */ | ||
32 | int is_powered_on_standby; | ||
21 | #define UDA134X_UDA1340 1 | 33 | #define UDA134X_UDA1340 1 |
22 | #define UDA134X_UDA1341 2 | 34 | #define UDA134X_UDA1341 2 |
23 | #define UDA134X_UDA1344 3 | 35 | #define UDA134X_UDA1344 3 |