Commit ad889794 authored by Takashi Iwai's avatar Takashi Iwai Committed by Luis Henriques

ALSA: hda - Set up GPIO for Toshiba Satellite S50D

commit 4227de2a upstream.

Toshiba Satellite S50D laptop with an IDT codec uses the GPIO4 (0x10)
as the master EAPD.

Bugzilla: https://bugzilla.novell.com/show_bug.cgi?id=915858Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
Signed-off-by: default avatarLuis Henriques <luis.henriques@canonical.com>
parent a4ab0d80
...@@ -105,6 +105,7 @@ enum { ...@@ -105,6 +105,7 @@ enum {
STAC_HP_ENVY_BASS, STAC_HP_ENVY_BASS,
STAC_HP_BNB13_EQ, STAC_HP_BNB13_EQ,
STAC_HP_ENVY_TS_BASS, STAC_HP_ENVY_TS_BASS,
STAC_92HD83XXX_GPIO10_EAPD,
STAC_92HD83XXX_MODELS STAC_92HD83XXX_MODELS
}; };
...@@ -2173,6 +2174,19 @@ static void stac92hd83xxx_fixup_headset_jack(struct hda_codec *codec, ...@@ -2173,6 +2174,19 @@ static void stac92hd83xxx_fixup_headset_jack(struct hda_codec *codec,
spec->headset_jack = 1; spec->headset_jack = 1;
} }
static void stac92hd83xxx_fixup_gpio10_eapd(struct hda_codec *codec,
const struct hda_fixup *fix,
int action)
{
struct sigmatel_spec *spec = codec->spec;
if (action != HDA_FIXUP_ACT_PRE_PROBE)
return;
spec->eapd_mask = spec->gpio_mask = spec->gpio_dir =
spec->gpio_data = 0x10;
spec->eapd_switch = 0;
}
static const struct hda_verb hp_bnb13_eq_verbs[] = { static const struct hda_verb hp_bnb13_eq_verbs[] = {
/* 44.1KHz base */ /* 44.1KHz base */
{ 0x22, 0x7A6, 0x3E }, { 0x22, 0x7A6, 0x3E },
...@@ -2688,6 +2702,10 @@ static const struct hda_fixup stac92hd83xxx_fixups[] = { ...@@ -2688,6 +2702,10 @@ static const struct hda_fixup stac92hd83xxx_fixups[] = {
{} {}
}, },
}, },
[STAC_92HD83XXX_GPIO10_EAPD] = {
.type = HDA_FIXUP_FUNC,
.v.func = stac92hd83xxx_fixup_gpio10_eapd,
},
}; };
static const struct hda_model_fixup stac92hd83xxx_models[] = { static const struct hda_model_fixup stac92hd83xxx_models[] = {
...@@ -2893,6 +2911,8 @@ static const struct snd_pci_quirk stac92hd83xxx_fixup_tbl[] = { ...@@ -2893,6 +2911,8 @@ static const struct snd_pci_quirk stac92hd83xxx_fixup_tbl[] = {
SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x148a, SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x148a,
"HP Mini", STAC_92HD83XXX_HP_LED), "HP Mini", STAC_92HD83XXX_HP_LED),
SND_PCI_QUIRK_VENDOR(PCI_VENDOR_ID_HP, "HP", STAC_92HD83XXX_HP), SND_PCI_QUIRK_VENDOR(PCI_VENDOR_ID_HP, "HP", STAC_92HD83XXX_HP),
SND_PCI_QUIRK(PCI_VENDOR_ID_TOSHIBA, 0xfa91,
"Toshiba Satellite S50D", STAC_92HD83XXX_GPIO10_EAPD),
{} /* terminator */ {} /* terminator */
}; };
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment