Skip to contentSkip to conversation

ARM: at91: rm9200 dt updates

PATCH New Jean-Christophe PLAGNIOL-VILLARD 2 participants 14 messages Jun 17, 2013 – Aug 21, 2013

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

cover ARM: at91: rm9200 dt updates

Hi,

The following patch series enable rm9200 in the dt defconfig and add
- spi
- pqfp package version

The following changes since commit 24ce10e142e7b063c4ae4437dd3b290fbfafe052:

ARM: at91: sam9m10g45ek add udc DT support (2013-06-15 00:15:22 +0200)

are available in the git repository at:

git://github.com/at91linux/linux-at91.git j/for-3.11-rm9200

for you to fetch changes up to 0dab9f12eab58fdf876be8bb39432f7426615230:

ARM: at91: at91rm9200: set default mmc0 pinctrl-names (2013-06-17 20:37:26 +0800)

----------------------------------------------------------------
Jean-Christophe PLAGNIOL-VILLARD (5):
ARM: at91: at91_dt_defconfig: enable rm9200 support
ARM: at91: dt: rm9200: add spi support
ARM: at91: dt: rm9200ek: add spi support
ARM: AT91: dt: add at91rm9200 PQFP package version
ARM: at91: at91rm9200: set default mmc0 pinctrl-names

 arch/arm/boot/dts/at91rm9200.dtsi      |   21 +++++++++++++++++++++
 arch/arm/boot/dts/at91rm9200_pqfp.dtsi |   17 +++++++++++++++++
 arch/arm/boot/dts/at91rm9200ek.dts     |   10 ++++++++++
 arch/arm/configs/at91_dt_defconfig     |    4 +++-
 4 files changed, 51 insertions(+), 1 deletion(-)
 create mode 100644 arch/arm/boot/dts/at91rm9200_pqfp.dtsi

Best Regards,
J.

#1 lore raw

PATCH 1/5 ARM: at91: at91_dt_defconfig: enable rm9200 support

---
 arch/arm/configs/at91_dt_defconfig |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
arch/arm/configs/at91_dt_defconfig +3 -1
index 75fd842..690e892 100644
@@ -14,11 +14,13 @@ CONFIG_MODULE_UNLOAD=y
 # CONFIG_IOSCHED_DEADLINE is not set
 # CONFIG_IOSCHED_CFQ is not set
 CONFIG_ARCH_AT91=y
+CONFIG_SOC_AT91RM9200=y
 CONFIG_SOC_AT91SAM9260=y
 CONFIG_SOC_AT91SAM9263=y
 CONFIG_SOC_AT91SAM9G45=y
 CONFIG_SOC_AT91SAM9X5=y
 CONFIG_SOC_AT91SAM9N12=y
+CONFIG_MACH_AT91RM9200_DT=y
 CONFIG_MACH_AT91SAM9_DT=y
 CONFIG_AT91_PROGRAMMABLE_CLOCKS=y
 CONFIG_AT91_TIMER_HZ=128
@@ -62,6 +64,7 @@ CONFIG_MTD=y
 CONFIG_MTD_CMDLINE_PARTS=y
 CONFIG_MTD_CHAR=y
 CONFIG_MTD_BLOCK=y
+CONFIG_MTD_DATAFLASH=y
 CONFIG_MTD_NAND=y
 CONFIG_MTD_NAND_ATMEL=y
 CONFIG_MTD_UBI=y
@@ -78,7 +81,6 @@ CONFIG_BLK_DEV_SD=y
 CONFIG_SCSI_MULTI_LUN=y
 # CONFIG_SCSI_LOWLEVEL is not set
 CONFIG_NETDEVICES=y
-CONFIG_MII=y
 CONFIG_MACB=y
 # CONFIG_NET_VENDOR_BROADCOM is not set
 # CONFIG_NET_VENDOR_FARADAY is not set
