* [PATCH/RFC 00/03] arm64: dts: renesas: Eagle V3M PFC/GPIO update and SPI NOR flash bitbang hack
@ 2018-01-18 19:07 Magnus Damm
2018-01-18 19:07 ` [PATCH/RFC 01/03] arm64: dts: renesas: r8a77970: Add PFC node for Eagle V3M Magnus Damm
` (2 more replies)
0 siblings, 3 replies; 6+ messages in thread
From: Magnus Damm @ 2018-01-18 19:07 UTC (permalink / raw)
To: linux-renesas-soc; +Cc: Magnus Damm
arm64: dts: renesas: Eagle V3M PFC/GPIO update and SPI NOR flash bitbang hack
[PATCH/RFC 01/03] arm64: dts: renesas: r8a77970: Add PFC node for Eagle V3M
[PATCH/RFC 02/03] arm64: dts: renesas: r8a77970: Add GPIO nodes
[PATCH/RFC 03/03] arm64: dts: renesas: eagle: NOR flash SPI bitbang prototype
This series gives the R-Car V3M SoC and the Eagle board an update when
it comes to PFC and GPIO support. Also to test the two QSPI channels are
configured as GPIOs and via SPI bitbang the SPI NOR flash chips are probed.
Patch 1 and 2 are rather ready for upstream merge:
Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
Patch 3 is just for testing purpose and shall not be picked up:
Not-Yet-Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
---
Developed on top of renesas-drivers-2018-01-09-v4.15-rc7
arch/arm64/boot/dts/renesas/r8a77970-eagle.dts | 46 ++++++++++
arch/arm64/boot/dts/renesas/r8a77970.dtsi | 101 ++++++++++++++++++++++++
2 files changed, 147 insertions(+)
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH/RFC 01/03] arm64: dts: renesas: r8a77970: Add PFC node for Eagle V3M
2018-01-18 19:07 [PATCH/RFC 00/03] arm64: dts: renesas: Eagle V3M PFC/GPIO update and SPI NOR flash bitbang hack Magnus Damm
@ 2018-01-18 19:07 ` Magnus Damm
2018-01-19 8:29 ` Sergei Shtylyov
2018-01-18 19:07 ` [PATCH/RFC 02/03] arm64: dts: renesas: r8a77970: Add GPIO nodes Magnus Damm
2018-01-18 19:07 ` [PATCH/RFC 03/03] arm64: dts: renesas: eagle: NOR flash SPI bitbang prototype Magnus Damm
2 siblings, 1 reply; 6+ messages in thread
From: Magnus Damm @ 2018-01-18 19:07 UTC (permalink / raw)
To: linux-renesas-soc; +Cc: Magnus Damm
From: Magnus Damm <damm+renesas@opensource.se>
Add DT nodes for the PFC on the r8a77970 SoC and hook up the SCIF
console to make use of the PFC to configure the pins.
Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
---
Depends on r8a77970 PFC support - included in latest renesas-drivers
arch/arm64/boot/dts/renesas/r8a77970-eagle.dts | 10 ++++++++++
arch/arm64/boot/dts/renesas/r8a77970.dtsi | 5 +++++
2 files changed, 15 insertions(+)
--- 0001/arch/arm64/boot/dts/renesas/r8a77970-eagle.dts
+++ work/arch/arm64/boot/dts/renesas/r8a77970-eagle.dts 2018-01-19 03:43:18.050607110 +0900
@@ -52,11 +52,21 @@
clock-frequency = <32768>;
};
+&pfc {
+ scif0_pins: scif0 {
+ groups = "scif0_data";
+ function = "scif0";
+ };
+};
+
&rwdt {
timeout-sec = <60>;
status = "okay";
};
&scif0 {
+ pinctrl-0 = <&scif0_pins>;
+ pinctrl-names = "default";
+
status = "okay";
};
--- 0001/arch/arm64/boot/dts/renesas/r8a77970.dtsi
+++ work/arch/arm64/boot/dts/renesas/r8a77970.dtsi 2018-01-19 03:43:36.990607110 +0900
@@ -117,6 +117,11 @@
reg = <0 0xe6160000 0 0x200>;
};
+ pfc: pin-controller@e6060000 {
+ compatible = "renesas,pfc-r8a77970";
+ reg = <0 0xe6060000 0 0x504>;
+ };
+
sysc: system-controller@e6180000 {
compatible = "renesas,r8a77970-sysc";
reg = <0 0xe6180000 0 0x440>;
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH/RFC 02/03] arm64: dts: renesas: r8a77970: Add GPIO nodes
2018-01-18 19:07 [PATCH/RFC 00/03] arm64: dts: renesas: Eagle V3M PFC/GPIO update and SPI NOR flash bitbang hack Magnus Damm
2018-01-18 19:07 ` [PATCH/RFC 01/03] arm64: dts: renesas: r8a77970: Add PFC node for Eagle V3M Magnus Damm
@ 2018-01-18 19:07 ` Magnus Damm
2018-01-19 8:35 ` Sergei Shtylyov
2018-01-18 19:07 ` [PATCH/RFC 03/03] arm64: dts: renesas: eagle: NOR flash SPI bitbang prototype Magnus Damm
2 siblings, 1 reply; 6+ messages in thread
From: Magnus Damm @ 2018-01-18 19:07 UTC (permalink / raw)
To: linux-renesas-soc; +Cc: Magnus Damm
From: Magnus Damm <damm+renesas@opensource.se>
Add GPIO device nodes for the r8a77970 SoC. Each GPIO device is
currently assumed to have 32 pins.
Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
---
arch/arm64/boot/dts/renesas/r8a77970.dtsi | 96 +++++++++++++++++++++++++++++
1 file changed, 96 insertions(+)
--- 0002/arch/arm64/boot/dts/renesas/r8a77970.dtsi
+++ work/arch/arm64/boot/dts/renesas/r8a77970.dtsi 2018-01-19 03:45:15.990607110 +0900
@@ -248,6 +248,102 @@
<&ipmmu_ds1 22>, <&ipmmu_ds1 23>;
};
+ gpio0: gpio@e6050000 {
+ compatible = "renesas,gpio-r8a77970",
+ "renesas,rcar-gen3-gpio",
+ "renesas,gpio-rcar";
+ reg = <0 0xe6050000 0 0x50>;
+ interrupts = <GIC_SPI 4 IRQ_TYPE_LEVEL_HIGH>;
+ #gpio-cells = <2>;
+ gpio-controller;
+ gpio-ranges = <&pfc 0 0 32>;
+ #interrupt-cells = <2>;
+ interrupt-controller;
+ clocks = <&cpg CPG_MOD 912>;
+ power-domains = <&sysc R8A77970_PD_ALWAYS_ON>;
+ resets = <&cpg 912>;
+ };
+
+ gpio1: gpio@e6051000 {
+ compatible = "renesas,gpio-r8a77970",
+ "renesas,rcar-gen3-gpio",
+ "renesas,gpio-rcar";
+ reg = <0 0xe6051000 0 0x50>;
+ interrupts = <GIC_SPI 5 IRQ_TYPE_LEVEL_HIGH>;
+ #gpio-cells = <2>;
+ gpio-controller;
+ gpio-ranges = <&pfc 0 32 32>;
+ #interrupt-cells = <2>;
+ interrupt-controller;
+ clocks = <&cpg CPG_MOD 911>;
+ power-domains = <&sysc R8A77970_PD_ALWAYS_ON>;
+ resets = <&cpg 911>;
+ };
+
+ gpio2: gpio@e6052000 {
+ compatible = "renesas,gpio-r8a77970",
+ "renesas,rcar-gen3-gpio",
+ "renesas,gpio-rcar";
+ reg = <0 0xe6052000 0 0x50>;
+ interrupts = <GIC_SPI 6 IRQ_TYPE_LEVEL_HIGH>;
+ #gpio-cells = <2>;
+ gpio-controller;
+ gpio-ranges = <&pfc 0 64 32>;
+ #interrupt-cells = <2>;
+ interrupt-controller;
+ clocks = <&cpg CPG_MOD 910>;
+ power-domains = <&sysc R8A77970_PD_ALWAYS_ON>;
+ resets = <&cpg 910>;
+ };
+
+ gpio3: gpio@e6053000 {
+ compatible = "renesas,gpio-r8a77970",
+ "renesas,rcar-gen3-gpio",
+ "renesas,gpio-rcar";
+ reg = <0 0xe6053000 0 0x50>;
+ interrupts = <GIC_SPI 7 IRQ_TYPE_LEVEL_HIGH>;
+ #gpio-cells = <2>;
+ gpio-controller;
+ gpio-ranges = <&pfc 0 96 32>;
+ #interrupt-cells = <2>;
+ interrupt-controller;
+ clocks = <&cpg CPG_MOD 909>;
+ power-domains = <&sysc R8A77970_PD_ALWAYS_ON>;
+ resets = <&cpg 909>;
+ };
+
+ gpio4: gpio@e6054000 {
+ compatible = "renesas,gpio-r8a77970",
+ "renesas,rcar-gen3-gpio",
+ "renesas,gpio-rcar";
+ reg = <0 0xe6054000 0 0x50>;
+ interrupts = <GIC_SPI 8 IRQ_TYPE_LEVEL_HIGH>;
+ #gpio-cells = <2>;
+ gpio-controller;
+ gpio-ranges = <&pfc 0 128 32>;
+ #interrupt-cells = <2>;
+ interrupt-controller;
+ clocks = <&cpg CPG_MOD 908>;
+ power-domains = <&sysc R8A77970_PD_ALWAYS_ON>;
+ resets = <&cpg 908>;
+ };
+
+ gpio5: gpio@e6055000 {
+ compatible = "renesas,gpio-r8a77970",
+ "renesas,rcar-gen3-gpio",
+ "renesas,gpio-rcar";
+ reg = <0 0xe6055000 0 0x50>;
+ interrupts = <GIC_SPI 9 IRQ_TYPE_LEVEL_HIGH>;
+ #gpio-cells = <2>;
+ gpio-controller;
+ gpio-ranges = <&pfc 0 160 32>;
+ #interrupt-cells = <2>;
+ interrupt-controller;
+ clocks = <&cpg CPG_MOD 907>;
+ power-domains = <&sysc R8A77970_PD_ALWAYS_ON>;
+ resets = <&cpg 907>;
+ };
+
hscif0: serial@e6540000 {
compatible = "renesas,hscif-r8a77970",
"renesas,rcar-gen3-hscif",
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH/RFC 03/03] arm64: dts: renesas: eagle: NOR flash SPI bitbang prototype
2018-01-18 19:07 [PATCH/RFC 00/03] arm64: dts: renesas: Eagle V3M PFC/GPIO update and SPI NOR flash bitbang hack Magnus Damm
2018-01-18 19:07 ` [PATCH/RFC 01/03] arm64: dts: renesas: r8a77970: Add PFC node for Eagle V3M Magnus Damm
2018-01-18 19:07 ` [PATCH/RFC 02/03] arm64: dts: renesas: r8a77970: Add GPIO nodes Magnus Damm
@ 2018-01-18 19:07 ` Magnus Damm
2 siblings, 0 replies; 6+ messages in thread
From: Magnus Damm @ 2018-01-18 19:07 UTC (permalink / raw)
To: linux-renesas-soc; +Cc: Magnus Damm
From: Magnus Damm <damm+renesas@opensource.se>
Drive the NOR flash chips via SPI bitbang instead of via the two
channels of QSPI hardware. This is useful to test the on-chip GPIO
devices.
Not-Yet-Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
---
arch/arm64/boot/dts/renesas/r8a77970-eagle.dts | 36 ++++++++++++++++++++++++
1 file changed, 36 insertions(+)
--- 0002/arch/arm64/boot/dts/renesas/r8a77970-eagle.dts
+++ work/arch/arm64/boot/dts/renesas/r8a77970-eagle.dts 2018-01-19 03:47:16.380607110 +0900
@@ -31,6 +31,42 @@
/* first 128MB is reserved for secure area. */
reg = <0x0 0x48000000 0x0 0x38000000>;
};
+
+ spi_flash@0 {
+ compatible = "spi-gpio";
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ gpio-sck = <&gpio5 0 0>;
+ gpio-mosi = <&gpio5 1 0>;
+ gpio-miso = <&gpio5 2 0>;
+ cs-gpios = <&gpio5 5 0>;
+ num-chipselects = <1>;
+
+ flash@0 {
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <30000000>;
+ };
+ };
+
+ spi_flash@1 {
+ compatible = "spi-gpio";
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ gpio-sck = <&gpio5 6 0>;
+ gpio-mosi = <&gpio5 7 0>;
+ gpio-miso = <&gpio5 8 0>;
+ cs-gpios = <&gpio5 11 0>;
+ num-chipselects = <1>;
+
+ flash@1 {
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <30000000>;
+ };
+ };
};
&avb {
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH/RFC 01/03] arm64: dts: renesas: r8a77970: Add PFC node for Eagle V3M
2018-01-18 19:07 ` [PATCH/RFC 01/03] arm64: dts: renesas: r8a77970: Add PFC node for Eagle V3M Magnus Damm
@ 2018-01-19 8:29 ` Sergei Shtylyov
0 siblings, 0 replies; 6+ messages in thread
From: Sergei Shtylyov @ 2018-01-19 8:29 UTC (permalink / raw)
To: Magnus Damm, linux-renesas-soc
Hello!
On 1/18/2018 10:07 PM, Magnus Damm wrote:
> From: Magnus Damm <damm+renesas@opensource.se>
>
> Add DT nodes for the PFC on the r8a77970 SoC and hook up the SCIF
> console to make use of the PFC to configure the pins.
>
> Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
> ---
>
> Depends on r8a77970 PFC support - included in latest renesas-drivers
Magnus, I have already posted R8A77970 PFC stuff back in November:
https://patchwork.kernel.org/patch/10053687/
https://patchwork.kernel.org/patch/10053689/
MBR, Sergei
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH/RFC 02/03] arm64: dts: renesas: r8a77970: Add GPIO nodes
2018-01-18 19:07 ` [PATCH/RFC 02/03] arm64: dts: renesas: r8a77970: Add GPIO nodes Magnus Damm
@ 2018-01-19 8:35 ` Sergei Shtylyov
0 siblings, 0 replies; 6+ messages in thread
From: Sergei Shtylyov @ 2018-01-19 8:35 UTC (permalink / raw)
To: Magnus Damm, linux-renesas-soc
On 1/18/2018 10:07 PM, Magnus Damm wrote:
> From: Magnus Damm <damm+renesas@opensource.se>
>
> Add GPIO device nodes for the r8a77970 SoC. Each GPIO device is
> currently assumed to have 32 pins.
>
> Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
[...]
Already posted as well:
https://patchwork.kernel.org/patch/10056695/
> --- 0002/arch/arm64/boot/dts/renesas/r8a77970.dtsi
> +++ work/arch/arm64/boot/dts/renesas/r8a77970.dtsi 2018-01-19 03:45:15.990607110 +0900
> @@ -248,6 +248,102 @@
> <&ipmmu_ds1 22>, <&ipmmu_ds1 23>;
> };
>
> + gpio0: gpio@e6050000 {
> + compatible = "renesas,gpio-r8a77970",
> + "renesas,rcar-gen3-gpio",
> + "renesas,gpio-rcar";
> + reg = <0 0xe6050000 0 0x50>;
> + interrupts = <GIC_SPI 4 IRQ_TYPE_LEVEL_HIGH>;
> + #gpio-cells = <2>;
> + gpio-controller;
> + gpio-ranges = <&pfc 0 0 32>;
gpio-ranges = <&pfc 0 0 22>;
> + #interrupt-cells = <2>;
> + interrupt-controller;
> + clocks = <&cpg CPG_MOD 912>;
> + power-domains = <&sysc R8A77970_PD_ALWAYS_ON>;
> + resets = <&cpg 912>;
> + };
> +
> + gpio1: gpio@e6051000 {
> + compatible = "renesas,gpio-r8a77970",
> + "renesas,rcar-gen3-gpio",
> + "renesas,gpio-rcar";
> + reg = <0 0xe6051000 0 0x50>;
> + interrupts = <GIC_SPI 5 IRQ_TYPE_LEVEL_HIGH>;
> + #gpio-cells = <2>;
> + gpio-controller;
> + gpio-ranges = <&pfc 0 32 32>;
gpio-ranges = <&pfc 0 32 28>;
> + #interrupt-cells = <2>;
> + interrupt-controller;
> + clocks = <&cpg CPG_MOD 911>;
> + power-domains = <&sysc R8A77970_PD_ALWAYS_ON>;
> + resets = <&cpg 911>;
> + };
> +
> + gpio2: gpio@e6052000 {
> + compatible = "renesas,gpio-r8a77970",
> + "renesas,rcar-gen3-gpio",
> + "renesas,gpio-rcar";
> + reg = <0 0xe6052000 0 0x50>;
> + interrupts = <GIC_SPI 6 IRQ_TYPE_LEVEL_HIGH>;
> + #gpio-cells = <2>;
> + gpio-controller;
> + gpio-ranges = <&pfc 0 64 32>;
gpio-ranges = <&pfc 0 64 17>;
> + #interrupt-cells = <2>;
> + interrupt-controller;
> + clocks = <&cpg CPG_MOD 910>;
> + power-domains = <&sysc R8A77970_PD_ALWAYS_ON>;
> + resets = <&cpg 910>;
> + };
> +
> + gpio3: gpio@e6053000 {
> + compatible = "renesas,gpio-r8a77970",
> + "renesas,rcar-gen3-gpio",
> + "renesas,gpio-rcar";
> + reg = <0 0xe6053000 0 0x50>;
> + interrupts = <GIC_SPI 7 IRQ_TYPE_LEVEL_HIGH>;
> + #gpio-cells = <2>;
> + gpio-controller;
> + gpio-ranges = <&pfc 0 96 32>;
gpio-ranges = <&pfc 0 96 17>;
> + #interrupt-cells = <2>;
> + interrupt-controller;
> + clocks = <&cpg CPG_MOD 909>;
> + power-domains = <&sysc R8A77970_PD_ALWAYS_ON>;
> + resets = <&cpg 909>;
> + };
> +
> + gpio4: gpio@e6054000 {
> + compatible = "renesas,gpio-r8a77970",
> + "renesas,rcar-gen3-gpio",
> + "renesas,gpio-rcar";
> + reg = <0 0xe6054000 0 0x50>;
> + interrupts = <GIC_SPI 8 IRQ_TYPE_LEVEL_HIGH>;
> + #gpio-cells = <2>;
> + gpio-controller;
> + gpio-ranges = <&pfc 0 128 32>;
gpio-ranges = <&pfc 0 128 6>;
> + #interrupt-cells = <2>;
> + interrupt-controller;
> + clocks = <&cpg CPG_MOD 908>;
> + power-domains = <&sysc R8A77970_PD_ALWAYS_ON>;
> + resets = <&cpg 908>;
> + };
> +
> + gpio5: gpio@e6055000 {
> + compatible = "renesas,gpio-r8a77970",
> + "renesas,rcar-gen3-gpio",
> + "renesas,gpio-rcar";
> + reg = <0 0xe6055000 0 0x50>;
> + interrupts = <GIC_SPI 9 IRQ_TYPE_LEVEL_HIGH>;
> + #gpio-cells = <2>;
> + gpio-controller;
> + gpio-ranges = <&pfc 0 160 32>;
> + #interrupt-cells = <2>;
gpio-ranges = <&pfc 0 160 15>;
> + interrupt-controller;
> + clocks = <&cpg CPG_MOD 907>;
> + power-domains = <&sysc R8A77970_PD_ALWAYS_ON>;
> + resets = <&cpg 907>;
> + };
> +
> hscif0: serial@e6540000 {
> compatible = "renesas,hscif-r8a77970",
> "renesas,rcar-gen3-hscif",
>
MBR, Sergei
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2018-01-19 8:35 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-01-18 19:07 [PATCH/RFC 00/03] arm64: dts: renesas: Eagle V3M PFC/GPIO update and SPI NOR flash bitbang hack Magnus Damm
2018-01-18 19:07 ` [PATCH/RFC 01/03] arm64: dts: renesas: r8a77970: Add PFC node for Eagle V3M Magnus Damm
2018-01-19 8:29 ` Sergei Shtylyov
2018-01-18 19:07 ` [PATCH/RFC 02/03] arm64: dts: renesas: r8a77970: Add GPIO nodes Magnus Damm
2018-01-19 8:35 ` Sergei Shtylyov
2018-01-18 19:07 ` [PATCH/RFC 03/03] arm64: dts: renesas: eagle: NOR flash SPI bitbang prototype Magnus Damm
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox