2023-10-06 04:54:05

by Devi Priya

[permalink] [raw]
Subject: [PATCH 0/4] Enable pwm support for IPQ5332 & IPQ9574 SoCs

Enable pwm support for IPQ5332 & IPQ9574 SoCs and document the
pwm compatibles.
While at it, use qcom,ipq6018-pwm as the fallback compatible and extend the
simple-mfd support for ipq5332 & ipq9574 targets.

This series depends on the below series which adds support
for the PWM driver on IPQ targets:
https://lore.kernel.org/linux-arm-msm/[email protected]/

Devi Priya (4):
dt-bindings: pwm: Document the pwm compatible for ipq5332 & ipq9574
dt-bindings: mfd: qcom,tcsr: Extend simple-mfd & pwm support for IPQ
targets
arm64: dts: qcom: ipq9574: Add pwm support
arm64: dts: qcom: ipq5332: Add pwm support

.../devicetree/bindings/mfd/qcom,tcsr.yaml | 9 ++++++---
.../devicetree/bindings/pwm/qcom,ipq6018-pwm.yaml | 9 ++++++++-
arch/arm64/boot/dts/qcom/ipq5332.dtsi | 15 ++++++++++++++-
arch/arm64/boot/dts/qcom/ipq9574-rdp418.dts | 12 ++++++++++++
arch/arm64/boot/dts/qcom/ipq9574.dtsi | 15 ++++++++++++++-
5 files changed, 54 insertions(+), 6 deletions(-)

--
2.34.1


2023-10-06 04:54:11

by Devi Priya

[permalink] [raw]
Subject: [PATCH 1/4] dt-bindings: pwm: Document the pwm compatible for ipq5332 & ipq9574

Use ipq6018 as the fallback for ipq5332 & ipq9574 and document its compatibles.

Signed-off-by: Devi Priya <[email protected]>
---
.../devicetree/bindings/pwm/qcom,ipq6018-pwm.yaml | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/pwm/qcom,ipq6018-pwm.yaml b/Documentation/devicetree/bindings/pwm/qcom,ipq6018-pwm.yaml
index 6d0d7ed271f7..8335c2952c2a 100644
--- a/Documentation/devicetree/bindings/pwm/qcom,ipq6018-pwm.yaml
+++ b/Documentation/devicetree/bindings/pwm/qcom,ipq6018-pwm.yaml
@@ -11,7 +11,14 @@ maintainers:

properties:
compatible:
- const: qcom,ipq6018-pwm
+ oneOf:
+ - items:
+ - enum:
+ - qcom,ipq5332-pwm
+ - qcom,ipq9574-pwm
+ - const: qcom,ipq6018-pwm
+ - enum:
+ - qcom,ipq6018-pwm

reg:
description: Offset of PWM register in the TCSR block.
--
2.34.1

2023-10-06 04:54:14

by Devi Priya

[permalink] [raw]
Subject: [PATCH 3/4] arm64: dts: qcom: ipq9574: Add pwm support

The PWM is in the TCSR area. Make tcsr "simple-mfd" compatible
and add pwm as a child of tcsr.
Also, Enable pwm support in RDP418 of IPQ9574 SoC.

Signed-off-by: Devi Priya <[email protected]>
---
arch/arm64/boot/dts/qcom/ipq9574-rdp418.dts | 12 ++++++++++++
arch/arm64/boot/dts/qcom/ipq9574.dtsi | 15 ++++++++++++++-
2 files changed, 26 insertions(+), 1 deletion(-)

diff --git a/arch/arm64/boot/dts/qcom/ipq9574-rdp418.dts b/arch/arm64/boot/dts/qcom/ipq9574-rdp418.dts
index 2b093e02637b..d275c98b4df7 100644
--- a/arch/arm64/boot/dts/qcom/ipq9574-rdp418.dts
+++ b/arch/arm64/boot/dts/qcom/ipq9574-rdp418.dts
@@ -43,6 +43,12 @@ &blsp1_uart2 {
status = "okay";
};

