Received: by 2002:ab2:6991:0:b0:1f7:f6c3:9cb1 with SMTP id v17csp417306lqo; Wed, 8 May 2024 04:02:55 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVRmv2np2zL+ya378t5tLQfNactad8K0Y60++MyOKLo7kwZ6Dz7VGsMSDfcwZrdOxDYY5jEXQXmfivzqBoYsYMgf1dZ/rENE1c/haudMw== X-Google-Smtp-Source: AGHT+IFtr8uqEWBY95LkR8w6zsOLquvibRLP/VgnsNiD90IynnOHnoZ8wTWDMd36dsToxzHUkAeN X-Received: by 2002:a05:6214:1949:b0:6a0:c953:cb02 with SMTP id 6a1803df08f44-6a151436b77mr27223866d6.3.1715166175709; Wed, 08 May 2024 04:02:55 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1715166175; cv=pass; d=google.com; s=arc-20160816; b=otkm0IyIxxiOwJqc4eWKLwcpUFBq5Dn+xRqBsX1O/bHq43NJQRQsP84sUPdu7EAJca bTkZ1J8Aaw9RQCK2bNfywLytn1NhkAGolXlVZ8Fa8FOMBplMblnL2fJxl4hUfc5jEvLz F/u98+/riHqfuja5CAdVmU3g71zXvtE0+s8p2choHs0ZIHgw/na+7lu7/Y977ENwv/6N lgg7ykmqaZwsj0952nlEs8J8ula+Rxtu9KPT2Dz197bQKIa48RglLkfcwzTVBKvwOpLW 7s2yeGsy1SGN0mteom7Sf7o611NSiLfWtkQcH3xFw3vj6sWlnkDbK1ssfoga+Nj2SwPi p9/w== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :subject:date:from:dkim-signature; bh=JckYzcWe8w+0grZPS9NysF8GgHh7PfoFNUhYz6cHvfw=; fh=jRvq0W8lknkI9KcjUNT/ADcGd6Cv9ee9nRhZ4jfh2oA=; b=DExV6/zs30Xjlv/fkbEKVb0Y4ZRVawovar3ioYfs/MXw+VC8cCuMABnjRbZuP4Uwe6 kOSknyIbNppjMnHxgywP2TF7TXoDmnY3yVytiRapruQ3Lk2iCWtzeSpIRCSQ7p4TQMno VqvxcLHNsgshGIGMjkeI5hp3WPAn1Um0petKOlbK5/Hj7PNzZmCCkUITJj1c8xMx2tFr Z1L4L/WnRXUrjqrvLt1JvO13f1f+NUKcadzJacPaBImKs+324fKe9imvq7bHbmNXP1WU 2MWInlsqIbAmVeFFRTJ4RN2UdzPv6FCdC4jkJBjK1kIBvA36XWP/f3vRmLk0adb/VxQG h1Ig==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=QuMMpDjH; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-173101-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-173101-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id fn3-20020ad45d63000000b006a0cd6a78b9si13934077qvb.15.2024.05.08.04.02.55 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 08 May 2024 04:02:55 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-173101-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=QuMMpDjH; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-173101-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-173101-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id EE8791C2025F for ; Wed, 8 May 2024 11:02:45 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 71A3584A5C; Wed, 8 May 2024 11:01:30 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="QuMMpDjH" Received: from mail-lf1-f51.google.com (mail-lf1-f51.google.com [209.85.167.51]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C8E0382D9F; Wed, 8 May 2024 11:01:27 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.167.51 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715166089; cv=none; b=OUcF+0s8yHj5JvXSDhbf7aE4KzVGL/zjFsZ0mcu2E3R0AoXFpe1ZVGIQPJ1azRYasKl9AW7ejLsTUKNiMxksKo4SS0afkK17X+fQ9m8cCLlqq+bNp2kVpmIbaU+QnK8g4rPDNC+M9Vb84kgiqGFcZrJSpRKXyIoTEnuIsETc3AU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715166089; c=relaxed/simple; bh=7ghoUuP1F66lo5lQILjtg4IgiT6Z0TAcd0jCIemjWlQ=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=CmaxcjQw5DDQscvm7DB9ez0OjxeEzinIN7/1Fpszw3I5l5K9OygoSW0208DHUlfJPBUDD8o3xiBfwpZl5rKFbcHw93kVE3zdIfsnISXqk/+OTy5N5qvgJzy3FT1dx2Vx15NUVqlF828Lejg+9gw2pLXieAy8KckmmRK3ZqDYIFo= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=QuMMpDjH; arc=none smtp.client-ip=209.85.167.51 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-lf1-f51.google.com with SMTP id 2adb3069b0e04-51f72a29f13so5077229e87.3; Wed, 08 May 2024 04:01:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1715166086; x=1715770886; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=JckYzcWe8w+0grZPS9NysF8GgHh7PfoFNUhYz6cHvfw=; b=QuMMpDjHPVcKHvAi7qfwl+O1FmvQlCvE+Ur+5LkKeGTEK9bCqqzfTTluGgcPJkFOt4 6S4AISEIk4AqwRNKTIfdaJkUiZx/kN7D38leIMPNibOoDS2x00QUwSYT22g3jb85xYU6 4VR1hhfYA/Y1878q6noBA/g/ORqG300vcc71by0nB0cGL0pEEN7ZCEpU1z/WcWtERPTo KOmZEhaXlFMecnYz1ws9yJi9JXEOCoWZsadA66UTC6cqu+s3/1+vFOGWBwcJ+d9a/8Dz 9UcoUN0jOu93ZW8Uh+BVSwBulWEQAOTEOCBJhJ8lXS9E+1QniULajr0A3MhAgAz+8ggT RL7Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1715166086; x=1715770886; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=JckYzcWe8w+0grZPS9NysF8GgHh7PfoFNUhYz6cHvfw=; b=tzcvzfgQLF+V96du1wdEdtvHzTRCXwtmX5caqrnH//Rgw/6bCWTxnyo1wwrG/Kg4MB g4WwLA83nq4t+qjrn+OlAxCR0Cvk75BZTfJsP1MjrFsRVkIZDmLqZ1n6SF2V6EYTK+mV O9Ez3iWmmLmjzcxbNPIrwBXVibzwKm31oUNM1SPL5ezmttcXIH2myuIzlPA/BhjjOfzg Zhmkl2u+bWAwf0g31lrp/RLQIIsOXRiHl7vQBASWFd/NQqt1mrXkTI7H3YT1vp1ke+Kj suNi7x27NyGGLO6TXnYznGAFM8MqgjM6606kpeI6XW5TrErylaaTtVthDbfy/eR1tuvQ V1BA== X-Forwarded-Encrypted: i=1; AJvYcCU9Z+H3idP0snMelo5ke2/PL3uv4ND8sKZl+3ukTNeh60dDmyvwhj90bUqPYJEu1h7sGPfvJXVfM1Cnw5hoUDZ7LMyJKlBZ+ddVyNPu1LP/bktd/Hm9szgTca+QeB7Zq4MF0I9XQOpwuLSFyRSmculTKsZ4kXM/uLfopKlUwFdfvMHyrr3kBmAuqDkM/pBQ+O47lwV/WHKRsUtE3WxOj0D1VPpiixCRTzo= X-Gm-Message-State: AOJu0YxGKG/uDxEty74GS7TIhqMWXnMAccNgNcl0AqvnjoAi1LOyzPLp UMprWRv9Nu3awAaIVpctKnQeIRv42LkRROpsDqPOxsLu1QkXKVCX X-Received: by 2002:a05:6512:40e:b0:518:9362:f63 with SMTP id 2adb3069b0e04-5217b5a6837mr1384384e87.0.1715166085711; Wed, 08 May 2024 04:01:25 -0700 (PDT) Received: from hex.my.domain (83.8.126.253.ipv4.supernova.orange.pl. [83.8.126.253]) by smtp.gmail.com with ESMTPSA id m6-20020a056402510600b005726b58a436sm7455793edd.30.2024.05.08.04.01.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 08 May 2024 04:01:25 -0700 (PDT) From: Artur Weber Date: Wed, 08 May 2024 12:58:54 +0200 Subject: [PATCH v2 6/7] ARM: dts: samsung: exynos4212-tab3: Fix headset mic, add jack detection Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20240508-midas-wm1811-gpio-jack-v2-6-b4d36cd02c6e@gmail.com> References: <20240508-midas-wm1811-gpio-jack-v2-0-b4d36cd02c6e@gmail.com> In-Reply-To: <20240508-midas-wm1811-gpio-jack-v2-0-b4d36cd02c6e@gmail.com> To: Sylwester Nawrocki , Krzysztof Kozlowski Cc: Liam Girdwood , Mark Brown , Rob Herring , Conor Dooley , Jaroslav Kysela , Takashi Iwai , Alim Akhtar , alsa-devel@alsa-project.org, linux-sound@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, ~postmarketos/upstreaming@lists.sr.ht, Artur Weber X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=ed25519-sha256; t=1715166076; l=1934; i=aweber.kernel@gmail.com; s=20231030; h=from:subject:message-id; bh=7ghoUuP1F66lo5lQILjtg4IgiT6Z0TAcd0jCIemjWlQ=; b=l0DFXbMoynUW/3tl/JJn+d4FFNg8IhQpMsG9UJeOU2kGTDNLpMYNTOAalpniOTbooBzyKlSiZ P9EqRrOaA4YA0I/fq2SM0f9GJDPc5NwRz+qYyqlEMUZfFI//F0HjlH5 X-Developer-Key: i=aweber.kernel@gmail.com; a=ed25519; pk=RhDBfWbJEHqDibXbhNEBAnc9FMkyznGxX/hwfhL8bv8= Set up headset mic bias regulator and add the necessary properties to the samsung,midas-audio node to allow for headset jack detection. Signed-off-by: Artur Weber --- Changes in v2: - Added headset mic bias regulator - Added samsung prefix to threshold properties - Dropped wm1811 config changes --- arch/arm/boot/dts/samsung/exynos4212-tab3.dtsi | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/arch/arm/boot/dts/samsung/exynos4212-tab3.dtsi b/arch/arm/boot/dts/samsung/exynos4212-tab3.dtsi index e5254e32aa8f..8dc81112172c 100644 --- a/arch/arm/boot/dts/samsung/exynos4212-tab3.dtsi +++ b/arch/arm/boot/dts/samsung/exynos4212-tab3.dtsi @@ -294,11 +294,30 @@ submic_bias_reg: voltage-regulator-5 { regulator-max-microvolt = <2800000>; }; + earmic_bias_reg: voltage-regulator-6 { + compatible = "regulator-fixed"; + regulator-name = "EAR_MICBIAS_LDO_2.8V"; + regulator-min-microvolt = <2800000>; + regulator-max-microvolt = <2800000>; + gpio = <&gpm0 0 GPIO_ACTIVE_HIGH>; + enable-active-high; + }; + sound: sound { compatible = "samsung,midas-audio"; model = "TAB3"; mic-bias-supply = <&mic_bias_reg>; submic-bias-supply = <&submic_bias_reg>; + headset-mic-bias-supply = <&earmic_bias_reg>; + + lineout-sel-gpios = <&gpj1 2 GPIO_ACTIVE_HIGH>; + + headset-detect-gpios = <&gpx0 4 GPIO_ACTIVE_LOW>; + headset-key-gpios = <&gpx3 6 GPIO_ACTIVE_LOW>; + samsung,headset-4pole-threshold-microvolt = <710 2000>; + samsung,headset-button-threshold-microvolt = <0 130 260>; + io-channel-names = "headset-detect"; + io-channels = <&adc 0>; audio-routing = "HP", "HPOUT1L", "HP", "HPOUT1R", @@ -345,6 +364,11 @@ wlan_pwrseq: sdhci3-pwrseq { }; }; +&adc { + vdd-supply = <&ldo3_reg>; + status = "okay"; +}; + &bus_acp { devfreq = <&bus_dmc>; status = "okay"; -- 2.45.0