linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] arm64: dts: qcom: sdm845: add missing power-controller compatible
@ 2021-12-20 21:14 David Heidelberg
  2021-12-21  6:58 ` Manivannan Sadhasivam
  2022-02-01  5:19 ` (subset) " Bjorn Andersson
  0 siblings, 2 replies; 4+ messages in thread
From: David Heidelberg @ 2021-12-20 21:14 UTC (permalink / raw)
  To: Andy Gross, Bjorn Andersson, Rob Herring
  Cc: ~okias/devicetree, David Heidelberg, linux-arm-msm, devicetree,
	linux-kernel

dt-schema expect to have fallback compatible, which is now in-place.

Fixes warning generated by `make qcom/sdm845-oneplus-fajita.dtb`:
arch/arm64/boot/dts/qcom/sdm845-oneplus-fajita.dt.yaml: power-controller@c300000: compatible: ['qcom,sdm845-aoss-qmp'] is too short
        From schema: Documentation/devicetree/bindings/soc/qcom/qcom,aoss-qmp.yaml

Signed-off-by: David Heidelberg <david@ixit.cz>
---
 arch/arm64/boot/dts/qcom/sdm845.dtsi | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm64/boot/dts/qcom/sdm845.dtsi b/arch/arm64/boot/dts/qcom/sdm845.dtsi
index 92ab4513a08b..dbdb4243499c 100644
--- a/arch/arm64/boot/dts/qcom/sdm845.dtsi
+++ b/arch/arm64/boot/dts/qcom/sdm845.dtsi
@@ -4619,7 +4619,7 @@ aoss_reset: reset-controller@c2a0000 {
 		};
 
 		aoss_qmp: power-controller@c300000 {
-			compatible = "qcom,sdm845-aoss-qmp";
+			compatible = "qcom,sdm845-aoss-qmp", "qcom,aoss-qmp";
 			reg = <0 0x0c300000 0 0x100000>;
 			interrupts = <GIC_SPI 389 IRQ_TYPE_EDGE_RISING>;
 			mboxes = <&apss_shared 0>;
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] arm64: dts: qcom: sdm845: add missing power-controller compatible
  2021-12-20 21:14 [PATCH] arm64: dts: qcom: sdm845: add missing power-controller compatible David Heidelberg
@ 2021-12-21  6:58 ` Manivannan Sadhasivam
  2021-12-21  8:46   ` David Heidelberg
  2022-02-01  5:19 ` (subset) " Bjorn Andersson
  1 sibling, 1 reply; 4+ messages in thread
From: Manivannan Sadhasivam @ 2021-12-21  6:58 UTC (permalink / raw)
  To: David Heidelberg
  Cc: Andy Gross, Bjorn Andersson, Rob Herring, ~okias/devicetree,
	linux-arm-msm, devicetree, linux-kernel

On Mon, Dec 20, 2021 at 10:14:43PM +0100, David Heidelberg wrote:
> dt-schema expect to have fallback compatible, which is now in-place.
> 
> Fixes warning generated by `make qcom/sdm845-oneplus-fajita.dtb`:
> arch/arm64/boot/dts/qcom/sdm845-oneplus-fajita.dt.yaml: power-controller@c300000: compatible: ['qcom,sdm845-aoss-qmp'] is too short
>         From schema: Documentation/devicetree/bindings/soc/qcom/qcom,aoss-qmp.yaml
> 
> Signed-off-by: David Heidelberg <david@ixit.cz>
> ---
>  arch/arm64/boot/dts/qcom/sdm845.dtsi | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/arch/arm64/boot/dts/qcom/sdm845.dtsi b/arch/arm64/boot/dts/qcom/sdm845.dtsi
> index 92ab4513a08b..dbdb4243499c 100644
> --- a/arch/arm64/boot/dts/qcom/sdm845.dtsi
> +++ b/arch/arm64/boot/dts/qcom/sdm845.dtsi
> @@ -4619,7 +4619,7 @@ aoss_reset: reset-controller@c2a0000 {
>  		};
>  
>  		aoss_qmp: power-controller@c300000 {
> -			compatible = "qcom,sdm845-aoss-qmp";
> +			compatible = "qcom,sdm845-aoss-qmp", "qcom,aoss-qmp";

"qcom,sdm845-aoss-qmp" compatible is supported by the driver. So ideally we
don't need a fallback here.

Is this something for DT backwards compatibility?

Thanks,
Mani

>  			reg = <0 0x0c300000 0 0x100000>;
>  			interrupts = <GIC_SPI 389 IRQ_TYPE_EDGE_RISING>;
>  			mboxes = <&apss_shared 0>;
> -- 
> 2.34.1
> 

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] arm64: dts: qcom: sdm845: add missing power-controller compatible
  2021-12-21  6:58 ` Manivannan Sadhasivam