Signature · 1 line
1.7.10.4
#2 lore raw

PATCH 2/5 ARM: at91: dt: rm9200: add spi support

---
 arch/arm/boot/dts/at91rm9200.dtsi |   20 ++++++++++++++++++++
 1 file changed, 20 insertions(+)
arch/arm/boot/dts/at91rm9200.dtsi +20 -0
index b91cf78..1fc645e 100644
@@ -474,6 +474,15 @@
 					};
 				};
 
+				spi0 {
+					pinctrl_spi0: spi0-0 {
+						atmel,pins =
+							<AT91_PIOA 0 AT91_PERIPH_A AT91_PINCTRL_NONE	/* PA0 periph A SPI0_MISO pin */
+							 AT91_PIOA 1 AT91_PERIPH_A AT91_PINCTRL_NONE	/* PA1 periph A SPI0_MOSI pin */
+							 AT91_PIOA 2 AT91_PERIPH_A AT91_PINCTRL_NONE>;	/* PA2 periph A SPI0_SPCK pin */
+					};
+				};
+
 				pioA: gpio at fffff400 {
 					compatible = "atmel,at91rm9200-gpio";
 					reg = <0xfffff400 0x200>;
@@ -574,6 +583,17 @@
 				interrupts = <11 IRQ_TYPE_LEVEL_HIGH 2>;
 				status = "disabled";
 			};
+
+			spi0: spi at fffe0000 {
+				#address-cells = <1>;
+				#size-cells = <0>;
+				compatible = "atmel,at91rm9200-spi";
+				reg = <0xfffe0000 0x200>;
+				interrupts = <13 IRQ_TYPE_LEVEL_HIGH 3>;
+				pinctrl-names = "default";
+				pinctrl-0 = <&pinctrl_spi0>;
+				status = "disabled";
+			};
 		};
 
 		nand0: nand at 40000000 {
Signature · 1 line
1.7.10.4
#3 lore raw

PATCH 2/5 ARM: at91: dt: rm9200: add spi support

On 17/06/2013 14:38, Jean-Christophe PLAGNIOL-VILLARD :

Quoted 2 lines

stacked on at91-3.11-dt

Quoted 43 lines
---
  arch/arm/boot/dts/at91rm9200.dtsi |   20 ++++++++++++++++++++
  1 file changed, 20 insertions(+)
arch/arm/boot/dts/at91rm9200.dtsi +20 -0
index b91cf78..1fc645e 100644
@@ -474,6 +474,15 @@
  					};
  				};
 
+				spi0 {
+					pinctrl_spi0: spi0-0 {
+						atmel,pins =
+							<AT91_PIOA 0 AT91_PERIPH_A AT91_PINCTRL_NONE	/* PA0 periph A SPI0_MISO pin */
+							 AT91_PIOA 1 AT91_PERIPH_A AT91_PINCTRL_NONE	/* PA1 periph A SPI0_MOSI pin */
+							 AT91_PIOA 2 AT91_PERIPH_A AT91_PINCTRL_NONE>;	/* PA2 periph A SPI0_SPCK pin */
+					};
+				};
+
  				pioA: gpio at fffff400 {
  					compatible = "atmel,at91rm9200-gpio";
  					reg = <0xfffff400 0x200>;
@@ -574,6 +583,17 @@
  				interrupts = <11 IRQ_TYPE_LEVEL_HIGH 2>;
  				status = "disabled";
  			};
