From patchwork Mon Jan 2 10:50:36 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Johan Hovold X-Patchwork-Id: 638595 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0C400C5479D for ; Mon, 2 Jan 2023 10:51:31 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232724AbjABKv3 (ORCPT ); Mon, 2 Jan 2023 05:51:29 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52424 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232642AbjABKvM (ORCPT ); Mon, 2 Jan 2023 05:51:12 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 05F3D62EF; Mon, 2 Jan 2023 02:50:53 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 9199060F2E; Mon, 2 Jan 2023 10:50:52 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 82C45C433B4; Mon, 2 Jan 2023 10:50:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1672656651; bh=Nyqaf4bMK9dpEeEzGEV6JiYvRsVHPutFOLZwu11jQ2g=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Ymvz2PV60CNcTI+Gcs/E6FuKXe0Yshdl7PycIGVyxCm3+pEqrIZRHCo3bDYcXHexm F7iv/3w/PRyBeSPumFOpIvLpjbuKNXIjum7BieLAfmTn+xJtxr/0K582Ht+IOrqXwd u32LHlAUxHuKVQciYqj2XwSFe8q3ovHipiFH9DEIxLURAzpvPFRzwYmujLxqbWcnsd KzReIfY0jP8j/GrDGoPx69YyHAKHOwMaqnpIMrkVebvnTxAWiKtJ+xXIIx4C6TVo74 7LLMSeLtCgfZoPdRG1QC5jZfUKEIvzKuWD7mKLU4S8prQIoxpjMy/3p5IPieN1sU3u ndv+Chf/X1VIw== Received: from johan by xi.lan with local (Exim 4.94.2) (envelope-from ) id 1pCIPM-00026w-EE; Mon, 02 Jan 2023 11:51:08 +0100 From: Johan Hovold To: Bjorn Andersson Cc: Andy Gross , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Srinivas Kandagatla , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Johan Hovold Subject: [PATCH 4/6] arm64: dts: qcom: sc8280xp-x13s: fix wcd938x codec node Date: Mon, 2 Jan 2023 11:50:36 +0100 Message-Id: <20230102105038.8074-5-johan+linaro@kernel.org> X-Mailer: git-send-email 2.37.4 In-Reply-To: <20230102105038.8074-1-johan+linaro@kernel.org> References: <20230102105038.8074-1-johan+linaro@kernel.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org The wcd938x codec is not a memory-mapped device and does not belong under the soc node. Move the node to the root node to avoid DT validation failures. While at it, clean up the node somewhat by adding newline separators, reordering properties and renaming it 'audio-codec'. Signed-off-by: Johan Hovold --- .../qcom/sc8280xp-lenovo-thinkpad-x13s.dts | 54 ++++++++++--------- 1 file changed, 28 insertions(+), 26 deletions(-) diff --git a/arch/arm64/boot/dts/qcom/sc8280xp-lenovo-thinkpad-x13s.dts b/arch/arm64/boot/dts/qcom/sc8280xp-lenovo-thinkpad-x13s.dts index 97ff74d5095e..ae67c11bfc22 100644 --- a/arch/arm64/boot/dts/qcom/sc8280xp-lenovo-thinkpad-x13s.dts +++ b/arch/arm64/boot/dts/qcom/sc8280xp-lenovo-thinkpad-x13s.dts @@ -21,6 +21,34 @@ / { model = "Lenovo ThinkPad X13s"; compatible = "lenovo,thinkpad-x13s", "qcom,sc8280xp"; + wcd938x: audio-codec { + compatible = "qcom,wcd9380-codec"; + + pinctrl-names = "default"; + pinctrl-0 = <&wcd_default>; + + reset-gpios = <&tlmm 106 GPIO_ACTIVE_LOW>; + + vdd-buck-supply = <&vreg_s10b>; + vdd-rxtx-supply = <&vreg_s10b>; + vdd-io-supply = <&vreg_s10b>; + vdd-mic-bias-supply = <&vreg_bob>; + + qcom,micbias1-microvolt = <1800000>; + qcom,micbias2-microvolt = <1800000>; + qcom,micbias3-microvolt = <1800000>; + qcom,micbias4-microvolt = <1800000>; + qcom,mbhc-buttons-vthreshold-microvolt = <75000 150000 237000 500000 500000 500000 500000 500000>; + qcom,mbhc-headset-vthreshold-microvolt = <1700000>; + qcom,mbhc-headphone-vthreshold-microvolt = <50000>; + qcom,rx-device = <&wcd_rx>; + qcom,tx-device = <&wcd_tx>; + + #sound-dai-cells = <1>; + + status = "disabled"; + }; + backlight { compatible = "pwm-backlight"; pwms = <&pmc8280c_lpg 3 1000000>; @@ -628,32 +656,6 @@ &remoteproc_nsp0 { status = "okay"; }; -&soc { - wcd938x: codec { - compatible = "qcom,wcd9380-codec"; - pinctrl-names = "default"; - pinctrl-0 = <&wcd_default>; - reset-gpios = <&tlmm 106 GPIO_ACTIVE_LOW>; - #sound-dai-cells = <1>; - - vdd-buck-supply = <&vreg_s10b>; - vdd-rxtx-supply = <&vreg_s10b>; - vdd-io-supply = <&vreg_s10b>; - vdd-mic-bias-supply = <&vreg_bob>; - qcom,micbias1-microvolt = <1800000>; - qcom,micbias2-microvolt = <1800000>; - qcom,micbias3-microvolt = <1800000>; - qcom,micbias4-microvolt = <1800000>; - qcom,mbhc-buttons-vthreshold-microvolt = <75000 150000 237000 500000 500000 500000 500000 500000>; - qcom,mbhc-headset-vthreshold-microvolt = <1700000>; - qcom,mbhc-headphone-vthreshold-microvolt = <50000>; - qcom,rx-device = <&wcd_rx>; - qcom,tx-device = <&wcd_tx>; - - status = "disabled"; - }; -}; - &sound { compatible = "qcom,sc8280xp-sndcard"; model = "SC8280XP-LENOVO-X13S"; From patchwork Mon Jan 2 10:50:37 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Johan Hovold X-Patchwork-Id: 638594 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id A4FA1C54EBF for ; Mon, 2 Jan 2023 10:51:32 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232730AbjABKvb (ORCPT ); Mon, 2 Jan 2023 05:51:31 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52436 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232643AbjABKvN (ORCPT ); Mon, 2 Jan 2023 05:51:13 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0E05062F2; Mon, 2 Jan 2023 02:50:53 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 95C3860F2F; Mon, 2 Jan 2023 10:50:52 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 82E3AC43442; Mon, 2 Jan 2023 10:50:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1672656651; bh=lCnlWTz7E2JT4DsGGsbUN7wr3y738SvPqozHAINwpoA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=jbNETFuc5HXKLMyoVazu/4FhPND8PQ9dLi8Qd4l/Sxjay0tr960z9OkubYQ1968IL YkXh/3tNYJlakdMuyWk7lJvrFBmMoC6jhZdTWIzHGRyjtLqrhregv1Y82c82ORGebN I1Tfq37XX1B6zG/cPNwjdbtr2Hv8dsoQ5BmyQqcvSIFx/w4pknBTb28pwD39hCSMfW TP/5uUVAVsPkxdbgLL3MUGUMYLE7+rSiePbuV56dwKEKFOLgyg68SPtbiOPVppkWGA i44g3lC6mXepHtRBT+1dBJHzSeMjs+tRAKwwq4aeKUjpERRtPwwzo2Iyrj4wqwgaho typQjxsCXKibw== Received: from johan by xi.lan with local (Exim 4.94.2) (envelope-from ) id 1pCIPM-000270-H5; Mon, 02 Jan 2023 11:51:08 +0100 From: Johan Hovold To: Bjorn Andersson Cc: Andy Gross , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Srinivas Kandagatla , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Johan Hovold Subject: [PATCH 5/6] arm64: dts: qcom: sm8250-mtp: fix wcd938x codec node Date: Mon, 2 Jan 2023 11:50:37 +0100 Message-Id: <20230102105038.8074-6-johan+linaro@kernel.org> X-Mailer: git-send-email 2.37.4 In-Reply-To: <20230102105038.8074-1-johan+linaro@kernel.org> References: <20230102105038.8074-1-johan+linaro@kernel.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org The wcd938x codec is not a memory-mapped device and does not belong under the soc node. Move the node to the root node to avoid DT validation failures. Signed-off-by: Johan Hovold --- arch/arm64/boot/dts/qcom/sm8250-mtp.dts | 40 ++++++++++++------------- 1 file changed, 19 insertions(+), 21 deletions(-) diff --git a/arch/arm64/boot/dts/qcom/sm8250-mtp.dts b/arch/arm64/boot/dts/qcom/sm8250-mtp.dts index 3ed8c84e25b8..ea43dbdc3671 100644 --- a/arch/arm64/boot/dts/qcom/sm8250-mtp.dts +++ b/arch/arm64/boot/dts/qcom/sm8250-mtp.dts @@ -23,6 +23,25 @@ aliases { serial0 = &uart12; }; + wcd938x: codec { + compatible = "qcom,wcd9380-codec"; + #sound-dai-cells = <1>; + reset-gpios = <&tlmm 32 GPIO_ACTIVE_LOW>; + vdd-buck-supply = <&vreg_s4a_1p8>; + vdd-rxtx-supply = <&vreg_s4a_1p8>; + vdd-io-supply = <&vreg_s4a_1p8>; + vdd-mic-bias-supply = <&vreg_bob>; + qcom,micbias1-microvolt = <1800000>; + qcom,micbias2-microvolt = <1800000>; + qcom,micbias3-microvolt = <1800000>; + qcom,micbias4-microvolt = <1800000>; + qcom,mbhc-buttons-vthreshold-microvolt = <75000 150000 237000 500000 500000 500000 500000 500000>; + qcom,mbhc-headset-vthreshold-microvolt = <1700000>; + qcom,mbhc-headphone-vthreshold-microvolt = <50000>; + qcom,rx-device = <&wcd_rx>; + qcom,tx-device = <&wcd_tx>; + }; + chosen { stdout-path = "serial0:115200n8"; }; @@ -631,27 +650,6 @@ &slpi { firmware-name = "qcom/sm8250/slpi.mbn"; }; -&soc { - wcd938x: codec { - compatible = "qcom,wcd9380-codec"; - #sound-dai-cells = <1>; - reset-gpios = <&tlmm 32 GPIO_ACTIVE_LOW>; - vdd-buck-supply = <&vreg_s4a_1p8>; - vdd-rxtx-supply = <&vreg_s4a_1p8>; - vdd-io-supply = <&vreg_s4a_1p8>; - vdd-mic-bias-supply = <&vreg_bob>; - qcom,micbias1-microvolt = <1800000>; - qcom,micbias2-microvolt = <1800000>; - qcom,micbias3-microvolt = <1800000>; - qcom,micbias4-microvolt = <1800000>; - qcom,mbhc-buttons-vthreshold-microvolt = <75000 150000 237000 500000 500000 500000 500000 500000>; - qcom,mbhc-headset-vthreshold-microvolt = <1700000>; - qcom,mbhc-headphone-vthreshold-microvolt = <50000>; - qcom,rx-device = <&wcd_rx>; - qcom,tx-device = <&wcd_tx>; - }; -}; - &sound { compatible = "qcom,sm8250-sndcard"; model = "SM8250-MTP-WCD9380-WSA8810-VA-DMIC"; From patchwork Mon Jan 2 10:50:38 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Johan Hovold X-Patchwork-Id: 638593 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 11382C46467 for ; Mon, 2 Jan 2023 10:51:42 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232611AbjABKvj (ORCPT ); Mon, 2 Jan 2023 05:51:39 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52458 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232657AbjABKvO (ORCPT ); Mon, 2 Jan 2023 05:51:14 -0500 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5404962E2; Mon, 2 Jan 2023 02:50:54 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id D7047B80D07; Mon, 2 Jan 2023 10:50:52 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 82C12C433B3; Mon, 2 Jan 2023 10:50:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1672656651; bh=NnSjzogFraldpT+XgAkjYumPBRSVym0mp3juRqkdBpI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=R9XUZ6DlHPc+bBa0ForStYZhT5tJwdXf/wFRBVQ5wdWU+fYlbl5yISWRi5rxUKSBD M6jiVrGmjr3TIORGvzU+BHTsZLJdbWelF2azHeNme6dc0lY+SiV/6ner5FlG/VbY2L tR40DLeW4viM5CNAn22sOvh85Kp1DHUxk60kQsLD0Wq7GAB+SArbcXJhV8WJnE9PfD 8RX1ee7JEDXEhC5GswkxemVwGaDvZAbLTZLe4HcBligs7MzVWyPX9dGI3oeTqBCzeo nJCY7d+blk0TCw84twVzigMjo53JkEVAqDSP/lcxum4kUANFpeImylqiWmwnUfCC6Y NXdcD8B2XUWzg== Received: from johan by xi.lan with local (Exim 4.94.2) (envelope-from ) id 1pCIPM-000273-Jl; Mon, 02 Jan 2023 11:51:08 +0100 From: Johan Hovold To: Bjorn Andersson Cc: Andy Gross , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Srinivas Kandagatla , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Johan Hovold Subject: [PATCH 6/6] arm64: dts: qcom: sm8450-hdk: fix wcd938x codec node Date: Mon, 2 Jan 2023 11:50:38 +0100 Message-Id: <20230102105038.8074-7-johan+linaro@kernel.org> X-Mailer: git-send-email 2.37.4 In-Reply-To: <20230102105038.8074-1-johan+linaro@kernel.org> References: <20230102105038.8074-1-johan+linaro@kernel.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org The wcd938x codec is not a memory-mapped device and does not belong under the soc node. Move the node to the root node to avoid DT validation failures. Signed-off-by: Johan Hovold --- arch/arm64/boot/dts/qcom/sm8450-hdk.dts | 52 ++++++++++++------------- 1 file changed, 25 insertions(+), 27 deletions(-) diff --git a/arch/arm64/boot/dts/qcom/sm8450-hdk.dts b/arch/arm64/boot/dts/qcom/sm8450-hdk.dts index 4de3e1f1c39c..217b2c654745 100644 --- a/arch/arm64/boot/dts/qcom/sm8450-hdk.dts +++ b/arch/arm64/boot/dts/qcom/sm8450-hdk.dts @@ -17,6 +17,31 @@ aliases { serial0 = &uart7; }; + wcd938x: codec { + compatible = "qcom,wcd9380-codec"; + + pinctrl-names = "default"; + pinctrl-0 = <&wcd_default>; + + qcom,micbias1-microvolt = <1800000>; + qcom,micbias2-microvolt = <1800000>; + qcom,micbias3-microvolt = <1800000>; + qcom,micbias4-microvolt = <1800000>; + qcom,mbhc-buttons-vthreshold-microvolt = <75000 150000 237000 500000 500000 500000 500000 500000>; + qcom,mbhc-headset-vthreshold-microvolt = <1700000>; + qcom,mbhc-headphone-vthreshold-microvolt = <50000>; + qcom,rx-device = <&wcd_rx>; + qcom,tx-device = <&wcd_tx>; + + reset-gpios = <&tlmm 43 GPIO_ACTIVE_LOW>; + #sound-dai-cells = <1>; + + vdd-buck-supply = <&vreg_s10b_1p8>; + vdd-rxtx-supply = <&vreg_s10b_1p8>; + vdd-io-supply = <&vreg_s10b_1p8>; + vdd-mic-bias-supply = <&vreg_bob>; + }; + chosen { stdout-path = "serial0:115200n8"; }; @@ -407,33 +432,6 @@ &sdhc_2 { status = "okay"; }; -&soc { - wcd938x: codec { - compatible = "qcom,wcd9380-codec"; - - pinctrl-names = "default"; - pinctrl-0 = <&wcd_default>; - - qcom,micbias1-microvolt = <1800000>; - qcom,micbias2-microvolt = <1800000>; - qcom,micbias3-microvolt = <1800000>; - qcom,micbias4-microvolt = <1800000>; - qcom,mbhc-buttons-vthreshold-microvolt = <75000 150000 237000 500000 500000 500000 500000 500000>; - qcom,mbhc-headset-vthreshold-microvolt = <1700000>; - qcom,mbhc-headphone-vthreshold-microvolt = <50000>; - qcom,rx-device = <&wcd_rx>; - qcom,tx-device = <&wcd_tx>; - - reset-gpios = <&tlmm 43 GPIO_ACTIVE_LOW>; - #sound-dai-cells = <1>; - - vdd-buck-supply = <&vreg_s10b_1p8>; - vdd-rxtx-supply = <&vreg_s10b_1p8>; - vdd-io-supply = <&vreg_s10b_1p8>; - vdd-mic-bias-supply = <&vreg_bob>; - }; -}; - &sound { compatible = "qcom,sm8450-sndcard"; model = "SM8450-HDK";