aboutsummaryrefslogtreecommitdiffstats
path: root/sound/soc/codecs
diff options
context:
space:
mode:
Diffstat (limited to 'sound/soc/codecs')
-rw-r--r--sound/soc/codecs/wm5102.c15
-rw-r--r--sound/soc/codecs/wm5110.c16
-rw-r--r--sound/soc/codecs/wm8350.c4
-rw-r--r--sound/soc/codecs/wm8960.c8
4 files changed, 27 insertions, 16 deletions
diff --git a/sound/soc/codecs/wm5102.c b/sound/soc/codecs/wm5102.c
index b8d461db369f..b82bbf584146 100644
--- a/sound/soc/codecs/wm5102.c
+++ b/sound/soc/codecs/wm5102.c
@@ -573,6 +573,13 @@ static const struct reg_default wm5102_sysclk_reva_patch[] = {
573 { 0x025e, 0x0112 }, 573 { 0x025e, 0x0112 },
574}; 574};
575 575
576static const struct reg_default wm5102_sysclk_revb_patch[] = {
577 { 0x3081, 0x08FE },
578 { 0x3083, 0x00ED },
579 { 0x30C1, 0x08FE },
580 { 0x30C3, 0x00ED },
581};
582
576static int wm5102_sysclk_ev(struct snd_soc_dapm_widget *w, 583static int wm5102_sysclk_ev(struct snd_soc_dapm_widget *w,
577 struct snd_kcontrol *kcontrol, int event) 584 struct snd_kcontrol *kcontrol, int event)
578{ 585{
@@ -587,6 +594,10 @@ static int wm5102_sysclk_ev(struct snd_soc_dapm_widget *w,
587 patch = wm5102_sysclk_reva_patch; 594 patch = wm5102_sysclk_reva_patch;
588 patch_size = ARRAY_SIZE(wm5102_sysclk_reva_patch); 595 patch_size = ARRAY_SIZE(wm5102_sysclk_reva_patch);
589 break; 596 break;
597 default:
598 patch = wm5102_sysclk_revb_patch;
599 patch_size = ARRAY_SIZE(wm5102_sysclk_revb_patch);
600 break;
590 } 601 }
591 602
592 switch (event) { 603 switch (event) {
@@ -755,7 +766,7 @@ SOC_SINGLE("SPKDAT1 High Performance Switch", ARIZONA_OUTPUT_PATH_CONFIG_5L,
755 766
756SOC_DOUBLE_R("HPOUT1 Digital Switch", ARIZONA_DAC_DIGITAL_VOLUME_1L, 767SOC_DOUBLE_R("HPOUT1 Digital Switch", ARIZONA_DAC_DIGITAL_VOLUME_1L,
757 ARIZONA_DAC_DIGITAL_VOLUME_1R, ARIZONA_OUT1L_MUTE_SHIFT, 1, 1), 768 ARIZONA_DAC_DIGITAL_VOLUME_1R, ARIZONA_OUT1L_MUTE_SHIFT, 1, 1),
758SOC_DOUBLE_R("OUT2 Digital Switch", ARIZONA_DAC_DIGITAL_VOLUME_2L, 769SOC_DOUBLE_R("HPOUT2 Digital Switch", ARIZONA_DAC_DIGITAL_VOLUME_2L,
759 ARIZONA_DAC_DIGITAL_VOLUME_2R, ARIZONA_OUT2L_MUTE_SHIFT, 1, 1), 770 ARIZONA_DAC_DIGITAL_VOLUME_2R, ARIZONA_OUT2L_MUTE_SHIFT, 1, 1),
760SOC_SINGLE("EPOUT Digital Switch", ARIZONA_DAC_DIGITAL_VOLUME_3L, 771SOC_SINGLE("EPOUT Digital Switch", ARIZONA_DAC_DIGITAL_VOLUME_3L,
761 ARIZONA_OUT3L_MUTE_SHIFT, 1, 1), 772 ARIZONA_OUT3L_MUTE_SHIFT, 1, 1),
@@ -767,7 +778,7 @@ SOC_DOUBLE_R("SPKDAT1 Digital Switch", ARIZONA_DAC_DIGITAL_VOLUME_5L,
767SOC_DOUBLE_R_TLV("HPOUT1 Digital Volume", ARIZONA_DAC_DIGITAL_VOLUME_1L, 778SOC_DOUBLE_R_TLV("HPOUT1 Digital Volume", ARIZONA_DAC_DIGITAL_VOLUME_1L,
768 ARIZONA_DAC_DIGITAL_VOLUME_1R, ARIZONA_OUT1L_VOL_SHIFT, 779 ARIZONA_DAC_DIGITAL_VOLUME_1R, ARIZONA_OUT1L_VOL_SHIFT,
769 0xbf, 0, digital_tlv), 780 0xbf, 0, digital_tlv),
770SOC_DOUBLE_R_TLV("OUT2 Digital Volume", ARIZONA_DAC_DIGITAL_VOLUME_2L, 781SOC_DOUBLE_R_TLV("HPOUT2 Digital Volume", ARIZONA_DAC_DIGITAL_VOLUME_2L,
771 ARIZONA_DAC_DIGITAL_VOLUME_2R, ARIZONA_OUT2L_VOL_SHIFT, 782 ARIZONA_DAC_DIGITAL_VOLUME_2R, ARIZONA_OUT2L_VOL_SHIFT,
772 0xbf, 0, digital_tlv), 783 0xbf, 0, digital_tlv),
773SOC_SINGLE_TLV("EPOUT Digital Volume", ARIZONA_DAC_DIGITAL_VOLUME_3L, 784SOC_SINGLE_TLV("EPOUT Digital Volume", ARIZONA_DAC_DIGITAL_VOLUME_3L,
diff --git a/sound/soc/codecs/wm5110.c b/sound/soc/codecs/wm5110.c
index cd17b477781d..cdeb301da1f6 100644
--- a/sound/soc/codecs/wm5110.c
+++ b/sound/soc/codecs/wm5110.c
@@ -213,9 +213,9 @@ ARIZONA_MIXER_CONTROLS("SPKDAT2R", ARIZONA_OUT6RMIX_INPUT_1_SOURCE),
213 213
214SOC_SINGLE("HPOUT1 High Performance Switch", ARIZONA_OUTPUT_PATH_CONFIG_1L, 214SOC_SINGLE("HPOUT1 High Performance Switch", ARIZONA_OUTPUT_PATH_CONFIG_1L,
215 ARIZONA_OUT1_OSR_SHIFT, 1, 0), 215 ARIZONA_OUT1_OSR_SHIFT, 1, 0),
216SOC_SINGLE("OUT2 High Performance Switch", ARIZONA_OUTPUT_PATH_CONFIG_2L, 216SOC_SINGLE("HPOUT2 High Performance Switch", ARIZONA_OUTPUT_PATH_CONFIG_2L,
217 ARIZONA_OUT2_OSR_SHIFT, 1, 0), 217 ARIZONA_OUT2_OSR_SHIFT, 1, 0),
218SOC_SINGLE("OUT3 High Performance Switch", ARIZONA_OUTPUT_PATH_CONFIG_3L, 218SOC_SINGLE("HPOUT3 High Performance Switch", ARIZONA_OUTPUT_PATH_CONFIG_3L,
219 ARIZONA_OUT3_OSR_SHIFT, 1, 0), 219 ARIZONA_OUT3_OSR_SHIFT, 1, 0),
220SOC_SINGLE("Speaker High Performance Switch", ARIZONA_OUTPUT_PATH_CONFIG_4L, 220SOC_SINGLE("Speaker High Performance Switch", ARIZONA_OUTPUT_PATH_CONFIG_4L,
221 ARIZONA_OUT4_OSR_SHIFT, 1, 0), 221 ARIZONA_OUT4_OSR_SHIFT, 1, 0),
@@ -226,9 +226,9 @@ SOC_SINGLE("SPKDAT2 High Performance Switch", ARIZONA_OUTPUT_PATH_CONFIG_6L,
226 226
227SOC_DOUBLE_R("HPOUT1 Digital Switch", ARIZONA_DAC_DIGITAL_VOLUME_1L, 227SOC_DOUBLE_R("HPOUT1 Digital Switch", ARIZONA_DAC_DIGITAL_VOLUME_1L,
228 ARIZONA_DAC_DIGITAL_VOLUME_1R, ARIZONA_OUT1L_MUTE_SHIFT, 1, 1), 228 ARIZONA_DAC_DIGITAL_VOLUME_1R, ARIZONA_OUT1L_MUTE_SHIFT, 1, 1),
229SOC_DOUBLE_R("OUT2 Digital Switch", ARIZONA_DAC_DIGITAL_VOLUME_2L, 229SOC_DOUBLE_R("HPOUT2 Digital Switch", ARIZONA_DAC_DIGITAL_VOLUME_2L,
230 ARIZONA_DAC_DIGITAL_VOLUME_2R, ARIZONA_OUT2L_MUTE_SHIFT, 1, 1), 230 ARIZONA_DAC_DIGITAL_VOLUME_2R, ARIZONA_OUT2L_MUTE_SHIFT, 1, 1),
231SOC_DOUBLE_R("OUT3 Digital Switch", ARIZONA_DAC_DIGITAL_VOLUME_3L, 231SOC_DOUBLE_R("HPOUT3 Digital Switch", ARIZONA_DAC_DIGITAL_VOLUME_3L,
232 ARIZONA_DAC_DIGITAL_VOLUME_3R, ARIZONA_OUT3L_MUTE_SHIFT, 1, 1), 232 ARIZONA_DAC_DIGITAL_VOLUME_3R, ARIZONA_OUT3L_MUTE_SHIFT, 1, 1),
233SOC_DOUBLE_R("Speaker Digital Switch", ARIZONA_DAC_DIGITAL_VOLUME_4L, 233SOC_DOUBLE_R("Speaker Digital Switch", ARIZONA_DAC_DIGITAL_VOLUME_4L,
234 ARIZONA_DAC_DIGITAL_VOLUME_4R, ARIZONA_OUT4L_MUTE_SHIFT, 1, 1), 234 ARIZONA_DAC_DIGITAL_VOLUME_4R, ARIZONA_OUT4L_MUTE_SHIFT, 1, 1),
@@ -240,10 +240,10 @@ SOC_DOUBLE_R("SPKDAT2 Digital Switch", ARIZONA_DAC_DIGITAL_VOLUME_6L,
240SOC_DOUBLE_R_TLV("HPOUT1 Digital Volume", ARIZONA_DAC_DIGITAL_VOLUME_1L, 240SOC_DOUBLE_R_TLV("HPOUT1 Digital Volume", ARIZONA_DAC_DIGITAL_VOLUME_1L,
241 ARIZONA_DAC_DIGITAL_VOLUME_1R, ARIZONA_OUT1L_VOL_SHIFT, 241 ARIZONA_DAC_DIGITAL_VOLUME_1R, ARIZONA_OUT1L_VOL_SHIFT,
242 0xbf, 0, digital_tlv), 242 0xbf, 0, digital_tlv),
243SOC_DOUBLE_R_TLV("OUT2 Digital Volume", ARIZONA_DAC_DIGITAL_VOLUME_2L, 243SOC_DOUBLE_R_TLV("HPOUT2 Digital Volume", ARIZONA_DAC_DIGITAL_VOLUME_2L,
244 ARIZONA_DAC_DIGITAL_VOLUME_2R, ARIZONA_OUT2L_VOL_SHIFT, 244 ARIZONA_DAC_DIGITAL_VOLUME_2R, ARIZONA_OUT2L_VOL_SHIFT,
245 0xbf, 0, digital_tlv), 245 0xbf, 0, digital_tlv),
246SOC_DOUBLE_R_TLV("OUT3 Digital Volume", ARIZONA_DAC_DIGITAL_VOLUME_3L, 246SOC_DOUBLE_R_TLV("HPOUT3 Digital Volume", ARIZONA_DAC_DIGITAL_VOLUME_3L,
247 ARIZONA_DAC_DIGITAL_VOLUME_3R, ARIZONA_OUT3L_VOL_SHIFT, 247 ARIZONA_DAC_DIGITAL_VOLUME_3R, ARIZONA_OUT3L_VOL_SHIFT,
248 0xbf, 0, digital_tlv), 248 0xbf, 0, digital_tlv),
249SOC_DOUBLE_R_TLV("Speaker Digital Volume", ARIZONA_DAC_DIGITAL_VOLUME_4L, 249SOC_DOUBLE_R_TLV("Speaker Digital Volume", ARIZONA_DAC_DIGITAL_VOLUME_4L,
@@ -260,11 +260,11 @@ SOC_DOUBLE_R_RANGE_TLV("HPOUT1 Volume", ARIZONA_OUTPUT_PATH_CONFIG_1L,
260 ARIZONA_OUTPUT_PATH_CONFIG_1R, 260 ARIZONA_OUTPUT_PATH_CONFIG_1R,
261 ARIZONA_OUT1L_PGA_VOL_SHIFT, 261 ARIZONA_OUT1L_PGA_VOL_SHIFT,
262 0x34, 0x40, 0, ana_tlv), 262 0x34, 0x40, 0, ana_tlv),
263SOC_DOUBLE_R_RANGE_TLV("OUT2 Volume", ARIZONA_OUTPUT_PATH_CONFIG_2L, 263SOC_DOUBLE_R_RANGE_TLV("HPOUT2 Volume", ARIZONA_OUTPUT_PATH_CONFIG_2L,
264 ARIZONA_OUTPUT_PATH_CONFIG_2R, 264 ARIZONA_OUTPUT_PATH_CONFIG_2R,
265 ARIZONA_OUT2L_PGA_VOL_SHIFT, 265 ARIZONA_OUT2L_PGA_VOL_SHIFT,
266 0x34, 0x40, 0, ana_tlv), 266 0x34, 0x40, 0, ana_tlv),
267SOC_DOUBLE_R_RANGE_TLV("OUT3 Volume", ARIZONA_OUTPUT_PATH_CONFIG_3L, 267SOC_DOUBLE_R_RANGE_TLV("HPOUT3 Volume", ARIZONA_OUTPUT_PATH_CONFIG_3L,
268 ARIZONA_OUTPUT_PATH_CONFIG_3R, 268 ARIZONA_OUTPUT_PATH_CONFIG_3R,
269 ARIZONA_OUT3L_PGA_VOL_SHIFT, 0x34, 0x40, 0, ana_tlv), 269 ARIZONA_OUT3L_PGA_VOL_SHIFT, 0x34, 0x40, 0, ana_tlv),
270 270
diff --git a/sound/soc/codecs/wm8350.c b/sound/soc/codecs/wm8350.c
index ec0efc1443ba..0e8b3aaf6c8d 100644
--- a/sound/soc/codecs/wm8350.c
+++ b/sound/soc/codecs/wm8350.c
@@ -1301,7 +1301,7 @@ static irqreturn_t wm8350_hpl_jack_handler(int irq, void *data)
1301 if (device_may_wakeup(wm8350->dev)) 1301 if (device_may_wakeup(wm8350->dev))
1302 pm_wakeup_event(wm8350->dev, 250); 1302 pm_wakeup_event(wm8350->dev, 250);
1303 1303
1304 schedule_delayed_work(&priv->hpl.work, 200); 1304 schedule_delayed_work(&priv->hpl.work, msecs_to_jiffies(200));
1305 1305
1306 return IRQ_HANDLED; 1306 return IRQ_HANDLED;
1307} 1307}
@@ -1318,7 +1318,7 @@ static irqreturn_t wm8350_hpr_jack_handler(int irq, void *data)
1318 if (device_may_wakeup(wm8350->dev)) 1318 if (device_may_wakeup(wm8350->dev))
1319 pm_wakeup_event(wm8350->dev, 250); 1319 pm_wakeup_event(wm8350->dev, 250);
1320 1320
1321 schedule_delayed_work(&priv->hpr.work, 200); 1321 schedule_delayed_work(&priv->hpr.work, msecs_to_jiffies(200));
1322 1322
1323 return IRQ_HANDLED; 1323 return IRQ_HANDLED;
1324} 1324}
diff --git a/sound/soc/codecs/wm8960.c b/sound/soc/codecs/wm8960.c
index 9bb927325993..a64b93425ae3 100644
--- a/sound/soc/codecs/wm8960.c
+++ b/sound/soc/codecs/wm8960.c
@@ -53,8 +53,8 @@
53 * using 2 wire for device control, so we cache them instead. 53 * using 2 wire for device control, so we cache them instead.
54 */ 54 */
55static const struct reg_default wm8960_reg_defaults[] = { 55static const struct reg_default wm8960_reg_defaults[] = {
56 { 0x0, 0x0097 }, 56 { 0x0, 0x00a7 },
57 { 0x1, 0x0097 }, 57 { 0x1, 0x00a7 },
58 { 0x2, 0x0000 }, 58 { 0x2, 0x0000 },
59 { 0x3, 0x0000 }, 59 { 0x3, 0x0000 },
60 { 0x4, 0x0000 }, 60 { 0x4, 0x0000 },
@@ -323,8 +323,8 @@ SND_SOC_DAPM_MIXER("Left Input Mixer", WM8960_POWER3, 5, 0,
323SND_SOC_DAPM_MIXER("Right Input Mixer", WM8960_POWER3, 4, 0, 323SND_SOC_DAPM_MIXER("Right Input Mixer", WM8960_POWER3, 4, 0,
324 wm8960_rin, ARRAY_SIZE(wm8960_rin)), 324 wm8960_rin, ARRAY_SIZE(wm8960_rin)),
325 325
326SND_SOC_DAPM_ADC("Left ADC", "Capture", WM8960_POWER2, 3, 0), 326SND_SOC_DAPM_ADC("Left ADC", "Capture", WM8960_POWER1, 3, 0),
327SND_SOC_DAPM_ADC("Right ADC", "Capture", WM8960_POWER2, 2, 0), 327SND_SOC_DAPM_ADC("Right ADC", "Capture", WM8960_POWER1, 2, 0),
328 328
329SND_SOC_DAPM_DAC("Left DAC", "Playback", WM8960_POWER2, 8, 0), 329SND_SOC_DAPM_DAC("Left DAC", "Playback", WM8960_POWER2, 8, 0),
330SND_SOC_DAPM_DAC("Right DAC", "Playback", WM8960_POWER2, 7, 0), 330SND_SOC_DAPM_DAC("Right DAC", "Playback", WM8960_POWER2, 7, 0),