diff options
Diffstat (limited to 'sound/soc/codecs/wm8990.c')
-rw-r--r-- | sound/soc/codecs/wm8990.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/sound/soc/codecs/wm8990.c b/sound/soc/codecs/wm8990.c index 8a584229310a..c93bffcb3cfb 100644 --- a/sound/soc/codecs/wm8990.c +++ b/sound/soc/codecs/wm8990.c | |||
@@ -374,13 +374,14 @@ SOC_SINGLE("RIN34 Mute Switch", WM8990_RIGHT_LINE_INPUT_3_4_VOLUME, | |||
374 | static int outmixer_event(struct snd_soc_dapm_widget *w, | 374 | static int outmixer_event(struct snd_soc_dapm_widget *w, |
375 | struct snd_kcontrol *kcontrol, int event) | 375 | struct snd_kcontrol *kcontrol, int event) |
376 | { | 376 | { |
377 | struct snd_soc_codec *codec = snd_soc_dapm_to_codec(w->dapm); | ||
377 | u32 reg_shift = kcontrol->private_value & 0xfff; | 378 | u32 reg_shift = kcontrol->private_value & 0xfff; |
378 | int ret = 0; | 379 | int ret = 0; |
379 | u16 reg; | 380 | u16 reg; |
380 | 381 | ||
381 | switch (reg_shift) { | 382 | switch (reg_shift) { |
382 | case WM8990_SPEAKER_MIXER | (WM8990_LDSPK_BIT << 8) : | 383 | case WM8990_SPEAKER_MIXER | (WM8990_LDSPK_BIT << 8) : |
383 | reg = snd_soc_read(w->codec, WM8990_OUTPUT_MIXER1); | 384 | reg = snd_soc_read(codec, WM8990_OUTPUT_MIXER1); |
384 | if (reg & WM8990_LDLO) { | 385 | if (reg & WM8990_LDLO) { |
385 | printk(KERN_WARNING | 386 | printk(KERN_WARNING |
386 | "Cannot set as Output Mixer 1 LDLO Set\n"); | 387 | "Cannot set as Output Mixer 1 LDLO Set\n"); |
@@ -388,7 +389,7 @@ static int outmixer_event(struct snd_soc_dapm_widget *w, | |||
388 | } | 389 | } |
389 | break; | 390 | break; |
390 | case WM8990_SPEAKER_MIXER | (WM8990_RDSPK_BIT << 8): | 391 | case WM8990_SPEAKER_MIXER | (WM8990_RDSPK_BIT << 8): |
391 | reg = snd_soc_read(w->codec, WM8990_OUTPUT_MIXER2); | 392 | reg = snd_soc_read(codec, WM8990_OUTPUT_MIXER2); |
392 | if (reg & WM8990_RDRO) { | 393 | if (reg & WM8990_RDRO) { |
393 | printk(KERN_WARNING | 394 | printk(KERN_WARNING |
394 | "Cannot set as Output Mixer 2 RDRO Set\n"); | 395 | "Cannot set as Output Mixer 2 RDRO Set\n"); |
@@ -396,7 +397,7 @@ static int outmixer_event(struct snd_soc_dapm_widget *w, | |||
396 | } | 397 | } |
397 | break; | 398 | break; |
398 | case WM8990_OUTPUT_MIXER1 | (WM8990_LDLO_BIT << 8): | 399 | case WM8990_OUTPUT_MIXER1 | (WM8990_LDLO_BIT << 8): |
399 | reg = snd_soc_read(w->codec, WM8990_SPEAKER_MIXER); | 400 | reg = snd_soc_read(codec, WM8990_SPEAKER_MIXER); |
400 | if (reg & WM8990_LDSPK) { | 401 | if (reg & WM8990_LDSPK) { |
401 | printk(KERN_WARNING | 402 | printk(KERN_WARNING |
402 | "Cannot set as Speaker Mixer LDSPK Set\n"); | 403 | "Cannot set as Speaker Mixer LDSPK Set\n"); |
@@ -404,7 +405,7 @@ static int outmixer_event(struct snd_soc_dapm_widget *w, | |||
404 | } | 405 | } |
405 | break; | 406 | break; |
406 | case WM8990_OUTPUT_MIXER2 | (WM8990_RDRO_BIT << 8): | 407 | case WM8990_OUTPUT_MIXER2 | (WM8990_RDRO_BIT << 8): |
407 | reg = snd_soc_read(w->codec, WM8990_SPEAKER_MIXER); | 408 | reg = snd_soc_read(codec, WM8990_SPEAKER_MIXER); |
408 | if (reg & WM8990_RDSPK) { | 409 | if (reg & WM8990_RDSPK) { |
409 | printk(KERN_WARNING | 410 | printk(KERN_WARNING |
410 | "Cannot set as Speaker Mixer RDSPK Set\n"); | 411 | "Cannot set as Speaker Mixer RDSPK Set\n"); |