diff mbox series

ARM: dts: r8a7792: blanche: Add IIC3 and DA9063 PMIC node

Message ID 20190304195958.8383-1-marek.vasut@gmail.com (mailing list archive)
State Mainlined, archived
Commit 72cd625c85e2681bad718b5218bf672d7fa5af80
Headers show
Series ARM: dts: r8a7792: blanche: Add IIC3 and DA9063 PMIC node | expand

Commit Message

Marek Vasut March 4, 2019, 7:59 p.m. UTC
From: Marek Vasut <marek.vasut+renesas@gmail.com>

Add IIC3 node to R8A7792 SoC device tree and a DA9063 PMIC node
to V2H Blanche board device tree.

Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
Cc: Geert Uytterhoeven <geert+renesas@glider.be>
Cc: Simon Horman <horms+renesas@verge.net.au>
Cc: linux-renesas-soc@vger.kernel.org
To: linux-arm-kernel@lists.infradead.org
---
NOTE: R8A7792 Blanche does not share the PMIC IRQ line with other PMICs,
      hence the regulator-quirk-rcar-gen2.c does not need a new entry.
---
 arch/arm/boot/dts/r8a7792-blanche.dts | 20 ++++++++++++++++++++
 arch/arm/boot/dts/r8a7792.dtsi        | 18 ++++++++++++++++++
 2 files changed, 38 insertions(+)

Comments

Simon Horman March 8, 2019, 1:38 p.m. UTC | #1
On Mon, Mar 04, 2019 at 08:59:58PM +0100, marek.vasut@gmail.com wrote:
> From: Marek Vasut <marek.vasut+renesas@gmail.com>
> 
> Add IIC3 node to R8A7792 SoC device tree and a DA9063 PMIC node
> to V2H Blanche board device tree.
> 
> Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
> Cc: Geert Uytterhoeven <geert+renesas@glider.be>
> Cc: Simon Horman <horms+renesas@verge.net.au>
> Cc: linux-renesas-soc@vger.kernel.org
> To: linux-arm-kernel@lists.infradead.org
> ---
> NOTE: R8A7792 Blanche does not share the PMIC IRQ line with other PMICs,
>       hence the regulator-quirk-rcar-gen2.c does not need a new entry.
> ---
>  arch/arm/boot/dts/r8a7792-blanche.dts | 20 ++++++++++++++++++++
>  arch/arm/boot/dts/r8a7792.dtsi        | 18 ++++++++++++++++++
>  2 files changed, 38 insertions(+)

Thanks, applied for v5.2.
Geert Uytterhoeven March 19, 2019, 10:26 a.m. UTC | #2
Hi Marek,

On Mon, Mar 4, 2019 at 9:00 PM <marek.vasut@gmail.com> wrote:
> From: Marek Vasut <marek.vasut+renesas@gmail.com>
>
> Add IIC3 node to R8A7792 SoC device tree and a DA9063 PMIC node
> to V2H Blanche board device tree.
>
> Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>

Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>

