From: Bjorn Andersson <andersson@kernel.org>
To: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Cc: Andy Gross <agross@kernel.org>,
Konrad Dybcio <konrad.dybcio@linaro.org>,
Rob Herring <robh+dt@kernel.org>,
Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/6] arm64: dts: qcom: sdm845: move WCD9340 codec to separate file
Date: Mon, 16 Jan 2023 21:56:31 -0600 [thread overview]
Message-ID: <20230117035631.cgi6fjdrpz5eppca@builder.lan> (raw)
In-Reply-To: <20230113162245.117324-2-krzysztof.kozlowski@linaro.org>
On Fri, Jan 13, 2023 at 05:22:41PM +0100, Krzysztof Kozlowski wrote:
> WCD9340 codec node is not a property of the SoC, but board. Move it to
> separate file and include it in the specific boards. On all others,
> keep the Slimbus node disabled as it is empty.
>
I think this seems like a reasonable idea. But without clearly
documenting your intentions/guidelines we will soon have
sdm845-display.dtsi, sdm845-pcie.dtsi etc.
So please start there.
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
> .../boot/dts/qcom/sdm845-audio-wcd9340.dtsi | 69 +++++++++++++++++++
> arch/arm64/boot/dts/qcom/sdm845-db845c.dts | 1 +
> .../qcom/sdm845-xiaomi-beryllium-common.dtsi | 1 +
> .../boot/dts/qcom/sdm845-xiaomi-polaris.dts | 1 +
> arch/arm64/boot/dts/qcom/sdm845.dtsi | 60 +---------------
> .../boot/dts/qcom/sdm850-lenovo-yoga-c630.dts | 1 +
> .../boot/dts/qcom/sdm850-samsung-w737.dts | 1 +
> 7 files changed, 75 insertions(+), 59 deletions(-)
> create mode 100644 arch/arm64/boot/dts/qcom/sdm845-audio-wcd9340.dtsi
>
> diff --git a/arch/arm64/boot/dts/qcom/sdm845-audio-wcd9340.dtsi b/arch/arm64/boot/dts/qcom/sdm845-audio-wcd9340.dtsi
> new file mode 100644
> index 000000000000..5bcce7d0d709
> --- /dev/null
> +++ b/arch/arm64/boot/dts/qcom/sdm845-audio-wcd9340.dtsi
Why does this include the substring "audio"?
Regards,
Bjorn
> @@ -0,0 +1,69 @@
> +// SPDX-License-Identifier: GPL-2.0
> +/*
> + * SDM845 SoC device tree source
> + *
> + * Copyright (c) 2018, The Linux Foundation. All rights reserved.
> + */
> +
> +&slim {
> + status = "okay";
> +
> + slim@1 {
> + reg = <1>;
> + #address-cells = <2>;
> + #size-cells = <0>;
> +
> + wcd9340_ifd: ifd@0,0 {
> + compatible = "slim217,250";
> + reg = <0 0>;
> + };
> +
> + wcd9340: codec@1,0 {
> + compatible = "slim217,250";
> + reg = <1 0>;
> + slim-ifc-dev = <&wcd9340_ifd>;
> +
> + #sound-dai-cells = <1>;
> +
> + interrupts-extended = <&tlmm 54 IRQ_TYPE_LEVEL_HIGH>;
> + interrupt-controller;
> + #interrupt-cells = <1>;
> +
> + #clock-cells = <0>;
> + clock-frequency = <9600000>;
> + clock-output-names = "mclk";
> + qcom,micbias1-microvolt = <1800000>;
> + qcom,micbias2-microvolt = <1800000>;
> + qcom,micbias3-microvolt = <1800000>;
> + qcom,micbias4-microvolt = <1800000>;
> +
> + #address-cells = <1>;
> + #size-cells = <1>;
> +
> + wcdgpio: gpio-controller@42 {
> + compatible = "qcom,wcd9340-gpio";
> + gpio-controller;
> + #gpio-cells = <2>;
> + reg = <0x42 0x2>;
> + };
> +
> + swm: swm@c85 {
> + compatible = "qcom,soundwire-v1.3.0";
> + reg = <0xc85 0x40>;
> + interrupts-extended = <&wcd9340 20>;
> +
> + qcom,dout-ports = <6>;
> + qcom,din-ports = <2>;
> + qcom,ports-sinterval-low = /bits/ 8 <0x07 0x1f 0x3f 0x7 0x1f 0x3f 0x0f 0x0f>;
> + qcom,ports-offset1 = /bits/ 8 <0x01 0x02 0x0c 0x6 0x12 0x0d 0x07 0x0a>;
> + qcom,ports-offset2 = /bits/ 8 <0x00 0x00 0x1f 0x00 0x00 0x1f 0x00 0x00>;
> +
> + #sound-dai-cells = <1>;
> + clocks = <&wcd9340>;
> + clock-names = "iface";
> + #address-cells = <2>;
> + #size-cells = <0>;
> + };
> + };
> + };
> +};
> diff --git a/arch/arm64/boot/dts/qcom/sdm845-db845c.dts b/arch/arm64/boot/dts/qcom/sdm845-db845c.dts
> index 6b355589edb3..3726465acbde 100644
> --- a/arch/arm64/boot/dts/qcom/sdm845-db845c.dts
> +++ b/arch/arm64/boot/dts/qcom/sdm845-db845c.dts
> @@ -11,6 +11,7 @@
> #include <dt-bindings/sound/qcom,q6afe.h>
> #include <dt-bindings/sound/qcom,q6asm.h>
> #include "sdm845.dtsi"
> +#include "sdm845-audio-wcd9340.dtsi"
> #include "pm8998.dtsi"
> #include "pmi8998.dtsi"
>
> diff --git a/arch/arm64/boot/dts/qcom/sdm845-xiaomi-beryllium-common.dtsi b/arch/arm64/boot/dts/qcom/sdm845-xiaomi-beryllium-common.dtsi
> index 64de4ed9b0c8..e530a676b250 100644
> --- a/arch/arm64/boot/dts/qcom/sdm845-xiaomi-beryllium-common.dtsi
> +++ b/arch/arm64/boot/dts/qcom/sdm845-xiaomi-beryllium-common.dtsi
> @@ -7,6 +7,7 @@
> #include <dt-bindings/sound/qcom,q6afe.h>
> #include <dt-bindings/sound/qcom,q6asm.h>
> #include "sdm845.dtsi"
> +#include "sdm845-audio-wcd9340.dtsi"
> #include "pm8998.dtsi"
> #include "pmi8998.dtsi"
>
> diff --git a/arch/arm64/boot/dts/qcom/sdm845-xiaomi-polaris.dts b/arch/arm64/boot/dts/qcom/sdm845-xiaomi-polaris.dts
> index a80c3dd9a2da..f81619c8a3ba 100644
> --- a/arch/arm64/boot/dts/qcom/sdm845-xiaomi-polaris.dts
> +++ b/arch/arm64/boot/dts/qcom/sdm845-xiaomi-polaris.dts
> @@ -13,6 +13,7 @@
> #include <dt-bindings/sound/qcom,q6afe.h>
> #include <dt-bindings/sound/qcom,q6asm.h>
> #include "sdm845.dtsi"
> +#include "sdm845-audio-wcd9340.dtsi"
> #include "pm8998.dtsi"
> #include "pmi8998.dtsi"
> #include "pm8005.dtsi"
> diff --git a/arch/arm64/boot/dts/qcom/sdm845.dtsi b/arch/arm64/boot/dts/qcom/sdm845.dtsi
> index 4c256431280a..f9b1d7a60fd6 100644
> --- a/arch/arm64/boot/dts/qcom/sdm845.dtsi
> +++ b/arch/arm64/boot/dts/qcom/sdm845.dtsi
> @@ -3831,65 +3831,7 @@ slim: slim-ngd@171c0000 {
> iommus = <&apps_smmu 0x1806 0x0>;
> #address-cells = <1>;
> #size-cells = <0>;
> -
> - slim@1 {
> - reg = <1>;
> - #address-cells = <2>;
> - #size-cells = <0>;
> -
> - wcd9340_ifd: ifd@0,0 {
> - compatible = "slim217,250";
> - reg = <0 0>;
> - };
> -
> - wcd9340: codec@1,0 {
> - compatible = "slim217,250";
> - reg = <1 0>;
> - slim-ifc-dev = <&wcd9340_ifd>;
> -
> - #sound-dai-cells = <1>;
> -
> - interrupts-extended = <&tlmm 54 IRQ_TYPE_LEVEL_HIGH>;
> - interrupt-controller;
> - #interrupt-cells = <1>;
> -
> - #clock-cells = <0>;
> - clock-frequency = <9600000>;
> - clock-output-names = "mclk";
> - qcom,micbias1-microvolt = <1800000>;
> - qcom,micbias2-microvolt = <1800000>;
> - qcom,micbias3-microvolt = <1800000>;
> - qcom,micbias4-microvolt = <1800000>;
> -
> - #address-cells = <1>;
> - #size-cells = <1>;
> -
> - wcdgpio: gpio-controller@42 {
> - compatible = "qcom,wcd9340-gpio";
> - gpio-controller;
> - #gpio-cells = <2>;
> - reg = <0x42 0x2>;
> - };
> -
> - swm: swm@c85 {
> - compatible = "qcom,soundwire-v1.3.0";
> - reg = <0xc85 0x40>;
> - interrupts-extended = <&wcd9340 20>;
> -
> - qcom,dout-ports = <6>;
> - qcom,din-ports = <2>;
> - qcom,ports-sinterval-low = /bits/ 8 <0x07 0x1f 0x3f 0x7 0x1f 0x3f 0x0f 0x0f>;
> - qcom,ports-offset1 = /bits/ 8 <0x01 0x02 0x0c 0x6 0x12 0x0d 0x07 0x0a>;
> - qcom,ports-offset2 = /bits/ 8 <0x00 0x00 0x1f 0x00 0x00 0x1f 0x00 0x00>;
> -
> - #sound-dai-cells = <1>;
> - clocks = <&wcd9340>;
> - clock-names = "iface";
> - #address-cells = <2>;
> - #size-cells = <0>;
> - };
> - };
> - };
> + status = "disabled";
> };
>
> lmh_cluster1: lmh@17d70800 {
> diff --git a/arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts b/arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts
> index d9581f4440b3..5586c95aa1ff 100644
> --- a/arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts
> +++ b/arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts
> @@ -13,6 +13,7 @@
> #include <dt-bindings/sound/qcom,q6afe.h>
> #include <dt-bindings/sound/qcom,q6asm.h>
> #include "sdm850.dtsi"
> +#include "sdm845-audio-wcd9340.dtsi"
> #include "pm8998.dtsi"
>
> /*
> diff --git a/arch/arm64/boot/dts/qcom/sdm850-samsung-w737.dts b/arch/arm64/boot/dts/qcom/sdm850-samsung-w737.dts
> index 6730804f4e3e..40223704a2c7 100644
> --- a/arch/arm64/boot/dts/qcom/sdm850-samsung-w737.dts
> +++ b/arch/arm64/boot/dts/qcom/sdm850-samsung-w737.dts
> @@ -14,6 +14,7 @@
> #include <dt-bindings/sound/qcom,q6afe.h>
> #include <dt-bindings/sound/qcom,q6asm.h>
> #include "sdm850.dtsi"
> +#include "sdm845-audio-wcd9340.dtsi"
> #include "pm8998.dtsi"
>
> /*
> --
> 2.34.1
>
next prev parent reply other threads:[~2023-01-17 3:56 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-01-13 16:22 [PATCH 1/6] arm64: dts: qcom: sm8250: drop unused clock-frequency from rx-macro Krzysztof Kozlowski
2023-01-13 16:22 ` [PATCH 2/6] arm64: dts: qcom: sdm845: move WCD9340 codec to separate file Krzysztof Kozlowski
2023-01-14 20:33 ` Konrad Dybcio
2023-01-15 11:21 ` Krzysztof Kozlowski
2023-01-16 5:55 ` Dmitry Baryshkov
2023-01-16 7:58 ` Krzysztof Kozlowski
2023-01-16 8:56 ` Konrad Dybcio
2023-01-16 8:54 ` Konrad Dybcio
2023-01-17 3:56 ` Bjorn Andersson [this message]
2023-01-17 7:51 ` Krzysztof Kozlowski
2023-01-13 16:22 ` [PATCH 3/6] arm64: dts: qcom: sdm845-audio-wcd9340: commonize pinctrl Krzysztof Kozlowski
2023-01-14 20:33 ` Konrad Dybcio
2023-01-13 16:22 ` [PATCH 4/6] arm64: dts: qcom: sdm845-audio-wcd9340: commonize clocks Krzysztof Kozlowski
2023-01-14 20:34 ` Konrad Dybcio
2023-01-13 16:22 ` [PATCH 5/6] arm64: dts: qcom: sc8280xp: drop bogus clock-controller property Krzysztof Kozlowski
2023-01-13 16:22 ` [PATCH 6/6] arm64: dts: qcom: sc8280xp: drop unused properties from tx-macro Krzysztof Kozlowski
2023-01-14 20:34 ` Konrad Dybcio
2023-01-14 20:32 ` [PATCH 1/6] arm64: dts: qcom: sm8250: drop unused clock-frequency from rx-macro Konrad Dybcio
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230117035631.cgi6fjdrpz5eppca@builder.lan \
--to=andersson@kernel.org \
--cc=agross@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=konrad.dybcio@linaro.org \
--cc=krzysztof.kozlowski+dt@linaro.org \
--cc=krzysztof.kozlowski@linaro.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=robh+dt@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).