+&pwm {
+ pinctrl-0 = <&pwm_pins>;
+ pinctrl-names = "default";
+ status = "okay";
+};
+
&rpm_requests {
regulators {
compatible = "qcom,rpm-mp5496-regulators";
@@ -79,6 +85,12 @@ &sleep_clk {
};

&tlmm {
+ pwm_pins: pwm-state {
+ pins = "gpio57";
+ function = "pwm";
+ drive-strength = <8>;
+ };
+
sdc_default_state: sdc-default-state {
clk-pins {
pins = "gpio5";
diff --git a/arch/arm64/boot/dts/qcom/ipq9574.dtsi b/arch/arm64/boot/dts/qcom/ipq9574.dtsi
index 8a72ad4afd03..5465254fbdde 100644
--- a/arch/arm64/boot/dts/qcom/ipq9574.dtsi
+++ b/arch/arm64/boot/dts/qcom/ipq9574.dtsi
@@ -296,8 +296,21 @@ tcsr_mutex: hwlock@1905000 {
};

tcsr: syscon@1937000 {
- compatible = "qcom,tcsr-ipq9574", "syscon";
+ compatible = "qcom,tcsr-ipq9574", "syscon", "simple-mfd";
reg = <0x01937000 0x21000>;
+ ranges = <0x0 0x01937000 0x21000>;
+ #address-cells = <1>;
+ #size-cells = <1>;
+
+ pwm: pwm@a010 {
+ compatible = "qcom,ipq9574-pwm", "qcom,ipq6018-pwm";
+ reg = <0xa010 0x20>;
+ clocks = <&gcc GCC_ADSS_PWM_CLK>;
+ assigned-clocks = <&gcc GCC_ADSS_PWM_CLK>;
+ assigned-clock-rates = <100000000>;
+ #pwm-cells = <2>;
+ status = "disabled";
+ };
};

sdhc_1: mmc@7804000 {
--
2.34.1

2023-10-06 04:54:30

by Devi Priya

[permalink] [raw]
Subject: [PATCH 4/4] arm64: dts: qcom: ipq5332: Add pwm support

Add PWM support in ipq5332. The PWM is in the TCSR area. Make tcsr
"simple-mfd" compatible, and add pwm as a child of &tcsr.

Signed-off-by: Devi Priya <[email protected]>
---
arch/arm64/boot/dts/qcom/ipq5332.dtsi | 15 ++++++++++++++-
1 file changed, 14 insertions(+), 1 deletion(-)

diff --git a/arch/arm64/boot/dts/qcom/ipq5332.dtsi b/arch/arm64/boot/dts/qcom/ipq5332.dtsi
index d3fef2f80a81..7620f1ccd324 100644
--- a/arch/arm64/boot/dts/qcom/ipq5332.dtsi
+++ b/arch/arm64/boot/dts/qcom/ipq5332.dtsi
@@ -210,8 +210,21 @@ tcsr_mutex: hwlock@1905000 {
};

tcsr: syscon@1937000 {
- compatible = "qcom,tcsr-ipq5332", "syscon";
+ compatible = "qcom,tcsr-ipq5332", "syscon", "simple-mfd";
reg = <0x01937000 0x21000>;
+ ranges = <0x0 0x01937000 0x21000>;
+ #address-cells = <1>;
+ #size-cells = <1>;
+
+ pwm: pwm@a010 {
+ compatible = "qcom,ipq5332-pwm", "qcom,ipq6018-pwm";
+ reg = <0xa010 0x20>;
+ clocks = <&gcc GCC_ADSS_PWM_CLK>;
+ assigned-clocks = <&gcc GCC_ADSS_PWM_CLK>;
+ assigned-clock-rates = <100000000>;
+ #pwm-cells = <2>;
+ status = "disabled";
+ };
};

sdhc: mmc@7804000 {
--
2.34.1

2023-10-06 04:55:06

by Devi Priya

[permalink] [raw]
Subject: [PATCH 2/4] dt-bindings: mfd: qcom,tcsr: Extend simple-mfd & pwm support for IPQ targets

Extend simple-mfd and pwm support for IPQ5332 & IPQ9574 SoCs.

Signed-off-by: Devi Priya <[email protected]>
---
Documentation/devicetree/bindings/mfd/qcom,tcsr.yaml | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/Documentation/devicetree/bindings/mfd/qcom,tcsr.yaml b/Documentation/devicetree/bindings/mfd/qcom,tcsr.yaml
index f836b973e382..1e1e25df4ee3 100644
--- a/Documentation/devicetree/bindings/mfd/qcom,tcsr.yaml
+++ b/Documentation/devicetree/bindings/mfd/qcom,tcsr.yaml
@@ -33,10 +33,8 @@ properties:
- qcom,sm8450-tcsr
- qcom,tcsr-apq8064
- qcom,tcsr-apq8084
- - qcom,tcsr-ipq5332
- qcom,tcsr-ipq8064
- qcom,tcsr-ipq8074
- - qcom,tcsr-ipq9574
- qcom,tcsr-mdm9615
- qcom,tcsr-msm8226
- qcom,tcsr-msm8660
@@ -47,7 +45,10 @@ properties:
- qcom,tcsr-msm8996
- const: syscon
- items:
- - const: qcom,tcsr-ipq6018
+ - enum:
+ - qcom,tcsr-ipq5332
+ - qcom,tcsr-ipq6018
+ - qcom,tcsr-ipq9574
- const: syscon
- const: simple-mfd

@@ -78,7 +79,9 @@ allOf:
compatible:
contains:
enum:
+ - qcom,tcsr-ipq5332
- qcom,tcsr-ipq6018
+ - qcom,tcsr-ipq9574
then:
patternProperties:
"pwm@[a-f0-9]+$": false
--
2.34.1

2023-10-06 06:08:58

by Krzysztof Kozlowski

[permalink] [raw]
Subject: Re: [PATCH 1/4] dt-bindings: pwm: Document the pwm compatible for ipq5332 & ipq9574

On 06/10/2023 06:53, Devi Priya wrote:
> Use ipq6018 as the fallback for ipq5332 & ipq9574 and document its compatibles.
>
> Signed-off-by: Devi Priya <[email protected]>
> ---
> .../devicetree/bindings/pwm/qcom,ipq6018-pwm.yaml | 9 ++++++++-
> 1 file changed, 8 insertions(+), 1 deletion(-)
>

Reviewed-by: Krzysztof Kozlowski <[email protected]>

Best regards,
Krzysztof

2023-10-06 06:09:32

by Krzysztof Kozlowski

[permalink] [raw]
Subject: Re: [PATCH 2/4] dt-bindings: mfd: qcom,tcsr: Extend simple-mfd & pwm support for IPQ targets

On 06/10/2023 06:53, Devi Priya wrote:
> Extend simple-mfd and pwm support for IPQ5332 & IPQ9574 SoCs.
>
> Signed-off-by: Devi Priya <[email protected]>
> ---


Reviewed-by: Krzysztof Kozlowski <[email protected]>

Best regards,
Krzysztof

2023-10-06 06:10:05

by Krzysztof Kozlowski

[permalink] [raw]
Subject: Re: [PATCH 3/4] arm64: dts: qcom: ipq9574: Add pwm support

On 06/10/2023 06:53, Devi Priya wrote:
> The PWM is in the TCSR area. Make tcsr "simple-mfd" compatible
> and add pwm as a child of tcsr.
> Also, Enable pwm support in RDP418 of IPQ9574 SoC.
>
> Signed-off-by: Devi Priya <[email protected]>
> ---


Reviewed-by: Krzysztof Kozlowski <[email protected]>

Best regards,
Krzysztof

2023-10-06 06:10:24

by Krzysztof Kozlowski

[permalink] [raw]
Subject: Re: [PATCH 4/4] arm64: dts: qcom: ipq5332: Add pwm support

On 06/10/2023 06:53, Devi Priya wrote:
> Add PWM support in ipq5332. The PWM is in the TCSR area. Make tcsr
> "simple-mfd" compatible, and add pwm as a child of &tcsr.
>
> Signed-off-by: Devi Priya <[email protected]>
> ---
> arch/arm64/boot/dts/qcom/ipq5332.dtsi | 15 ++++++++++++++-
> 1 file changed, 14 insertions(+), 1 deletion(-)

Reviewed-by: Krzysztof Kozlowski <[email protected]>

Best regards,
Krzysztof

2023-10-12 10:08:02

by Lee Jones

[permalink] [raw]
Subject: Re: (subset) [PATCH 2/4] dt-bindings: mfd: qcom,tcsr: Extend simple-mfd & pwm support for IPQ targets

On Fri, 06 Oct 2023 10:23:15 +0530, Devi Priya wrote:
> Extend simple-mfd and pwm support for IPQ5332 & IPQ9574 SoCs.
>
>

Applied, thanks!

[2/4] dt-bindings: mfd: qcom,tcsr: Extend simple-mfd & pwm support for IPQ targets
commit: abbb729360a50ce949de94a983cb56b15b82018e

--
Lee Jones [李琼斯]

2023-10-23 09:53:29

by Lee Jones

[permalink] [raw]
Subject: Re: (subset) [PATCH 2/4] dt-bindings: mfd: qcom,tcsr: Extend simple-mfd & pwm support for IPQ targets

On Thu, 12 Oct 2023, Lee Jones wrote:

> On Fri, 06 Oct 2023 10:23:15 +0530, Devi Priya wrote:
> > Extend simple-mfd and pwm support for IPQ5332 & IPQ9574 SoCs.
> >
> >
>
> Applied, thanks!
>
> [2/4] dt-bindings: mfd: qcom,tcsr: Extend simple-mfd & pwm support for IPQ targets
> commit: abbb729360a50ce949de94a983cb56b15b82018e

Also unapplied, since it seems to depend on:

dt-bindings: mfd: qcom,tcsr: Add simple-mfd support for IPQ6018

--
Lee Jones [李琼斯]

2024-01-28 02:46:39

by Bjorn Andersson

[permalink] [raw]
Subject: Re: [PATCH 0/4] Enable pwm support for IPQ5332 & IPQ9574 SoCs

On Fri, Oct 06, 2023 at 10:23:13AM +0530, Devi Priya wrote:
> Enable pwm support for IPQ5332 & IPQ9574 SoCs and document the
> pwm compatibles.
> While at it, use qcom,ipq6018-pwm as the fallback compatible and extend the
> simple-mfd support for ipq5332 & ipq9574 targets.
>
> This series depends on the below series which adds support
> for the PWM driver on IPQ targets:
> https://lore.kernel.org/linux-arm-msm/[email protected]/

I've kept this series in my inbox, hoping that you would work out the DT
bindings with the maintainers. Dropping them now, please resend the DTS
patches once the bindings are in order.

Thanks,
Bjorn

>
> Devi Priya (4):
> dt-bindings: pwm: Document the pwm compatible for ipq5332 & ipq9574
> dt-bindings: mfd: qcom,tcsr: Extend simple-mfd & pwm support for IPQ
> targets
> arm64: dts: qcom: ipq9574: Add pwm support
> arm64: dts: qcom: ipq5332: Add pwm support
>
> .../devicetree/bindings/mfd/qcom,tcsr.yaml | 9 ++++++---
> .../devicetree/bindings/pwm/qcom,ipq6018-pwm.yaml | 9 ++++++++-
> arch/arm64/boot/dts/qcom/ipq5332.dtsi | 15 ++++++++++++++-
> arch/arm64/boot/dts/qcom/ipq9574-rdp418.dts | 12 ++++++++++++
> arch/arm64/boot/dts/qcom/ipq9574.dtsi | 15 ++++++++++++++-
> 5 files changed, 54 insertions(+), 6 deletions(-)
>
> --
> 2.34.1
>