lkml.org 
[lkml]   [2016]   [Jan]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH 3.16.y-ckt 033/128] ALSA: hda - Fix noise problems on Thinkpad T440s
    Date
    3.16.7-ckt23 -stable review patch.  If anyone has any objections, please let me know.

    ---8<------------------------------------------------------------

    From: Takashi Iwai <tiwai@suse.de>

    commit 9a811230481243f384b8036c6a558bfdbd961f78 upstream.

    Lenovo Thinkpad T440s suffers from constant background noises, and it
    seems to be a generic hardware issue on this model:
    https://forums.lenovo.com/t5/ThinkPad-T400-T500-and-newer-T/T440s-speaker-noise/td-p/1339883

    As the noise comes from the analog loopback path, disabling the path
    is the easy workaround.

    Also, the machine gives significant cracking noises at PM suspend. A
    workaround found by trial-and-error is to disable the shutup callback
    currently used for ALC269-variant.

    This patch addresses these noise issues by introducing a new fixup
    chain. Although the same workaround might be applicable to other
    Thinkpad models, it's applied only to T440s (17aa:220c) in this patch,
    so far, just to be safe (you chicken!). As a compromise, a new model
    option string "tp440" is provided now, though, so that owners of other
    Thinkpad models can test it more easily.

    Bugzilla: https://bugzilla.opensuse.org/show_bug.cgi?id=958504
    Reported-and-tested-by: Tim Hardeck <thardeck@suse.de>
    Signed-off-by: Takashi Iwai <tiwai@suse.de>
    [ luis: backported to 3.16: adjusted context ]
    Signed-off-by: Luis Henriques <luis.henriques@canonical.com>
    ---
    sound/pci/hda/patch_realtek.c | 22 +++++++++++++++++++++-
    1 file changed, 21 insertions(+), 1 deletion(-)

    diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c
    index e3a98869b1b6..148957ca1d04 100644
    --- a/sound/pci/hda/patch_realtek.c
    +++ b/sound/pci/hda/patch_realtek.c
    @@ -4029,6 +4029,18 @@ static void alc_fixup_disable_aamix(struct hda_codec *codec,
    }
    }

    +/* additional fixup for Thinkpad T440s noise problem */
    +static void alc_fixup_tpt440(struct hda_codec *codec,
    + const struct hda_fixup *fix, int action)
    +{
    + struct alc_spec *spec = codec->spec;
    +
    + if (action == HDA_FIXUP_ACT_PRE_PROBE) {
    + spec->shutup = alc_no_shutup; /* reduce click noise */
    + spec->gen.mixer_nid = 0; /* reduce background noise */
    + }
    +}
    +
    static unsigned int alc_power_filter_xps13(struct hda_codec *codec,
    hda_nid_t nid,
    unsigned int power_state)
    @@ -4325,6 +4337,7 @@ enum {
    ALC293_FIXUP_DELL1_MIC_NO_PRESENCE,
    ALC292_FIXUP_TPT440_DOCK,
    ALC292_FIXUP_TPT440_DOCK2,
    + ALC292_FIXUP_TPT440,
    ALC275_FIXUP_DELL_XPS,
    ALC256_FIXUP_DELL_XPS_13_HEADPHONE_NOISE,
    ALC293_FIXUP_LENOVO_SPK_NOISE,
    @@ -4780,6 +4793,12 @@ static const struct hda_fixup alc269_fixups[] = {
    .chained = true,
    .chain_id = ALC269_FIXUP_LIMIT_INT_MIC_BOOST
    },
    + [ALC292_FIXUP_TPT440] = {
    + .type = HDA_FIXUP_FUNC,
    + .v.func = alc_fixup_tpt440,
    + .chained = true,
    + .chain_id = ALC292_FIXUP_TPT440_DOCK,
    + },
    [ALC275_FIXUP_DELL_XPS] = {
    .type = HDA_FIXUP_VERBS,
    .v.verbs = (const struct hda_verb[]) {
    @@ -4961,7 +4980,7 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = {
    SND_PCI_QUIRK(0x17aa, 0x21fb, "Thinkpad T430s", ALC269_FIXUP_LENOVO_DOCK),
    SND_PCI_QUIRK(0x17aa, 0x2203, "Thinkpad X230 Tablet", ALC269_FIXUP_LENOVO_DOCK),
    SND_PCI_QUIRK(0x17aa, 0x2208, "Thinkpad T431s", ALC269_FIXUP_LENOVO_DOCK),
    - SND_PCI_QUIRK(0x17aa, 0x220c, "Thinkpad T440s", ALC292_FIXUP_TPT440_DOCK),
    + SND_PCI_QUIRK(0x17aa, 0x220c, "Thinkpad T440s", ALC292_FIXUP_TPT440),
    SND_PCI_QUIRK(0x17aa, 0x220e, "Thinkpad T440p", ALC292_FIXUP_TPT440_DOCK),
    SND_PCI_QUIRK(0x17aa, 0x2210, "Thinkpad T540p", ALC292_FIXUP_TPT440_DOCK),
    SND_PCI_QUIRK(0x17aa, 0x2212, "Thinkpad T440", ALC292_FIXUP_TPT440_DOCK),
    @@ -5050,6 +5069,7 @@ static const struct hda_model_fixup alc269_fixup_models[] = {
    {.id = ALC283_FIXUP_CHROME_BOOK, .name = "alc283-dac-wcaps"},
    {.id = ALC283_FIXUP_SENSE_COMBO_JACK, .name = "alc283-sense-combo"},
    {.id = ALC292_FIXUP_TPT440_DOCK, .name = "tpt440-dock"},
    + {.id = ALC292_FIXUP_TPT440, .name = "tpt440"},
    {}
    };

    \
     
     \ /
      Last update: 2016-01-25 00:21    [W:4.638 / U:0.072 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site