+
+			spi0: spi at fffe0000 {
+				#address-cells = <1>;
+				#size-cells = <0>;
+				compatible = "atmel,at91rm9200-spi";
+				reg = <0xfffe0000 0x200>;
+				interrupts = <13 IRQ_TYPE_LEVEL_HIGH 3>;
+				pinctrl-names = "default";
+				pinctrl-0 = <&pinctrl_spi0>;
+				status = "disabled";
+			};
  		};
 
  		nand0: nand at 40000000 {
Signature · 1 line
Nicolas Ferre
#4 lore raw

PATCH 3/5 ARM: at91: dt: rm9200ek: add spi support

In reply to Jean-Christophe PLAGNIOL-VILLARD
---
 arch/arm/boot/dts/at91rm9200ek.dts |   10 ++++++++++
 1 file changed, 10 insertions(+)
arch/arm/boot/dts/at91rm9200ek.dts +10 -0
index 1405812..d2d72c3 100644
@@ -53,6 +53,16 @@
 				atmel,vbus-gpio = <&pioD 4 GPIO_ACTIVE_HIGH>;
 				status = "okay";
 			};
+
+			spi0: spi at fffe0000 {
+				status = "okay";
+				cs-gpios = <&pioA 3 0>, <0>, <0>, <0>;
+				mtd_dataflash at 0 {
+					compatible = "atmel,at45", "atmel,dataflash";
+					spi-max-frequency = <15000000>;
+					reg = <0>;
+				};
+			};
 		};
 
 		usb0: ohci at 00300000 {
Signature · 1 line
1.7.10.4
#5 lore raw

PATCH 3/5 ARM: at91: dt: rm9200ek: add spi support

On 17/06/2013 14:38, Jean-Christophe PLAGNIOL-VILLARD :

Quoted 2 lines

stacked on at91-3.11-dt

Thanks

Quoted 26 lines
---
  arch/arm/boot/dts/at91rm9200ek.dts |   10 ++++++++++
  1 file changed, 10 insertions(+)
arch/arm/boot/dts/at91rm9200ek.dts +10 -0
index 1405812..d2d72c3 100644
@@ -53,6 +53,16 @@
  				atmel,vbus-gpio = <&pioD 4 GPIO_ACTIVE_HIGH>;
  				status = "okay";
  			};