> --- a/arch/arm/boot/dts/r8a7792-blanche.dts
> +++ b/arch/arm/boot/dts/r8a7792-blanche.dts
> @@ -308,6 +308,26 @@
>         };
>  };
>
> +&iic3 {
> +       status = "okay";
> +
> +       pmic@58 {
> +               compatible = "dlg,da9063";
> +               reg = <0x58>;
> +               interrupt-parent = <&irqc>;
> +               interrupts = <2 IRQ_TYPE_LEVEL_LOW>;

I've just realized none of the R-Car Gen2 boards configure pinctrl for the
IRQC2 line (intc_irq2/intc), so they all rely on the boot loader doing that.

Gr{oetje,eeting}s,

                        Geert
Marek Vasut May 2, 2019, 2:07 p.m. UTC | #3
On 3/19/19 11:26 AM, Geert Uytterhoeven wrote:
> Hi Marek,
> 
> On Mon, Mar 4, 2019 at 9:00 PM <marek.vasut@gmail.com> wrote:
>> From: Marek Vasut <marek.vasut+renesas@gmail.com>
>>
>> Add IIC3 node to R8A7792 SoC device tree and a DA9063 PMIC node
>> to V2H Blanche board device tree.
>>
>> Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
> 
> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
> 
>> --- a/arch/arm/boot/dts/r8a7792-blanche.dts
>> +++ b/arch/arm/boot/dts/r8a7792-blanche.dts
>> @@ -308,6 +308,26 @@
>>         };
>>  };
>>
>> +&iic3 {
>> +       status = "okay";
>> +
>> +       pmic@58 {
>> +               compatible = "dlg,da9063";
>> +               reg = <0x58>;
>> +               interrupt-parent = <&irqc>;
>> +               interrupts = <2 IRQ_TYPE_LEVEL_LOW>;
> 
> I've just realized none of the R-Car Gen2 boards configure pinctrl for the
> IRQC2 line (intc_irq2/intc), so they all rely on the boot loader doing that.

I just sent out a patch
diff mbox series

Patch

diff --git a/arch/arm/boot/dts/r8a7792-blanche.dts b/arch/arm/boot/dts/r8a7792-blanche.dts
index f92301290b02..b6fa80c3b07e 100644
--- a/arch/arm/boot/dts/r8a7792-blanche.dts
+++ b/arch/arm/boot/dts/r8a7792-blanche.dts
@@ -308,6 +308,26 @@ 
 	};
 };
 
+&iic3 {
+	status = "okay";
+
+	pmic@58 {
+		compatible = "dlg,da9063";
+		reg = <0x58>;
+		interrupt-parent = <&irqc>;
+		interrupts = <2 IRQ_TYPE_LEVEL_LOW>;
+		interrupt-controller;
+
+		rtc {
+			compatible = "dlg,da9063-rtc";
+		};
+
+		wdt {
+			compatible = "dlg,da9063-watchdog";
+		};
+	};
+};
+
 &du {
 	pinctrl-0 = <&du0_pins &du1_pins>;
 	pinctrl-names = "default";
diff --git a/arch/arm/boot/dts/r8a7792.dtsi b/arch/arm/boot/dts/r8a7792.dtsi
index 8e9eb4b704d3..38fb43d11b27 100644
--- a/arch/arm/boot/dts/r8a7792.dtsi
+++ b/arch/arm/boot/dts/r8a7792.dtsi
@@ -22,6 +22,7 @@ 
 		i2c3 = &i2c3;
 		i2c4 = &i2c4;
 		i2c5 = &i2c5;
+		i2c6 = &iic3;
 		spi0 = &qspi;
 		spi1 = &msiof0;
 		spi2 = &msiof1;
@@ -444,6 +445,23 @@ 
 			status = "disabled";
 		};
 
+		iic3: i2c@e60b0000 {
+			#address-cells = <1>;
+			#size-cells = <0>;
+			compatible = "renesas,iic-r8a7792",
+				     "renesas,rcar-gen2-iic",
+				     "renesas,rmobile-iic";
+			reg = <0 0xe60b0000 0 0x425>;
+			interrupts = <GIC_SPI 173 IRQ_TYPE_LEVEL_HIGH>;
+			clocks = <&cpg CPG_MOD 926>;
+			dmas = <&dmac0 0x77>, <&dmac0 0x78>,
+			       <&dmac1 0x77>, <&dmac1 0x78>;
+			dma-names = "tx", "rx", "tx", "rx";
+			power-domains = <&sysc R8A7792_PD_ALWAYS_ON>;
+			resets = <&cpg 926>;
+			status = "disabled";
+		};
+
 		dmac0: dma-controller@e6700000 {
 			compatible = "renesas,dmac-r8a7792",
 				     "renesas,rcar-dmac";