diff options
author | Vitaliy Kulikov <Vitaliy.Kulikov@idt.com> | 2011-01-14 18:21:13 -0500 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2011-01-18 01:43:48 -0500 |
commit | cbbf50b22f9693218f9f0d460432266b04fc960d (patch) | |
tree | 0ca57d634ebe649b62483b5d4ecda21ba0672efc /sound/pci/hda | |
parent | 0f0714c5ed0a98fdeaa2287d3b159989bbe6d842 (diff) |
ALSA: hda - Fix initialization for HP 2011 notebooks
Fixes for HP 2011 notebooks: enable dock ports and disable BTL
initialization in the driver.
Signed-off-by: Vitaliy Kulikov <Vitaliy.Kulikov@idt.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci/hda')
-rw-r--r-- | sound/pci/hda/patch_sigmatel.c | 53 |
1 files changed, 10 insertions, 43 deletions
diff --git a/sound/pci/hda/patch_sigmatel.c b/sound/pci/hda/patch_sigmatel.c index 056f52df68cd..9ea48b425d0b 100644 --- a/sound/pci/hda/patch_sigmatel.c +++ b/sound/pci/hda/patch_sigmatel.c | |||
@@ -5333,7 +5333,7 @@ again: | |||
5333 | return 0; | 5333 | return 0; |
5334 | } | 5334 | } |
5335 | 5335 | ||
5336 | static int stac92hd83xxx_set_system_btl_amp(struct hda_codec *codec) | 5336 | static int hp_bnb2011_with_dock(struct hda_codec *codec) |
5337 | { | 5337 | { |
5338 | if (codec->vendor_id != 0x111d7605 && | 5338 | if (codec->vendor_id != 0x111d7605 && |
5339 | codec->vendor_id != 0x111d76d1) | 5339 | codec->vendor_id != 0x111d76d1) |
@@ -5348,10 +5348,6 @@ static int stac92hd83xxx_set_system_btl_amp(struct hda_codec *codec) | |||
5348 | case 0x103c161d: | 5348 | case 0x103c161d: |
5349 | case 0x103c161e: | 5349 | case 0x103c161e: |
5350 | case 0x103c161f: | 5350 | case 0x103c161f: |
5351 | case 0x103c1620: | ||
5352 | case 0x103c1621: | ||
5353 | case 0x103c1622: | ||
5354 | case 0x103c1623: | ||
5355 | 5351 | ||
5356 | case 0x103c162a: | 5352 | case 0x103c162a: |
5357 | case 0x103c162b: | 5353 | case 0x103c162b: |
@@ -5360,41 +5356,9 @@ static int stac92hd83xxx_set_system_btl_amp(struct hda_codec *codec) | |||
5360 | case 0x103c1631: | 5356 | case 0x103c1631: |
5361 | 5357 | ||
5362 | case 0x103c1633: | 5358 | case 0x103c1633: |
5363 | 5359 | case 0x103c1634: | |
5364 | case 0x103c1635: | 5360 | case 0x103c1635: |
5365 | 5361 | ||
5366 | case 0x103c164f: | ||
5367 | |||
5368 | case 0x103c1676: | ||
5369 | case 0x103c1677: | ||
5370 | case 0x103c1678: | ||
5371 | case 0x103c1679: | ||
5372 | case 0x103c167a: | ||
5373 | case 0x103c167b: | ||
5374 | case 0x103c167c: | ||
5375 | case 0x103c167d: | ||
5376 | case 0x103c167e: | ||
5377 | case 0x103c167f: | ||
5378 | case 0x103c1680: | ||
5379 | case 0x103c1681: | ||
5380 | case 0x103c1682: | ||
5381 | case 0x103c1683: | ||
5382 | case 0x103c1684: | ||
5383 | case 0x103c1685: | ||
5384 | case 0x103c1686: | ||
5385 | case 0x103c1687: | ||
5386 | case 0x103c1688: | ||
5387 | case 0x103c1689: | ||
5388 | case 0x103c168a: | ||
5389 | case 0x103c168b: | ||
5390 | case 0x103c168c: | ||
5391 | case 0x103c168d: | ||
5392 | case 0x103c168e: | ||
5393 | case 0x103c168f: | ||
5394 | case 0x103c1690: | ||
5395 | case 0x103c1691: | ||
5396 | case 0x103c1692: | ||
5397 | |||
5398 | case 0x103c3587: | 5362 | case 0x103c3587: |
5399 | case 0x103c3588: | 5363 | case 0x103c3588: |
5400 | case 0x103c3589: | 5364 | case 0x103c3589: |
@@ -5402,9 +5366,9 @@ static int stac92hd83xxx_set_system_btl_amp(struct hda_codec *codec) | |||
5402 | 5366 | ||
5403 | case 0x103c3667: | 5367 | case 0x103c3667: |
5404 | case 0x103c3668: | 5368 | case 0x103c3668: |
5405 | /* set BTL amp level to 13.43dB for louder speaker output */ | 5369 | case 0x103c3669: |
5406 | return snd_hda_codec_write_cache(codec, codec->afg, 0, | 5370 | |
5407 | 0x7F4, 0x14); | 5371 | return 1; |
5408 | } | 5372 | } |
5409 | return 0; | 5373 | return 0; |
5410 | } | 5374 | } |
@@ -5420,6 +5384,11 @@ static int patch_stac92hd83xxx(struct hda_codec *codec) | |||
5420 | if (spec == NULL) | 5384 | if (spec == NULL) |
5421 | return -ENOMEM; | 5385 | return -ENOMEM; |
5422 | 5386 | ||
5387 | if (hp_bnb2011_with_dock(codec)) { | ||
5388 | snd_hda_codec_set_pincfg(codec, 0xa, 0x2101201f); | ||
5389 | snd_hda_codec_set_pincfg(codec, 0xf, 0x2181205e); | ||
5390 | } | ||
5391 | |||
5423 | /* reset pin power-down; Windows may leave these bits after reboot */ | 5392 | /* reset pin power-down; Windows may leave these bits after reboot */ |
5424 | snd_hda_codec_write_cache(codec, codec->afg, 0, 0x7EC, 0); | 5393 | snd_hda_codec_write_cache(codec, codec->afg, 0, 0x7EC, 0); |
5425 | snd_hda_codec_write_cache(codec, codec->afg, 0, 0x7ED, 0); | 5394 | snd_hda_codec_write_cache(codec, codec->afg, 0, 0x7ED, 0); |
@@ -5546,8 +5515,6 @@ again: | |||
5546 | AC_VERB_SET_CONNECT_SEL, num_dacs); | 5515 | AC_VERB_SET_CONNECT_SEL, num_dacs); |
5547 | } | 5516 | } |
5548 | 5517 | ||
5549 | stac92hd83xxx_set_system_btl_amp(codec); | ||
5550 | |||
5551 | codec->proc_widget_hook = stac92hd_proc_hook; | 5518 | codec->proc_widget_hook = stac92hd_proc_hook; |
5552 | 5519 | ||
5553 | return 0; | 5520 | return 0; |