@ 2021-12-21  8:46   ` David Heidelberg
  0 siblings, 0 replies; 4+ messages in thread
From: David Heidelberg @ 2021-12-21  8:46 UTC (permalink / raw)
  To: Manivannan Sadhasivam
  Cc: Andy Gross, Bjorn Andersson, Rob Herring, ~okias/devicetree,
	linux-arm-msm, devicetree, linux-kernel

It's more about how documentation is written. Documentation expect "specific compatible", "generic compatible" in that order. Of course it can be changed to allow also  only specific compatible.

Also this syntax ensure that older kernel (without implemented device compatible/support) will try to work when new dts is used. Kernel can fallback to generic one compatible and code and device will still work, if the driver is generic enough to provide at least some basic support without knowing which exact device is handled.

If I missed some reason to use it, I guess Rob will correct me :)

David


-------- Původní zpráva --------
Odesílatel: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Odesláno: 21. prosince 2021 6:58:45 UTC
Komu: David Heidelberg <david@ixit.cz>
Kopie: Andy Gross <agross@kernel.org>, Bjorn Andersson <bjorn.andersson@linaro.org>, Rob Herring <robh+dt@kernel.org>, ~okias/devicetree@lists.sr.ht, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org
Předmět: Re: [PATCH] arm64: dts: qcom: sdm845: add missing power-controller compatible

On Mon, Dec 20, 2021 at 10:14:43PM +0100, David Heidelberg wrote:
> dt-schema expect to have fallback compatible, which is now in-place.
> 
> Fixes warning generated by `make qcom/sdm845-oneplus-fajita.dtb`:
> arch/arm64/boot/dts/qcom/sdm845-oneplus-fajita.dt.yaml: power-controller@c300000: compatible: ['qcom,sdm845-aoss-qmp'] is too short
>         From schema: Documentation/devicetree/bindings/soc/qcom/qcom,aoss-qmp.yaml
> 
> Signed-off-by: David Heidelberg <david@ixit.cz>
> ---
>  arch/arm64/boot/dts/qcom/sdm845.dtsi | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/arch/arm64/boot/dts/qcom/sdm845.dtsi b/arch/arm64/boot/dts/qcom/sdm845.dtsi
> index 92ab4513a08b..dbdb4243499c 100644
> --- a/arch/arm64/boot/dts/qcom/sdm845.dtsi
> +++ b/arch/arm64/boot/dts/qcom/sdm845.dtsi
> @@ -4619,7 +4619,7 @@ aoss_reset: reset-controller@c2a0000 {
>  		};
>  
>  		aoss_qmp: power-controller@c300000 {
> -			compatible = "qcom,sdm845-aoss-qmp";
> +			compatible = "qcom,sdm845-aoss-qmp", "qcom,aoss-qmp";

"qcom,sdm845-aoss-qmp" compatible is supported by the driver. So ideally we
don't need a fallback here.

Is this something for DT backwards compatibility?

Thanks,
Mani

>  			reg = <0 0x0c300000 0 0x100000>;
>  			interrupts = <GIC_SPI 389 IRQ_TYPE_EDGE_RISING>;
>  			mboxes = <&apss_shared 0>;
> -- 
> 2.34.1
> 

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: (subset) [PATCH] arm64: dts: qcom: sdm845: add missing power-controller compatible
  2021-12-20 21:14 [PATCH] arm64: dts: qcom: sdm845: add missing power-controller compatible David Heidelberg
  2021-12-21  6:58 ` Manivannan Sadhasivam
@ 2022-02-01  5:19 ` Bjorn Andersson
  1 sibling, 0 replies; 4+ messages in thread
From: Bjorn Andersson @ 2022-02-01  5:19 UTC (permalink / raw)
  To: Rob Herring, Andy Gross, David Heidelberg
  Cc: devicetree, ~okias/devicetree, linux-arm-msm, linux-kernel

On Mon, 20 Dec 2021 22:14:43 +0100, David Heidelberg wrote:
> dt-schema expect to have fallback compatible, which is now in-place.
> 
> Fixes warning generated by `make qcom/sdm845-oneplus-fajita.dtb`:
> arch/arm64/boot/dts/qcom/sdm845-oneplus-fajita.dt.yaml: power-controller@c300000: compatible: ['qcom,sdm845-aoss-qmp'] is too short
>         From schema: Documentation/devicetree/bindings/soc/qcom/qcom,aoss-qmp.yaml
> 
> 
> [...]

Applied, thanks!

[1/1] arm64: dts: qcom: sdm845: add missing power-controller compatible
      commit: 3b87b01d747386e0429996266c063d7700d9813e

Best regards,
-- 
Bjorn Andersson <bjorn.andersson@linaro.org>

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-02-01  5:20 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-12-20 21:14 [PATCH] arm64: dts: qcom: sdm845: add missing power-controller compatible David Heidelberg
2021-12-21  6:58 ` Manivannan Sadhasivam
2021-12-21  8:46   ` David Heidelberg
2022-02-01  5:19 ` (subset) " Bjorn Andersson

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).