* [PATCH 1/3] ARM: dts: r8a7792: add QSPI clock
2016-09-02 22:04 [PATCH 0/3] Add R8A7792/Wheat QSPI support Sergei Shtylyov
@ 2016-09-02 22:07 ` Sergei Shtylyov
2016-09-05 9:04 ` Geert Uytterhoeven
2016-09-02 22:08 ` [PATCH 2/3] ARM: dts: r8a7792: add QSPI support Sergei Shtylyov
` (2 subsequent siblings)
3 siblings, 1 reply; 8+ messages in thread
From: Sergei Shtylyov @ 2016-09-02 22:07 UTC (permalink / raw)
To: linux-arm-kernel
Describe the QSPI clock in the R8A7792 device tree.
Based on the original (and large) patch by Vladimir Barinov
<vladimir.barinov@cogentembedded.com>.
Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>
---
arch/arm/boot/dts/r8a7792.dtsi | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
Index: renesas/arch/arm/boot/dts/r8a7792.dtsi
===================================================================
--- renesas.orig/arch/arm/boot/dts/r8a7792.dtsi
+++ renesas/arch/arm/boot/dts/r8a7792.dtsi
@@ -860,6 +860,7 @@
clocks = <&cp_clk>, <&cp_clk>, <&cp_clk>, <&cp_clk>,
<&cp_clk>, <&cp_clk>, <&cp_clk>, <&cp_clk>,
<&cp_clk>, <&cp_clk>, <&p_clk>, <&p_clk>,
+ <&cpg_clocks R8A7792_CLK_QSPI>,
<&cp_clk>, <&cp_clk>, <&hp_clk>, <&hp_clk>,
<&hp_clk>, <&hp_clk>, <&hp_clk>, <&hp_clk>;
#clock-cells = <1>;
@@ -870,6 +871,7 @@
R8A7792_CLK_GPIO1 R8A7792_CLK_GPIO0
R8A7792_CLK_GPIO11 R8A7792_CLK_GPIO10
R8A7792_CLK_CAN1 R8A7792_CLK_CAN0
+ R8A7792_CLK_QSPI_MOD
R8A7792_CLK_GPIO9 R8A7792_CLK_GPIO8
R8A7792_CLK_I2C5 R8A7792_CLK_I2C4
R8A7792_CLK_I2C3 R8A7792_CLK_I2C2
@@ -879,8 +881,9 @@
"gpio7", "gpio6", "gpio5", "gpio4",
"gpio3", "gpio2", "gpio1", "gpio0",
"gpio11", "gpio10", "can1", "can0",
- "gpio9", "gpio8", "i2c5", "i2c4",
- "i2c3", "i2c2", "i2c1", "i2c0";
+ "qspi_mod", "gpio9", "gpio8",
+ "i2c5", "i2c4", "i2c3", "i2c2",
+ "i2c1", "i2c0";
};
};
^ permalink raw reply [flat|nested] 8+ messages in thread
* [PATCH 2/3] ARM: dts: r8a7792: add QSPI support
2016-09-02 22:04 [PATCH 0/3] Add R8A7792/Wheat QSPI support Sergei Shtylyov
2016-09-02 22:07 ` [PATCH 1/3] ARM: dts: r8a7792: add QSPI clock Sergei Shtylyov
@ 2016-09-02 22:08 ` Sergei Shtylyov
2016-09-05 9:06 ` Geert Uytterhoeven
2016-09-02 22:09 ` [PATCH 3/3] ARM: dts: wheat: " Sergei Shtylyov
2016-09-05 12:01 ` [PATCH 0/3] Add R8A7792/Wheat " Simon Horman
3 siblings, 1 reply; 8+ messages in thread
From: Sergei Shtylyov @ 2016-09-02 22:08 UTC (permalink / raw)
To: linux-arm-kernel
Define the generic R8A7792 part of the QSPI device node.
Based on the original (and large) patch by Vladimir Barinov
<vladimir.barinov@cogentembedded.com>.
Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>
---
arch/arm/boot/dts/r8a7792.dtsi | 16 ++++++++++++++++
1 file changed, 16 insertions(+)
Index: renesas/arch/arm/boot/dts/r8a7792.dtsi
===================================================================
--- renesas.orig/arch/arm/boot/dts/r8a7792.dtsi
+++ renesas/arch/arm/boot/dts/r8a7792.dtsi
@@ -25,6 +25,7 @@
i2c3 = &i2c3;
i2c4 = &i2c4;
i2c5 = &i2c5;
+ spi0 = &qspi;
vin0 = &vin0;
vin1 = &vin1;
vin2 = &vin2;
@@ -554,6 +555,21 @@
#address-cells = <1>;
#size-cells = <0>;
status = "disabled";
+ };
+
+ qspi: spi at e6b10000 {
+ compatible = "renesas,qspi-r8a7792", "renesas,qspi";
+ reg = <0 0xe6b10000 0 0x2c>;
+ interrupts = <GIC_SPI 184 IRQ_TYPE_LEVEL_HIGH>;
+ clocks = <&mstp9_clks R8A7792_CLK_QSPI_MOD>;
+ dmas = <&dmac0 0x17>, <&dmac0 0x18>,
+ <&dmac1 0x17>, <&dmac1 0x18>;
+ dma-names = "tx", "rx", "tx", "rx";
+ power-domains = <&sysc R8A7792_PD_ALWAYS_ON>;
+ num-cs = <1>;
+ #address-cells = <1>;
+ #size-cells = <0>;
+ status = "disabled";
};
du: display at feb00000 {
^ permalink raw reply [flat|nested] 8+ messages in thread
* [PATCH 3/3] ARM: dts: wheat: add QSPI support
2016-09-02 22:04 [PATCH 0/3] Add R8A7792/Wheat QSPI support Sergei Shtylyov
2016-09-02 22:07 ` [PATCH 1/3] ARM: dts: r8a7792: add QSPI clock Sergei Shtylyov
2016-09-02 22:08 ` [PATCH 2/3] ARM: dts: r8a7792: add QSPI support Sergei Shtylyov
@ 2016-09-02 22:09 ` Sergei Shtylyov
2016-09-05 9:10 ` Geert Uytterhoeven
2016-09-05 12:01 ` [PATCH 0/3] Add R8A7792/Wheat " Simon Horman
3 siblings, 1 reply; 8+ messages in thread
From: Sergei Shtylyov @ 2016-09-02 22:09 UTC (permalink / raw)
To: linux-arm-kernel
Define the Wheat board dependent part of the QSPI device node.
Add device nodes for Spansion S25FL512S SPI flash and MTD partitions on it.
Based on the original (and large) patch by Vladimir Barinov
<vladimir.barinov@cogentembedded.com>.
Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>
---
arch/arm/boot/dts/r8a7792-wheat.dts | 43 ++++++++++++++++++++++++++++++++++++
1 file changed, 43 insertions(+)
Index: renesas/arch/arm/boot/dts/r8a7792-wheat.dts
===================================================================
--- renesas.orig/arch/arm/boot/dts/r8a7792-wheat.dts
+++ renesas/arch/arm/boot/dts/r8a7792-wheat.dts
@@ -132,6 +132,11 @@
function = "sdhi0";
};
+ qspi_pins: qspi {
+ groups = "qspi_ctrl", "qspi_data4";
+ function = "qspi";
+ };
+
du0_pins: du0 {
groups = "du0_rgb888", "du0_sync", "du0_disp";
function = "du0";
@@ -173,6 +178,44 @@
status = "okay";
};
+&qspi {
+ pinctrl-0 = <&qspi_pins>;
+ pinctrl-names = "default";
+ status = "okay";
+
+ flash at 0 {
+ compatible = "spansion,s25fl512s", "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <30000000>;
+ spi-tx-bus-width = <4>;
+ spi-rx-bus-width = <4>;
+ spi-cpol;
+ spi-cpha;
+ m25p,fast-read;
+
+ partitions {
+ compatible = "fixed-partitions";
+ #address-cells = <1>;
+ #size-cells = <1>;
+
+ partition at 0 {
+ label = "loader";
+ reg = <0x00000000 0x00040000>;
+ read-only;
+ };
+ partition at 40000 {
+ label = "user";
+ reg = <0x00040000 0x00400000>;
+ read-only;
+ };
+ partition at 440000 {
+ label = "flash";
+ reg = <0x00440000 0x03bc0000>;
+ };
+ };
+ };
+};
+
&i2c4 {
status = "okay";
clock-frequency = <400000>;
^ permalink raw reply [flat|nested] 8+ messages in thread