diff options
author | Ken Prox <kprox@users.sourceforge.net> | 2010-01-08 03:01:47 -0500 |
---|---|---|
committer | Jaroslav Kysela <perex@perex.cz> | 2010-01-08 03:07:50 -0500 |
commit | cd9d95a55550555da8e587ead9cbba5f98a371a3 (patch) | |
tree | bde2800eb82c91cf6437ac9328b4e4e00e5abc03 /sound/pci | |
parent | dd3533eca859a6debb1565503ec03e68354e08e0 (diff) |
ALSA: hda - conexant - Fixed microphone mixer for HP Compaq Presario F700
Added patch for Hewlett-Packard Company Device Subsystem id - 103c:30ea.
Signed-off-by: Ken Prox <kprox@users.sourceforge.net>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Diffstat (limited to 'sound/pci')
-rw-r--r-- | sound/pci/hda/patch_conexant.c | 50 |
1 files changed, 50 insertions, 0 deletions
diff --git a/sound/pci/hda/patch_conexant.c b/sound/pci/hda/patch_conexant.c index 1ab2958a290b..b20c640f7502 100644 --- a/sound/pci/hda/patch_conexant.c +++ b/sound/pci/hda/patch_conexant.c | |||
@@ -1720,6 +1720,22 @@ static struct snd_kcontrol_new cxt5051_hp_dv6736_mixers[] = { | |||
1720 | {} | 1720 | {} |
1721 | }; | 1721 | }; |
1722 | 1722 | ||
1723 | static struct snd_kcontrol_new cxt5051_f700_mixers[] = { | ||
1724 | HDA_CODEC_VOLUME("Mic Volume", 0x14, 0x01, HDA_INPUT), | ||
1725 | HDA_CODEC_MUTE("Mic Switch", 0x14, 0x01, HDA_INPUT), | ||
1726 | HDA_CODEC_VOLUME("Master Playback Volume", 0x10, 0x00, HDA_OUTPUT), | ||
1727 | { | ||
1728 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | ||
1729 | .name = "Master Playback Switch", | ||
1730 | .info = cxt_eapd_info, | ||
1731 | .get = cxt_eapd_get, | ||
1732 | .put = cxt5051_hp_master_sw_put, | ||
1733 | .private_value = 0x1a, | ||
1734 | }, | ||
1735 | |||
1736 | {} | ||
1737 | }; | ||
1738 | |||
1723 | static struct hda_verb cxt5051_init_verbs[] = { | 1739 | static struct hda_verb cxt5051_init_verbs[] = { |
1724 | /* Line in, Mic */ | 1740 | /* Line in, Mic */ |
1725 | {0x17, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0) | 0x03}, | 1741 | {0x17, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0) | 0x03}, |
@@ -1810,6 +1826,32 @@ static struct hda_verb cxt5051_lenovo_x200_init_verbs[] = { | |||
1810 | { } /* end */ | 1826 | { } /* end */ |
1811 | }; | 1827 | }; |
1812 | 1828 | ||
1829 | static struct hda_verb cxt5051_f700_init_verbs[] = { | ||
1830 | /* Line in, Mic */ | ||
1831 | {0x17, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(1) | 0x03}, | ||
1832 | {0x17, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_VREF80}, | ||
1833 | {0x18, AC_VERB_SET_PIN_WIDGET_CONTROL, 0x0}, | ||
1834 | {0x1d, AC_VERB_SET_PIN_WIDGET_CONTROL, 0x0}, | ||
1835 | /* SPK */ | ||
1836 | {0x1a, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT}, | ||
1837 | {0x1a, AC_VERB_SET_CONNECT_SEL, 0x00}, | ||
1838 | /* HP, Amp */ | ||
1839 | {0x16, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_HP}, | ||
1840 | {0x16, AC_VERB_SET_CONNECT_SEL, 0x00}, | ||
1841 | /* DAC1 */ | ||
1842 | {0x10, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_UNMUTE}, | ||
1843 | /* Record selector: Int mic */ | ||
1844 | {0x14, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(1) | 0x44}, | ||
1845 | {0x14, AC_VERB_SET_CONNECT_SEL, 0x1}, | ||
1846 | /* SPDIF route: PCM */ | ||
1847 | {0x1c, AC_VERB_SET_CONNECT_SEL, 0x0}, | ||
1848 | /* EAPD */ | ||
1849 | {0x1a, AC_VERB_SET_EAPD_BTLENABLE, 0x2}, /* default on */ | ||
1850 | {0x16, AC_VERB_SET_UNSOLICITED_ENABLE, AC_USRSP_EN|CONEXANT_HP_EVENT}, | ||
1851 | {0x17, AC_VERB_SET_UNSOLICITED_ENABLE, AC_USRSP_EN|CXT5051_PORTB_EVENT}, | ||
1852 | { } /* end */ | ||
1853 | }; | ||
1854 | |||
1813 | /* initialize jack-sensing, too */ | 1855 | /* initialize jack-sensing, too */ |
1814 | static int cxt5051_init(struct hda_codec *codec) | 1856 | static int cxt5051_init(struct hda_codec *codec) |
1815 | { | 1857 | { |
@@ -1829,6 +1871,7 @@ enum { | |||
1829 | CXT5051_HP, /* no docking */ | 1871 | CXT5051_HP, /* no docking */ |
1830 | CXT5051_HP_DV6736, /* HP without mic switch */ | 1872 | CXT5051_HP_DV6736, /* HP without mic switch */ |
1831 | CXT5051_LENOVO_X200, /* Lenovo X200 laptop */ | 1873 | CXT5051_LENOVO_X200, /* Lenovo X200 laptop */ |
1874 | CXT5051_F700, /* HP Compaq Presario F700 */ | ||
1832 | CXT5051_MODELS | 1875 | CXT5051_MODELS |
1833 | }; | 1876 | }; |
1834 | 1877 | ||
@@ -1837,6 +1880,7 @@ static const char *cxt5051_models[CXT5051_MODELS] = { | |||
1837 | [CXT5051_HP] = "hp", | 1880 | [CXT5051_HP] = "hp", |
1838 | [CXT5051_HP_DV6736] = "hp-dv6736", | 1881 | [CXT5051_HP_DV6736] = "hp-dv6736", |
1839 | [CXT5051_LENOVO_X200] = "lenovo-x200", | 1882 | [CXT5051_LENOVO_X200] = "lenovo-x200", |
1883 | [CXT5051_F700] = "hp 700" | ||
1840 | }; | 1884 | }; |
1841 | 1885 | ||
1842 | static struct snd_pci_quirk cxt5051_cfg_tbl[] = { | 1886 | static struct snd_pci_quirk cxt5051_cfg_tbl[] = { |
@@ -1846,6 +1890,7 @@ static struct snd_pci_quirk cxt5051_cfg_tbl[] = { | |||
1846 | CXT5051_LAPTOP), | 1890 | CXT5051_LAPTOP), |
1847 | SND_PCI_QUIRK(0x14f1, 0x5051, "HP Spartan 1.1", CXT5051_HP), | 1891 | SND_PCI_QUIRK(0x14f1, 0x5051, "HP Spartan 1.1", CXT5051_HP), |
1848 | SND_PCI_QUIRK(0x17aa, 0x20f2, "Lenovo X200", CXT5051_LENOVO_X200), | 1892 | SND_PCI_QUIRK(0x17aa, 0x20f2, "Lenovo X200", CXT5051_LENOVO_X200), |
1893 | SND_PCI_QUIRK(0x103c, 0x30ea, "Compaq Presario F700", CXT5051_F700), | ||
1849 | {} | 1894 | {} |
1850 | }; | 1895 | }; |
1851 | 1896 | ||
@@ -1896,6 +1941,11 @@ static int patch_cxt5051(struct hda_codec *codec) | |||
1896 | case CXT5051_LENOVO_X200: | 1941 | case CXT5051_LENOVO_X200: |
1897 | spec->init_verbs[0] = cxt5051_lenovo_x200_init_verbs; | 1942 | spec->init_verbs[0] = cxt5051_lenovo_x200_init_verbs; |
1898 | break; | 1943 | break; |
1944 | case CXT5051_F700: | ||
1945 | spec->init_verbs[0] = cxt5051_f700_init_verbs; | ||
1946 | spec->mixers[0] = cxt5051_f700_mixers; | ||
1947 | spec->no_auto_mic = 1; | ||
1948 | break; | ||
1899 | } | 1949 | } |
1900 | 1950 | ||
1901 | return 0; | 1951 | return 0; |