+
+			spi0: spi at fffe0000 {
+				status = "okay";
+				cs-gpios = <&pioA 3 0>, <0>, <0>, <0>;
+				mtd_dataflash at 0 {
+					compatible = "atmel,at45", "atmel,dataflash";
+					spi-max-frequency = <15000000>;
+					reg = <0>;
+				};
+			};
  		};
 
  		usb0: ohci at 00300000 {
Signature · 1 line
Nicolas Ferre
#6 lore raw

PATCH 4/5 ARM: AT91: dt: add at91rm9200 PQFP package version

In reply to Jean-Christophe PLAGNIOL-VILLARD

the PQFP version have only 3 gpio banks (A, B & C)

---
 arch/arm/boot/dts/at91rm9200_pqfp.dtsi |   17 +++++++++++++++++
 1 file changed, 17 insertions(+)
 create mode 100644 arch/arm/boot/dts/at91rm9200_pqfp.dtsi
arch/arm/boot/dts/at91rm9200_pqfp.dtsi new file +17 -0
new file mode 100644
index 0000000..8e3d43f
@@ -0,0 +1,17 @@
+/*
+ * at91rm9200_pqfp.dtsi - Device Tree Include file for AT91RM9200 PQFP family SoC
+ *
+ * Copyright (C) 2013 Jean-Christophe PLAGNIOL-VILLARD <[email protected]>
+ *
+ * Licensed under GPLv2 or later.
+ */
+
+#include "at91rm9200.dtsi"
+
+/ {
+	compatible = "atmel,at91rm9200-pqfp", "atmel,at91rm9200";
+};
+
+&pioD {
+	status = "disable";
+};
Signature · 1 line
1.7.10.4
#7 lore raw

PATCH 4/5 ARM: AT91: dt: add at91rm9200 PQFP package version

On 17/06/2013 14:38, Jean-Christophe PLAGNIOL-VILLARD :

Quoted 4 lines

the PQFP version have only 3 gpio banks (A, B & C)

Quoted 17 lines
---
  arch/arm/boot/dts/at91rm9200_pqfp.dtsi |   17 +++++++++++++++++
  1 file changed, 17 insertions(+)

create mode 100644 arch/arm/boot/dts/at91rm9200_pqfp.dtsi

arch/arm/boot/dts/at91rm9200_pqfp.dtsi new file +6 -0
new file mode 100644
index 0000000..8e3d43f
@@ -0,0 +1,17 @@
+/*
+ * at91rm9200_pqfp.dtsi - Device Tree Include file for AT91RM9200 PQFP family SoC
+ *
+ * Copyright (C) 2013 Jean-Christophe PLAGNIOL-VILLARD <[email protected]>
+ *
+ * Licensed under GPLv2 or later.

arch/arm/boot/dts/at91rm9200_pqfp.dtsi line 16

Quoted 10 lines
arch/arm/boot/dts/at91rm9200_pqfp.dtsi new file +10 -0
+ */
+
+#include "at91rm9200.dtsi"
+
+/ {
+	compatible = "atmel,at91rm9200-pqfp", "atmel,at91rm9200";
+};
+
+&pioD {
+	status = "disable";

Typo: s/disable/disabled/

Quoted 2 lines
arch/arm/boot/dts/at91rm9200_pqfp.dtsi new file +1 -0
+};
Signature · 1 line
Nicolas Ferre
#8 lore raw

PATCH 4/5 ARM: AT91: dt: add at91rm9200 PQFP package version

On 26/06/2013 09:55, Nicolas Ferre :

Quoted 29 lines

On 17/06/2013 14:38, Jean-Christophe PLAGNIOL-VILLARD :

Quoted 4 lines

the PQFP version have only 3 gpio banks (A, B & C)

Quoted 21 lines
---
   arch/arm/boot/dts/at91rm9200_pqfp.dtsi |   17 +++++++++++++++++
   1 file changed, 17 insertions(+)

create mode 100644 arch/arm/boot/dts/at91rm9200_pqfp.dtsi

arch/arm/boot/dts/at91rm9200_pqfp.dtsi new file +10 -0
new file mode 100644
index 0000000..8e3d43f
@@ -0,0 +1,17 @@
+/*
+ * at91rm9200_pqfp.dtsi - Device Tree Include file for AT91RM9200 PQFP family SoC
+ *
+ * Copyright (C) 2013 Jean-Christophe PLAGNIOL-VILLARD <[email protected]>
+ *
+ * Licensed under GPLv2 or later.
+ */
+
+#include "at91rm9200.dtsi"
+
Quoted 8 lines

arch/arm/boot/dts/at91rm9200_pqfp.dtsi line 16

Quoted 6 lines
arch/arm/boot/dts/at91rm9200_pqfp.dtsi new file +6 -0
+/ {
+	compatible = "atmel,at91rm9200-pqfp", "atmel,at91rm9200";
+};
+
+&pioD {
+	status = "disable";

Typo: s/disable/disabled/

With typo corrected, stacked on at91-3.12-dt

Thanks,

Signature · 1 line
Nicolas Ferre
#9 lore raw

PATCH 5/5 ARM: at91: at91rm9200: set default mmc0 pinctrl-names

In reply to Jean-Christophe PLAGNIOL-VILLARD
---
 arch/arm/boot/dts/at91rm9200.dtsi |    1 +
 1 file changed, 1 insertion(+)
arch/arm/boot/dts/at91rm9200.dtsi +1 -0
index 1fc645e..8bc87e5 100644
@@ -116,6 +116,7 @@
 				interrupts = <10 IRQ_TYPE_LEVEL_HIGH 0>;
 				#address-cells = <1>;
 				#size-cells = <0>;
+				pinctrl-names = "default";
 				status = "disabled";
 			};
 
Signature · 1 line
1.7.10.4
#10 lore raw

PATCH 5/5 ARM: at91: at91rm9200: set default mmc0 pinctrl-names

On 17/06/2013 14:38, Jean-Christophe PLAGNIOL-VILLARD :

Quoted 11 lines
---
  arch/arm/boot/dts/at91rm9200.dtsi |    1 +
  1 file changed, 1 insertion(+)
arch/arm/boot/dts/at91rm9200.dtsi +0 -0
index 1fc645e..8bc87e5 100644

arch/arm/boot/dts/at91rm9200.dtsi line 119

Quoted 4 lines
arch/arm/boot/dts/at91rm9200.dtsi +1 -0
@@ -116,6 +116,7 @@
  				interrupts = <10 IRQ_TYPE_LEVEL_HIGH 0>;
  				#address-cells = <1>;
  				#size-cells = <0>;
+				pinctrl-names = "default";

You do not add a pinctrl cell: is it normal? Which pinctrl definition does it take then?

Quoted 4 lines
arch/arm/boot/dts/at91rm9200.dtsi +0 -0
  				status = "disabled";
  			};
 
