* Enable headset Mic for Dell DT
@ 2014-03-03 7:42 Kailang
2014-03-03 8:59 ` Takashi Iwai
0 siblings, 1 reply; 4+ messages in thread
From: Kailang @ 2014-03-03 7:42 UTC (permalink / raw)
To: Kailang, Takashi Iwai; +Cc: alsa-devel
Hi Takashi,
I created patch below for Dell DT for support headset MIC.
Many Thanks.
Kailang.
>From 2f448d6f9ad7023befa91b80f86cb267311d3f8a Mon Sep 17 00:00:00 2001
From: Kailang Yang <kailang@realtek.com>
Date: Mon, 3 Mar 2014 15:27:22 +0800
Subject: [PATCH] ALSA: hda/realtek - Add headset quirk for Dell DT
This quirk is needed for the headset microphone to work.
Signed-off-by: Kailang Yang <kailang@realtek.com>
diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c
index 534796e..74456bd 100644
--- a/sound/pci/hda/patch_realtek.c
+++ b/sound/pci/hda/patch_realtek.c
@@ -3594,21 +3594,38 @@ static void alc_fixup_headset_mode_no_hp_mic(struct
hda_codec *codec,
alc_fixup_headset_mode(codec, fix, action);
}
+static void alc255_set_default_jack_type(struct hda_codec *codec)
+{
+ /* Set to iphone type */
+ alc_write_coef_idx(codec, 0x1b, 0x880b);
+ alc_write_coef_idx(codec, 0x45, 0xd089);
+ alc_write_coef_idx(codec, 0x1b, 0x080b);
+ alc_write_coef_idx(codec, 0x46, 0x0004);
+ alc_write_coef_idx(codec, 0x1b, 0x0c0b);
+ msleep(30);
+}
+
static void alc_fixup_headset_mode_alc255(struct hda_codec *codec,
const struct hda_fixup *fix, int action)
{
if (action == HDA_FIXUP_ACT_PRE_PROBE) {
- /* Set to iphone type */
- alc_write_coef_idx(codec, 0x1b, 0x880b);
- alc_write_coef_idx(codec, 0x45, 0xd089);
- alc_write_coef_idx(codec, 0x1b, 0x080b);
- alc_write_coef_idx(codec, 0x46, 0x0004);
- alc_write_coef_idx(codec, 0x1b, 0x0c0b);
- msleep(30);
+ alc255_set_default_jack_type(codec);
}
alc_fixup_headset_mode(codec, fix, action);
}
+static void alc_fixup_headset_mode_alc255_no_hp_mic(struct hda_codec
*codec,
+ const struct hda_fixup *fix, int action)
+{
+ if (action == HDA_FIXUP_ACT_PRE_PROBE) {
+ struct alc_spec *spec = codec->spec;
+ spec->parse_flags |= HDA_PINCFG_HEADSET_MIC;
+ alc255_set_default_jack_type(codec);
+ }
+ else
+ alc_fixup_headset_mode(codec, fix, action);
+}
+
static void alc_fixup_auto_mute_via_amp(struct hda_codec *codec,
const struct hda_fixup *fix, int action)
{
@@ -3875,7 +3892,9 @@ enum {
ALC290_FIXUP_SUBWOOFER_HSJACK,
ALC269_FIXUP_THINKPAD_ACPI,
ALC255_FIXUP_DELL1_MIC_NO_PRESENCE,
+ ALC255_FIXUP_DELL2_MIC_NO_PRESENCE,
ALC255_FIXUP_HEADSET_MODE,
+ ALC255_FIXUP_HEADSET_MODE_NO_HP_MIC,
};
static const struct hda_fixup alc269_fixups[] = {
@@ -4248,10 +4267,23 @@ static const struct hda_fixup alc269_fixups[] = {
.chained = true,
.chain_id = ALC255_FIXUP_HEADSET_MODE
},
+ [ALC255_FIXUP_DELL2_MIC_NO_PRESENCE] = {
+ .type = HDA_FIXUP_PINS,
+ .v.pins = (const struct hda_pintbl[]) {
+ { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect
*/
+ { }
+ },
+ .chained = true,
+ .chain_id = ALC255_FIXUP_HEADSET_MODE_NO_HP_MIC
+ },
[ALC255_FIXUP_HEADSET_MODE] = {
.type = HDA_FIXUP_FUNC,
.v.func = alc_fixup_headset_mode_alc255,
},
+ [ALC255_FIXUP_HEADSET_MODE_NO_HP_MIC] = {
+ .type = HDA_FIXUP_FUNC,
+ .v.func = alc_fixup_headset_mode_alc255_no_hp_mic,
+ },
};
static const struct snd_pci_quirk alc269_fixup_tbl[] = {
@@ -4314,6 +4346,8 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] =
{
SND_PCI_QUIRK(0x1028, 0x0658, "Dell", ALC269_FIXUP_DELL1_MIC_NO_PRESENCE),
SND_PCI_QUIRK(0x1028, 0x065f, "Dell", ALC255_FIXUP_DELL1_MIC_NO_PRESENCE),
SND_PCI_QUIRK(0x1028, 0x0662, "Dell", ALC255_FIXUP_DELL1_MIC_NO_PRESENCE),
+ SND_PCI_QUIRK(0x1028, 0x0668, "Dell", ALC255_FIXUP_DELL2_MIC_NO_PRESENCE),
+ SND_PCI_QUIRK(0x1028, 0x0669, "Dell", ALC255_FIXUP_DELL2_MIC_NO_PRESENCE),
SND_PCI_QUIRK(0x1028, 0x15cc, "Dell X5 Precision",
ALC269_FIXUP_DELL2_MIC_NO_PRESENCE),
SND_PCI_QUIRK(0x1028, 0x15cd, "Dell X5 Precision",
ALC269_FIXUP_DELL2_MIC_NO_PRESENCE),
SND_PCI_QUIRK(0x103c, 0x1586, "HP", ALC269_FIXUP_HP_MUTE_LED_MIC2),
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: Enable headset Mic for Dell DT
2014-03-03 7:42 Enable headset Mic for Dell DT Kailang
@ 2014-03-03 8:59 ` Takashi Iwai
2014-03-03 9:09 ` Kailang
0 siblings, 1 reply; 4+ messages in thread
From: Takashi Iwai @ 2014-03-03 8:59 UTC (permalink / raw)
To: Kailang; +Cc: alsa-devel
At Mon, 3 Mar 2014 15:42:42 +0800,
Kailang wrote:
>
> Hi Takashi,
>
> I created patch below for Dell DT for support headset MIC.
> Many Thanks.
The changes look good, but the patch can't be applied cleanly because
your mailer broke spaces. Please fix MUA, or just use an attachment
in addition.
thanks,
Takashi
>
> Kailang.
>
>
> >From 2f448d6f9ad7023befa91b80f86cb267311d3f8a Mon Sep 17 00:00:00 2001
> From: Kailang Yang <kailang@realtek.com>
> Date: Mon, 3 Mar 2014 15:27:22 +0800
> Subject: [PATCH] ALSA: hda/realtek - Add headset quirk for Dell DT
>
> This quirk is needed for the headset microphone to work.
>
> Signed-off-by: Kailang Yang <kailang@realtek.com>
>
> diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c
> index 534796e..74456bd 100644
> --- a/sound/pci/hda/patch_realtek.c
> +++ b/sound/pci/hda/patch_realtek.c
> @@ -3594,21 +3594,38 @@ static void alc_fixup_headset_mode_no_hp_mic(struct
> hda_codec *codec,
> alc_fixup_headset_mode(codec, fix, action);
> }
>
> +static void alc255_set_default_jack_type(struct hda_codec *codec)
> +{
> + /* Set to iphone type */
> + alc_write_coef_idx(codec, 0x1b, 0x880b);
> + alc_write_coef_idx(codec, 0x45, 0xd089);
> + alc_write_coef_idx(codec, 0x1b, 0x080b);
> + alc_write_coef_idx(codec, 0x46, 0x0004);
> + alc_write_coef_idx(codec, 0x1b, 0x0c0b);
> + msleep(30);
> +}
> +
> static void alc_fixup_headset_mode_alc255(struct hda_codec *codec,
> const struct hda_fixup *fix, int action)
> {
> if (action == HDA_FIXUP_ACT_PRE_PROBE) {
> - /* Set to iphone type */
> - alc_write_coef_idx(codec, 0x1b, 0x880b);
> - alc_write_coef_idx(codec, 0x45, 0xd089);
> - alc_write_coef_idx(codec, 0x1b, 0x080b);
> - alc_write_coef_idx(codec, 0x46, 0x0004);
> - alc_write_coef_idx(codec, 0x1b, 0x0c0b);
> - msleep(30);
> + alc255_set_default_jack_type(codec);
> }
> alc_fixup_headset_mode(codec, fix, action);
> }
>
> +static void alc_fixup_headset_mode_alc255_no_hp_mic(struct hda_codec
> *codec,
> + const struct hda_fixup *fix, int action)
> +{
> + if (action == HDA_FIXUP_ACT_PRE_PROBE) {
> + struct alc_spec *spec = codec->spec;
> + spec->parse_flags |= HDA_PINCFG_HEADSET_MIC;
> + alc255_set_default_jack_type(codec);
> + }
> + else
> + alc_fixup_headset_mode(codec, fix, action);
> +}
> +
> static void alc_fixup_auto_mute_via_amp(struct hda_codec *codec,
> const struct hda_fixup *fix, int action)
> {
> @@ -3875,7 +3892,9 @@ enum {
> ALC290_FIXUP_SUBWOOFER_HSJACK,
> ALC269_FIXUP_THINKPAD_ACPI,
> ALC255_FIXUP_DELL1_MIC_NO_PRESENCE,
> + ALC255_FIXUP_DELL2_MIC_NO_PRESENCE,
> ALC255_FIXUP_HEADSET_MODE,
> + ALC255_FIXUP_HEADSET_MODE_NO_HP_MIC,
> };
>
> static const struct hda_fixup alc269_fixups[] = {
> @@ -4248,10 +4267,23 @@ static const struct hda_fixup alc269_fixups[] = {
> .chained = true,
> .chain_id = ALC255_FIXUP_HEADSET_MODE
> },
> + [ALC255_FIXUP_DELL2_MIC_NO_PRESENCE] = {
> + .type = HDA_FIXUP_PINS,
> + .v.pins = (const struct hda_pintbl[]) {
> + { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect
> */
> + { }
> + },
> + .chained = true,
> + .chain_id = ALC255_FIXUP_HEADSET_MODE_NO_HP_MIC
> + },
> [ALC255_FIXUP_HEADSET_MODE] = {
> .type = HDA_FIXUP_FUNC,
> .v.func = alc_fixup_headset_mode_alc255,
> },
> + [ALC255_FIXUP_HEADSET_MODE_NO_HP_MIC] = {
> + .type = HDA_FIXUP_FUNC,
> + .v.func = alc_fixup_headset_mode_alc255_no_hp_mic,
> + },
> };
>
> static const struct snd_pci_quirk alc269_fixup_tbl[] = {
> @@ -4314,6 +4346,8 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] =
> {
> SND_PCI_QUIRK(0x1028, 0x0658, "Dell", ALC269_FIXUP_DELL1_MIC_NO_PRESENCE),
> SND_PCI_QUIRK(0x1028, 0x065f, "Dell", ALC255_FIXUP_DELL1_MIC_NO_PRESENCE),
> SND_PCI_QUIRK(0x1028, 0x0662, "Dell", ALC255_FIXUP_DELL1_MIC_NO_PRESENCE),
> + SND_PCI_QUIRK(0x1028, 0x0668, "Dell", ALC255_FIXUP_DELL2_MIC_NO_PRESENCE),
> + SND_PCI_QUIRK(0x1028, 0x0669, "Dell", ALC255_FIXUP_DELL2_MIC_NO_PRESENCE),
> SND_PCI_QUIRK(0x1028, 0x15cc, "Dell X5 Precision",
> ALC269_FIXUP_DELL2_MIC_NO_PRESENCE),
> SND_PCI_QUIRK(0x1028, 0x15cd, "Dell X5 Precision",
> ALC269_FIXUP_DELL2_MIC_NO_PRESENCE),
> SND_PCI_QUIRK(0x103c, 0x1586, "HP", ALC269_FIXUP_HP_MUTE_LED_MIC2),
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Enable headset Mic for Dell DT
2014-03-03 8:59 ` Takashi Iwai
@ 2014-03-03 9:09 ` Kailang
2014-03-03 9:49 ` Takashi Iwai
0 siblings, 1 reply; 4+ messages in thread
From: Kailang @ 2014-03-03 9:09 UTC (permalink / raw)
To: Takashi Iwai; +Cc: alsa-devel
[-- Attachment #1: Type: text/plain, Size: 4552 bytes --]
Hi Takashi,
Please see attachment.
Thanks.
Kailang
> At Mon, 3 Mar 2014 15:42:42 +0800,
> Kailang wrote:
>>
>> Hi Takashi,
>>
>> I created patch below for Dell DT for support headset MIC.
>> Many Thanks.
>
> The changes look good, but the patch can't be applied cleanly because
> your mailer broke spaces. Please fix MUA, or just use an attachment
> in addition.
>
>
> thanks,
>
> Takashi
>
>>
>> Kailang.
>>
>>
>> >From 2f448d6f9ad7023befa91b80f86cb267311d3f8a Mon Sep 17 00:00:00 2001
>> From: Kailang Yang <kailang@realtek.com>
>> Date: Mon, 3 Mar 2014 15:27:22 +0800
>> Subject: [PATCH] ALSA: hda/realtek - Add headset quirk for Dell DT
>>
>> This quirk is needed for the headset microphone to work.
>>
>> Signed-off-by: Kailang Yang <kailang@realtek.com>
>>
>> diff --git a/sound/pci/hda/patch_realtek.c
>> b/sound/pci/hda/patch_realtek.c
>> index 534796e..74456bd 100644
>> --- a/sound/pci/hda/patch_realtek.c
>> +++ b/sound/pci/hda/patch_realtek.c
>> @@ -3594,21 +3594,38 @@ static void
>> alc_fixup_headset_mode_no_hp_mic(struct
>> hda_codec *codec,
>> alc_fixup_headset_mode(codec, fix, action);
>> }
>>
>> +static void alc255_set_default_jack_type(struct hda_codec *codec)
>> +{
>> + /* Set to iphone type */
>> + alc_write_coef_idx(codec, 0x1b, 0x880b);
>> + alc_write_coef_idx(codec, 0x45, 0xd089);
>> + alc_write_coef_idx(codec, 0x1b, 0x080b);
>> + alc_write_coef_idx(codec, 0x46, 0x0004);
>> + alc_write_coef_idx(codec, 0x1b, 0x0c0b);
>> + msleep(30);
>> +}
>> +
>> static void alc_fixup_headset_mode_alc255(struct hda_codec *codec,
>> const struct hda_fixup *fix, int action)
>> {
>> if (action == HDA_FIXUP_ACT_PRE_PROBE) {
>> - /* Set to iphone type */
>> - alc_write_coef_idx(codec, 0x1b, 0x880b);
>> - alc_write_coef_idx(codec, 0x45, 0xd089);
>> - alc_write_coef_idx(codec, 0x1b, 0x080b);
>> - alc_write_coef_idx(codec, 0x46, 0x0004);
>> - alc_write_coef_idx(codec, 0x1b, 0x0c0b);
>> - msleep(30);
>> + alc255_set_default_jack_type(codec);
>> }
>> alc_fixup_headset_mode(codec, fix, action);
>> }
>>
>> +static void alc_fixup_headset_mode_alc255_no_hp_mic(struct hda_codec
>> *codec,
>> + const struct hda_fixup *fix, int action)
>> +{
>> + if (action == HDA_FIXUP_ACT_PRE_PROBE) {
>> + struct alc_spec *spec = codec->spec;
>> + spec->parse_flags |= HDA_PINCFG_HEADSET_MIC;
>> + alc255_set_default_jack_type(codec);
>> + }
>> + else
>> + alc_fixup_headset_mode(codec, fix, action);
>> +}
>> +
>> static void alc_fixup_auto_mute_via_amp(struct hda_codec *codec,
>> const struct hda_fixup *fix, int action)
>> {
>> @@ -3875,7 +3892,9 @@ enum {
>> ALC290_FIXUP_SUBWOOFER_HSJACK,
>> ALC269_FIXUP_THINKPAD_ACPI,
>> ALC255_FIXUP_DELL1_MIC_NO_PRESENCE,
>> + ALC255_FIXUP_DELL2_MIC_NO_PRESENCE,
>> ALC255_FIXUP_HEADSET_MODE,
>> + ALC255_FIXUP_HEADSET_MODE_NO_HP_MIC,
>> };
>>
>> static const struct hda_fixup alc269_fixups[] = {
>> @@ -4248,10 +4267,23 @@ static const struct hda_fixup alc269_fixups[] = {
>> .chained = true,
>> .chain_id = ALC255_FIXUP_HEADSET_MODE
>> },
>> + [ALC255_FIXUP_DELL2_MIC_NO_PRESENCE] = {
>> + .type = HDA_FIXUP_PINS,
>> + .v.pins = (const struct hda_pintbl[]) {
>> + { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack
>> detect
>> */
>> + { }
>> + },
>> + .chained = true,
>> + .chain_id = ALC255_FIXUP_HEADSET_MODE_NO_HP_MIC
>> + },
>> [ALC255_FIXUP_HEADSET_MODE] = {
>> .type = HDA_FIXUP_FUNC,
>> .v.func = alc_fixup_headset_mode_alc255,
>> },
>> + [ALC255_FIXUP_HEADSET_MODE_NO_HP_MIC] = {
>> + .type = HDA_FIXUP_FUNC,
>> + .v.func = alc_fixup_headset_mode_alc255_no_hp_mic,
>> + },
>> };
>>
>> static const struct snd_pci_quirk alc269_fixup_tbl[] = {
>> @@ -4314,6 +4346,8 @@ static const struct snd_pci_quirk
>> alc269_fixup_tbl[] =
>> {
>> SND_PCI_QUIRK(0x1028, 0x0658, "Dell",
>> ALC269_FIXUP_DELL1_MIC_NO_PRESENCE),
>> SND_PCI_QUIRK(0x1028, 0x065f, "Dell",
>> ALC255_FIXUP_DELL1_MIC_NO_PRESENCE),
>> SND_PCI_QUIRK(0x1028, 0x0662, "Dell",
>> ALC255_FIXUP_DELL1_MIC_NO_PRESENCE),
>> + SND_PCI_QUIRK(0x1028, 0x0668, "Dell",
>> ALC255_FIXUP_DELL2_MIC_NO_PRESENCE),
>> + SND_PCI_QUIRK(0x1028, 0x0669, "Dell",
>> ALC255_FIXUP_DELL2_MIC_NO_PRESENCE),
>> SND_PCI_QUIRK(0x1028, 0x15cc, "Dell X5 Precision",
>> ALC269_FIXUP_DELL2_MIC_NO_PRESENCE),
>> SND_PCI_QUIRK(0x1028, 0x15cd, "Dell X5 Precision",
>> ALC269_FIXUP_DELL2_MIC_NO_PRESENCE),
>> SND_PCI_QUIRK(0x103c, 0x1586, "HP", ALC269_FIXUP_HP_MUTE_LED_MIC2),
>>
>
> ------Please consider the environment before printing this e-mail.
[-- Attachment #2: 0000-Enable-headset-mic-for-Dell-DT.patch --]
[-- Type: application/octet-stream, Size: 3813 bytes --]
>From 2f448d6f9ad7023befa91b80f86cb267311d3f8a Mon Sep 17 00:00:00 2001
From: Kailang Yang <kailang@realtek.com>
Date: Mon, 3 Mar 2014 15:27:22 +0800
Subject: [PATCH] ALSA: hda/realtek - Add headset quirk for Dell DT
This quirk is needed for the headset microphone to work.
Signed-off-by: Kailang Yang <kailang@realtek.com>
diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c
index 534796e..74456bd 100644
--- a/sound/pci/hda/patch_realtek.c
+++ b/sound/pci/hda/patch_realtek.c
@@ -3594,21 +3594,38 @@ static void alc_fixup_headset_mode_no_hp_mic(struct hda_codec *codec,
alc_fixup_headset_mode(codec, fix, action);
}
+static void alc255_set_default_jack_type(struct hda_codec *codec)
+{
+ /* Set to iphone type */
+ alc_write_coef_idx(codec, 0x1b, 0x880b);
+ alc_write_coef_idx(codec, 0x45, 0xd089);
+ alc_write_coef_idx(codec, 0x1b, 0x080b);
+ alc_write_coef_idx(codec, 0x46, 0x0004);
+ alc_write_coef_idx(codec, 0x1b, 0x0c0b);
+ msleep(30);
+}
+
static void alc_fixup_headset_mode_alc255(struct hda_codec *codec,
const struct hda_fixup *fix, int action)
{
if (action == HDA_FIXUP_ACT_PRE_PROBE) {
- /* Set to iphone type */
- alc_write_coef_idx(codec, 0x1b, 0x880b);
- alc_write_coef_idx(codec, 0x45, 0xd089);
- alc_write_coef_idx(codec, 0x1b, 0x080b);
- alc_write_coef_idx(codec, 0x46, 0x0004);
- alc_write_coef_idx(codec, 0x1b, 0x0c0b);
- msleep(30);
+ alc255_set_default_jack_type(codec);
}
alc_fixup_headset_mode(codec, fix, action);
}
+static void alc_fixup_headset_mode_alc255_no_hp_mic(struct hda_codec *codec,
+ const struct hda_fixup *fix, int action)
+{
+ if (action == HDA_FIXUP_ACT_PRE_PROBE) {
+ struct alc_spec *spec = codec->spec;
+ spec->parse_flags |= HDA_PINCFG_HEADSET_MIC;
+ alc255_set_default_jack_type(codec);
+ }
+ else
+ alc_fixup_headset_mode(codec, fix, action);
+}
+
static void alc_fixup_auto_mute_via_amp(struct hda_codec *codec,
const struct hda_fixup *fix, int action)
{
@@ -3875,7 +3892,9 @@ enum {
ALC290_FIXUP_SUBWOOFER_HSJACK,
ALC269_FIXUP_THINKPAD_ACPI,
ALC255_FIXUP_DELL1_MIC_NO_PRESENCE,
+ ALC255_FIXUP_DELL2_MIC_NO_PRESENCE,
ALC255_FIXUP_HEADSET_MODE,
+ ALC255_FIXUP_HEADSET_MODE_NO_HP_MIC,
};
static const struct hda_fixup alc269_fixups[] = {
@@ -4248,10 +4267,23 @@ static const struct hda_fixup alc269_fixups[] = {
.chained = true,
.chain_id = ALC255_FIXUP_HEADSET_MODE
},
+ [ALC255_FIXUP_DELL2_MIC_NO_PRESENCE] = {
+ .type = HDA_FIXUP_PINS,
+ .v.pins = (const struct hda_pintbl[]) {
+ { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect */
+ { }
+ },
+ .chained = true,
+ .chain_id = ALC255_FIXUP_HEADSET_MODE_NO_HP_MIC
+ },
[ALC255_FIXUP_HEADSET_MODE] = {
.type = HDA_FIXUP_FUNC,
.v.func = alc_fixup_headset_mode_alc255,
},
+ [ALC255_FIXUP_HEADSET_MODE_NO_HP_MIC] = {
+ .type = HDA_FIXUP_FUNC,
+ .v.func = alc_fixup_headset_mode_alc255_no_hp_mic,
+ },
};
static const struct snd_pci_quirk alc269_fixup_tbl[] = {
@@ -4314,6 +4346,8 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = {
SND_PCI_QUIRK(0x1028, 0x0658, "Dell", ALC269_FIXUP_DELL1_MIC_NO_PRESENCE),
SND_PCI_QUIRK(0x1028, 0x065f, "Dell", ALC255_FIXUP_DELL1_MIC_NO_PRESENCE),
SND_PCI_QUIRK(0x1028, 0x0662, "Dell", ALC255_FIXUP_DELL1_MIC_NO_PRESENCE),
+ SND_PCI_QUIRK(0x1028, 0x0668, "Dell", ALC255_FIXUP_DELL2_MIC_NO_PRESENCE),
+ SND_PCI_QUIRK(0x1028, 0x0669, "Dell", ALC255_FIXUP_DELL2_MIC_NO_PRESENCE),
SND_PCI_QUIRK(0x1028, 0x15cc, "Dell X5 Precision", ALC269_FIXUP_DELL2_MIC_NO_PRESENCE),
SND_PCI_QUIRK(0x1028, 0x15cd, "Dell X5 Precision", ALC269_FIXUP_DELL2_MIC_NO_PRESENCE),
SND_PCI_QUIRK(0x103c, 0x1586, "HP", ALC269_FIXUP_HP_MUTE_LED_MIC2),
[-- Attachment #3: Type: text/plain, Size: 0 bytes --]
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: Enable headset Mic for Dell DT
2014-03-03 9:09 ` Kailang
@ 2014-03-03 9:49 ` Takashi Iwai
0 siblings, 0 replies; 4+ messages in thread
From: Takashi Iwai @ 2014-03-03 9:49 UTC (permalink / raw)
To: Kailang; +Cc: alsa-devel
At Mon, 3 Mar 2014 17:09:35 +0800,
Kailang wrote:
>
> Hi Takashi,
>
> Please see attachment.
> Thanks.
>
> Kailang
OK, applied now.
thanks,
Takashi
>
>
> > At Mon, 3 Mar 2014 15:42:42 +0800,
> > Kailang wrote:
> >>
> >> Hi Takashi,
> >>
> >> I created patch below for Dell DT for support headset MIC.
> >> Many Thanks.
> >
> > The changes look good, but the patch can't be applied cleanly because
> > your mailer broke spaces. Please fix MUA, or just use an attachment
> > in addition.
> >
> >
> > thanks,
> >
> > Takashi
> >
> >>
> >> Kailang.
> >>
> >>
> >> >From 2f448d6f9ad7023befa91b80f86cb267311d3f8a Mon Sep 17 00:00:00 2001
> >> From: Kailang Yang <kailang@realtek.com>
> >> Date: Mon, 3 Mar 2014 15:27:22 +0800
> >> Subject: [PATCH] ALSA: hda/realtek - Add headset quirk for Dell DT
> >>
> >> This quirk is needed for the headset microphone to work.
> >>
> >> Signed-off-by: Kailang Yang <kailang@realtek.com>
> >>
> >> diff --git a/sound/pci/hda/patch_realtek.c
> >> b/sound/pci/hda/patch_realtek.c
> >> index 534796e..74456bd 100644
> >> --- a/sound/pci/hda/patch_realtek.c
> >> +++ b/sound/pci/hda/patch_realtek.c
> >> @@ -3594,21 +3594,38 @@ static void
> >> alc_fixup_headset_mode_no_hp_mic(struct
> >> hda_codec *codec,
> >> alc_fixup_headset_mode(codec, fix, action);
> >> }
> >>
> >> +static void alc255_set_default_jack_type(struct hda_codec *codec)
> >> +{
> >> + /* Set to iphone type */
> >> + alc_write_coef_idx(codec, 0x1b, 0x880b);
> >> + alc_write_coef_idx(codec, 0x45, 0xd089);
> >> + alc_write_coef_idx(codec, 0x1b, 0x080b);
> >> + alc_write_coef_idx(codec, 0x46, 0x0004);
> >> + alc_write_coef_idx(codec, 0x1b, 0x0c0b);
> >> + msleep(30);
> >> +}
> >> +
> >> static void alc_fixup_headset_mode_alc255(struct hda_codec *codec,
> >> const struct hda_fixup *fix, int action)
> >> {
> >> if (action == HDA_FIXUP_ACT_PRE_PROBE) {
> >> - /* Set to iphone type */
> >> - alc_write_coef_idx(codec, 0x1b, 0x880b);
> >> - alc_write_coef_idx(codec, 0x45, 0xd089);
> >> - alc_write_coef_idx(codec, 0x1b, 0x080b);
> >> - alc_write_coef_idx(codec, 0x46, 0x0004);
> >> - alc_write_coef_idx(codec, 0x1b, 0x0c0b);
> >> - msleep(30);
> >> + alc255_set_default_jack_type(codec);
> >> }
> >> alc_fixup_headset_mode(codec, fix, action);
> >> }
> >>
> >> +static void alc_fixup_headset_mode_alc255_no_hp_mic(struct hda_codec
> >> *codec,
> >> + const struct hda_fixup *fix, int action)
> >> +{
> >> + if (action == HDA_FIXUP_ACT_PRE_PROBE) {
> >> + struct alc_spec *spec = codec->spec;
> >> + spec->parse_flags |= HDA_PINCFG_HEADSET_MIC;
> >> + alc255_set_default_jack_type(codec);
> >> + }
> >> + else
> >> + alc_fixup_headset_mode(codec, fix, action);
> >> +}
> >> +
> >> static void alc_fixup_auto_mute_via_amp(struct hda_codec *codec,
> >> const struct hda_fixup *fix, int action)
> >> {
> >> @@ -3875,7 +3892,9 @@ enum {
> >> ALC290_FIXUP_SUBWOOFER_HSJACK,
> >> ALC269_FIXUP_THINKPAD_ACPI,
> >> ALC255_FIXUP_DELL1_MIC_NO_PRESENCE,
> >> + ALC255_FIXUP_DELL2_MIC_NO_PRESENCE,
> >> ALC255_FIXUP_HEADSET_MODE,
> >> + ALC255_FIXUP_HEADSET_MODE_NO_HP_MIC,
> >> };
> >>
> >> static const struct hda_fixup alc269_fixups[] = {
> >> @@ -4248,10 +4267,23 @@ static const struct hda_fixup alc269_fixups[] = {
> >> .chained = true,
> >> .chain_id = ALC255_FIXUP_HEADSET_MODE
> >> },
> >> + [ALC255_FIXUP_DELL2_MIC_NO_PRESENCE] = {
> >> + .type = HDA_FIXUP_PINS,
> >> + .v.pins = (const struct hda_pintbl[]) {
> >> + { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack
> >> detect
> >> */
> >> + { }
> >> + },
> >> + .chained = true,
> >> + .chain_id = ALC255_FIXUP_HEADSET_MODE_NO_HP_MIC
> >> + },
> >> [ALC255_FIXUP_HEADSET_MODE] = {
> >> .type = HDA_FIXUP_FUNC,
> >> .v.func = alc_fixup_headset_mode_alc255,
> >> },
> >> + [ALC255_FIXUP_HEADSET_MODE_NO_HP_MIC] = {
> >> + .type = HDA_FIXUP_FUNC,
> >> + .v.func = alc_fixup_headset_mode_alc255_no_hp_mic,
> >> + },
> >> };
> >>
> >> static const struct snd_pci_quirk alc269_fixup_tbl[] = {
> >> @@ -4314,6 +4346,8 @@ static const struct snd_pci_quirk
> >> alc269_fixup_tbl[] =
> >> {
> >> SND_PCI_QUIRK(0x1028, 0x0658, "Dell",
> >> ALC269_FIXUP_DELL1_MIC_NO_PRESENCE),
> >> SND_PCI_QUIRK(0x1028, 0x065f, "Dell",
> >> ALC255_FIXUP_DELL1_MIC_NO_PRESENCE),
> >> SND_PCI_QUIRK(0x1028, 0x0662, "Dell",
> >> ALC255_FIXUP_DELL1_MIC_NO_PRESENCE),
> >> + SND_PCI_QUIRK(0x1028, 0x0668, "Dell",
> >> ALC255_FIXUP_DELL2_MIC_NO_PRESENCE),
> >> + SND_PCI_QUIRK(0x1028, 0x0669, "Dell",
> >> ALC255_FIXUP_DELL2_MIC_NO_PRESENCE),
> >> SND_PCI_QUIRK(0x1028, 0x15cc, "Dell X5 Precision",
> >> ALC269_FIXUP_DELL2_MIC_NO_PRESENCE),
> >> SND_PCI_QUIRK(0x1028, 0x15cd, "Dell X5 Precision",
> >> ALC269_FIXUP_DELL2_MIC_NO_PRESENCE),
> >> SND_PCI_QUIRK(0x103c, 0x1586, "HP", ALC269_FIXUP_HP_MUTE_LED_MIC2),
> >>
> >
> > ------Please consider the environment before printing this e-mail.
> [2 0000-Enable-headset-mic-for-Dell-DT.patch <application/octet-stream (quoted-printable)>]
>
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2014-03-03 9:49 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-03-03 7:42 Enable headset Mic for Dell DT Kailang
2014-03-03 8:59 ` Takashi Iwai
2014-03-03 9:09 ` Kailang
2014-03-03 9:49 ` Takashi Iwai
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).