Received: by 2002:a5b:505:0:0:0:0:0 with SMTP id o5csp23131ybp; Thu, 3 Oct 2019 09:38:28 -0700 (PDT) X-Google-Smtp-Source: APXvYqwTMENdBpZB1BDQMKAC/br7SiAuufCpuTY3bBDbXp5t9HkgMiCtg3UJAUFgVyNG2ufBoPtX X-Received: by 2002:a50:91d8:: with SMTP id h24mr10368080eda.61.1570120708094; Thu, 03 Oct 2019 09:38:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1570120708; cv=none; d=google.com; s=arc-20160816; b=sHBjZEIuOtn7VzxOulGPARYR/TTXedpp75xe+EAmqDuhRfySSXPeBaqlPFnxQmjmSU ao9MgKHl3uKJr6MZBzHPK5+dK2sh1FvdchzJdijf4WL6oImv9/6gd1VUU4DnTlPpx999 FLsdXjl2XxPZVhtpylbMO+7Yo0MMf92aKH7RE4g1PsKRi2EMZZuyLYK46XiKdyDSSy45 VbqmgQbR/qLi5fOAm4y2ZK3Rs36ObiD5I7JYK+2AgZz16hQv/u05FjNwFDOW+I18C+mx 63EJP9ZR67pd54xHkxHYpUsLOSLPiLlh46vUI4cKCgRcOXGZluSVRIH+ggzJigvH7Uqg /S+Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=4gGkinUDM3YykCODSUV3ujDPf9alJsP7DWJwY3YCU30=; b=07qtyEko1bWslg5lek08AVJW4uupIPFEnQhOISwclexXqnqSoMeAjH3+KBaVB2SQ94 w4Hv2+OPQHqb5FfkaSISPi8gTeTJyL3WDGJNhtP/JKap+oxNCiruIutHD9aVwryucR6u ePlV1Aq8UhG9Zw0rhMt6Eq2ltzP2zhECeDxnkTLdc+qglzFwqUf6MpnYKqOZId4+ESS3 a3r/Nrq+qNkFWIxsXm9Yf449R/mtYIBSN3/Hrb2sBRGc6df4k6mKhdut9+22/T+jyab5 eljWQh9ZTWyjJmRnAsIJ11YxjAqWz49B0ecIIMXbpevOIpEmfnANLPRp2vyrW+h6N1Gl ArPQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=H8NK+EuF; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id oz19si1512558ejb.93.2019.10.03.09.38.01; Thu, 03 Oct 2019 09:38:28 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=H8NK+EuF; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2392113AbfJCQeQ (ORCPT + 99 others); Thu, 3 Oct 2019 12:34:16 -0400 Received: from mail.kernel.org ([198.145.29.99]:42722 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2404152AbfJCQeP (ORCPT ); Thu, 3 Oct 2019 12:34:15 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id D859F215EA; Thu, 3 Oct 2019 16:34:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1570120454; bh=hg7cnCXjeGWahhxiH2BWq0tRZool+GN4nN36HueKydU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=H8NK+EuFQF+BoD6qhy2DkkjrSwjOm2CtB20KUbMdijL10gVQVemFxrbB/0jeMbVo3 lkD6x6zafOzaPPpJUmpO2Je08lKvFFa8mZkKuownVWkFUA7AKFz/M4h02qUsrJDsvq QquXyWy8V9m8wa0d9WHqS7Mp+uHCwsm17ceOxQvs= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Jan-Marek Glogowski , Takashi Iwai , Sasha Levin Subject: [PATCH 5.2 228/313] ALSA: hda/realtek - PCI quirk for Medion E4254 Date: Thu, 3 Oct 2019 17:53:26 +0200 Message-Id: <20191003154555.468959729@linuxfoundation.org> X-Mailer: git-send-email 2.23.0 In-Reply-To: <20191003154533.590915454@linuxfoundation.org> References: <20191003154533.590915454@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Jan-Marek Glogowski [ Upstream commit bd9c10bc663dd2eaac8fe39dad0f18cd21527446 ] The laptop has a combined jack to attach headsets on the right. The BIOS encodes them as two different colored jacks at the front, but otherwise it seems to be configured ok. But any adaption of the pins config on its own doesn't fix the jack detection to work in Linux. Still Windows works correct. This is somehow fixed by chaining ALC256_FIXUP_ASUS_HEADSET_MODE, which seems to register the microphone jack as a headset part and also results in fixing jack sensing, visible in dmesg as: -snd_hda_codec_realtek hdaudioC0D0: Mic=0x19 +snd_hda_codec_realtek hdaudioC0D0: Headset Mic=0x19 [ Actually the essential change is the location of the jack; the driver created "Front Mic Jack" without the matching volume / mute control element due to its jack location, which confused PA. -- tiwai ] Signed-off-by: Jan-Marek Glogowski Cc: Link: https://lore.kernel.org/r/8f4f9b20-0aeb-f8f1-c02f-fd53c09679f1@fbihome.de Signed-off-by: Takashi Iwai Signed-off-by: Sasha Levin --- sound/pci/hda/patch_realtek.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c index d223a79ac934f..36aee8ad20547 100644 --- a/sound/pci/hda/patch_realtek.c +++ b/sound/pci/hda/patch_realtek.c @@ -5870,6 +5870,7 @@ enum { ALC256_FIXUP_ASUS_MIC_NO_PRESENCE, ALC299_FIXUP_PREDATOR_SPK, ALC294_FIXUP_ASUS_INTSPK_HEADSET_MIC, + ALC256_FIXUP_MEDION_HEADSET_NO_PRESENCE, }; static const struct hda_fixup alc269_fixups[] = { @@ -6926,6 +6927,16 @@ static const struct hda_fixup alc269_fixups[] = { .chained = true, .chain_id = ALC269_FIXUP_HEADSET_MODE_NO_HP_MIC }, + [ALC256_FIXUP_MEDION_HEADSET_NO_PRESENCE] = { + .type = HDA_FIXUP_PINS, + .v.pins = (const struct hda_pintbl[]) { + { 0x19, 0x04a11040 }, + { 0x21, 0x04211020 }, + { } + }, + .chained = true, + .chain_id = ALC256_FIXUP_ASUS_HEADSET_MODE + }, }; static const struct snd_pci_quirk alc269_fixup_tbl[] = { @@ -7189,6 +7200,7 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = { SND_PCI_QUIRK(0x17aa, 0x9e54, "LENOVO NB", ALC269_FIXUP_LENOVO_EAPD), SND_PCI_QUIRK(0x19e5, 0x3204, "Huawei MACH-WX9", ALC256_FIXUP_HUAWEI_MACH_WX9_PINS), SND_PCI_QUIRK(0x1b7d, 0xa831, "Ordissimo EVE2 ", ALC269VB_FIXUP_ORDISSIMO_EVE2), /* Also known as Malata PC-B1303 */ + SND_PCI_QUIRK(0x10ec, 0x118c, "Medion EE4254 MD62100", ALC256_FIXUP_MEDION_HEADSET_NO_PRESENCE), #if 0 /* Below is a quirk table taken from the old code. @@ -7357,6 +7369,7 @@ static const struct hda_model_fixup alc269_fixup_models[] = { {.id = ALC295_FIXUP_CHROME_BOOK, .name = "alc-chrome-book"}, {.id = ALC299_FIXUP_PREDATOR_SPK, .name = "predator-spk"}, {.id = ALC298_FIXUP_HUAWEI_MBX_STEREO, .name = "huawei-mbx-stereo"}, + {.id = ALC256_FIXUP_MEDION_HEADSET_NO_PRESENCE, .name = "alc256-medion-headset"}, {} }; #define ALC225_STANDARD_PINS \ -- 2.20.1