Signature · 1 line
Nicolas Ferre
#11 lore raw

PATCH 5/5 ARM: at91: at91rm9200: set default mmc0 pinctrl-names

On 25/06/2013 12:35, Nicolas Ferre :

Quoted 7 lines

On 17/06/2013 14:38, Jean-Christophe PLAGNIOL-VILLARD :

Quoted 6 lines
---
   arch/arm/boot/dts/at91rm9200.dtsi |    1 +
   1 file changed, 1 insertion(+)
Quoted 12 lines

arch/arm/boot/dts/at91rm9200.dtsi line 119

Quoted 9 lines
arch/arm/boot/dts/at91rm9200.dtsi +1 -0
index 1fc645e..8bc87e5 100644
@@ -116,6 +116,7 @@
   				interrupts = <10 IRQ_TYPE_LEVEL_HIGH 0>;
   				#address-cells = <1>;
   				#size-cells = <0>;
+				pinctrl-names = "default";

You do not add a pinctrl cell: is it normal? Which pinctrl definition does it take then?

Okay, same fix that the one for 9260/9g20. So I take this one without a change:

Quoted 7 lines
Quoted 5 lines
arch/arm/boot/dts/at91rm9200.dtsi +0 -0
   				status = "disabled";
   			};
 
Signature · 1 line
Nicolas Ferre
#12 lore raw

PATCH 1/5 ARM: at91: at91_dt_defconfig: enable rm9200 support

In reply to Jean-Christophe PLAGNIOL-VILLARD

On 17/06/2013 14:38, Jean-Christophe PLAGNIOL-VILLARD :

Quoted 33 lines
---
  arch/arm/configs/at91_dt_defconfig |    4 +++-
  1 file changed, 3 insertions(+), 1 deletion(-)
arch/arm/configs/at91_dt_defconfig +3 -0
index 75fd842..690e892 100644
@@ -14,11 +14,13 @@ CONFIG_MODULE_UNLOAD=y
  # CONFIG_IOSCHED_DEADLINE is not set
  # CONFIG_IOSCHED_CFQ is not set
  CONFIG_ARCH_AT91=y
+CONFIG_SOC_AT91RM9200=y
  CONFIG_SOC_AT91SAM9260=y
  CONFIG_SOC_AT91SAM9263=y
  CONFIG_SOC_AT91SAM9G45=y
  CONFIG_SOC_AT91SAM9X5=y
  CONFIG_SOC_AT91SAM9N12=y
+CONFIG_MACH_AT91RM9200_DT=y
  CONFIG_MACH_AT91SAM9_DT=y
  CONFIG_AT91_PROGRAMMABLE_CLOCKS=y
  CONFIG_AT91_TIMER_HZ=128
@@ -62,6 +64,7 @@ CONFIG_MTD=y
  CONFIG_MTD_CMDLINE_PARTS=y
  CONFIG_MTD_CHAR=y
  CONFIG_MTD_BLOCK=y
