diff mbox series

[3/3] ARM: dts: qcom: msm8974: add interrupt properties

Message ID 20181229114755.8711-4-masneyb@onstation.org
State New
Headers show
Series qcom: spmi: add support for hierarchical IRQ chip | expand

Commit Message

Brian Masney Dec. 29, 2018, 11:47 a.m. UTC
Add interrupt properties now that spmi-gpio is a proper hierarchical IRQ
chip.

Signed-off-by: Brian Masney <masneyb@onstation.org>
---
 arch/arm/boot/dts/qcom-pm8941.dtsi | 3 +++
 1 file changed, 3 insertions(+)

Comments

Stephen Boyd Jan. 4, 2019, 12:29 a.m. UTC | #1
Quoting Brian Masney (2018-12-29 03:47:55)
> Add interrupt properties now that spmi-gpio is a proper hierarchical IRQ
> chip.
> 
> Signed-off-by: Brian Masney <masneyb@onstation.org>
> ---
>  arch/arm/boot/dts/qcom-pm8941.dtsi | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/arch/arm/boot/dts/qcom-pm8941.dtsi b/arch/arm/boot/dts/qcom-pm8941.dtsi
> index 9a91b758f7aa..d0b7f0eff288 100644
> --- a/arch/arm/boot/dts/qcom-pm8941.dtsi
> +++ b/arch/arm/boot/dts/qcom-pm8941.dtsi
> @@ -65,6 +65,9 @@
>                         gpio-controller;
>                         gpio-ranges = <&pm8941_gpios 0 0 36>;
>                         #gpio-cells = <2>;
> +                       interrupt-parent = <&spmi_bus>;
> +                       interrupt-controller;
> +                       #interrupt-cells = <4>;
>                         interrupts = <0 0xc0 0 IRQ_TYPE_NONE>,
>                                      <0 0xc1 0 IRQ_TYPE_NONE>,
>                                      <0 0xc2 0 IRQ_TYPE_NONE>,

Shouldn't we remove the interrupts property here then? Although we use
it to count the number of gpios that are supported so I guess we'll have
to specify it all the time now just to know how many pins there are.
Alternatively we change the driver to know about all the different
compatibles and use the right number of gpios for each compatible string
that we see.
diff mbox series

Patch

diff --git a/arch/arm/boot/dts/qcom-pm8941.dtsi b/arch/arm/boot/dts/qcom-pm8941.dtsi
index 9a91b758f7aa..d0b7f0eff288 100644
--- a/arch/arm/boot/dts/qcom-pm8941.dtsi
+++ b/arch/arm/boot/dts/qcom-pm8941.dtsi
@@ -65,6 +65,9 @@ 
 			gpio-controller;
 			gpio-ranges = <&pm8941_gpios 0 0 36>;
 			#gpio-cells = <2>;
+			interrupt-parent = <&spmi_bus>;
+			interrupt-controller;
+			#interrupt-cells = <4>;
 			interrupts = <0 0xc0 0 IRQ_TYPE_NONE>,
 				     <0 0xc1 0 IRQ_TYPE_NONE>,
 				     <0 0xc2 0 IRQ_TYPE_NONE>,