+CONFIG_MTD_DATAFLASH=y
  CONFIG_MTD_NAND=y
  CONFIG_MTD_NAND_ATMEL=y
  CONFIG_MTD_UBI=y

arch/arm/configs/at91_dt_defconfig CONFIG_BLK_DEV_SD=y · line 81

Quoted 4 lines
arch/arm/configs/at91_dt_defconfig +0 -1
@@ -78,7 +81,6 @@ CONFIG_BLK_DEV_SD=y
  CONFIG_SCSI_MULTI_LUN=y
  # CONFIG_SCSI_LOWLEVEL is not set
  CONFIG_NETDEVICES=y
-CONFIG_MII=y

What is the reason for this change? It is really related with rm9200 DT suppot?

Quoted 4 lines
arch/arm/configs/at91_dt_defconfig +0 -0
  CONFIG_MACB=y
  # CONFIG_NET_VENDOR_BROADCOM is not set
  # CONFIG_NET_VENDOR_FARADAY is not set
Signature · 1 line
Nicolas Ferre
#13 lore raw

PATCH 1/5 ARM: at91: at91_dt_defconfig: enable rm9200 support

On 25/06/2013 12:39, Nicolas Ferre :

Quoted 33 lines

On 17/06/2013 14:38, Jean-Christophe PLAGNIOL-VILLARD :

Quoted 32 lines
---
   arch/arm/configs/at91_dt_defconfig |    4 +++-
   1 file changed, 3 insertions(+), 1 deletion(-)
arch/arm/configs/at91_dt_defconfig +3 -0
index 75fd842..690e892 100644
@@ -14,11 +14,13 @@ CONFIG_MODULE_UNLOAD=y
   # CONFIG_IOSCHED_DEADLINE is not set
   # CONFIG_IOSCHED_CFQ is not set
   CONFIG_ARCH_AT91=y
+CONFIG_SOC_AT91RM9200=y
   CONFIG_SOC_AT91SAM9260=y
   CONFIG_SOC_AT91SAM9263=y
   CONFIG_SOC_AT91SAM9G45=y
   CONFIG_SOC_AT91SAM9X5=y
   CONFIG_SOC_AT91SAM9N12=y
+CONFIG_MACH_AT91RM9200_DT=y
   CONFIG_MACH_AT91SAM9_DT=y
   CONFIG_AT91_PROGRAMMABLE_CLOCKS=y
   CONFIG_AT91_TIMER_HZ=128
@@ -62,6 +64,7 @@ CONFIG_MTD=y
   CONFIG_MTD_CMDLINE_PARTS=y
   CONFIG_MTD_CHAR=y
   CONFIG_MTD_BLOCK=y
+CONFIG_MTD_DATAFLASH=y
   CONFIG_MTD_NAND=y
   CONFIG_MTD_NAND_ATMEL=y
   CONFIG_MTD_UBI=y
Quoted 8 lines

arch/arm/configs/at91_dt_defconfig CONFIG_BLK_DEV_SD=y · line 81

Quoted 5 lines
arch/arm/configs/at91_dt_defconfig +0 -1
@@ -78,7 +81,6 @@ CONFIG_BLK_DEV_SD=y
   CONFIG_SCSI_MULTI_LUN=y
   # CONFIG_SCSI_LOWLEVEL is not set
   CONFIG_NETDEVICES=y
-CONFIG_MII=y

What is the reason for this change? It is really related with rm9200 DT suppot?

Okay, automatic selection by MACB => we can remove it.

stacked on at91-3.12-cleanup

Thanks,

Quoted 7 lines
Quoted 5 lines
arch/arm/configs/at91_dt_defconfig +0 -0
   CONFIG_MACB=y
   # CONFIG_NET_VENDOR_BROADCOM is not set
   # CONFIG_NET_VENDOR_FARADAY is not set
Signature · 1 line
Nicolas Ferre