Skip to contentSkip to conversation

ARM: EXYNOS: ODROID-XU DT and LEDs

PATCH Applied Andreas Färber 7 participants 21 messages Mar 15, 2015 – Jun 2, 2015

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

v4 cover ARM: EXYNOS: ODROID-XU DT and LEDs

Hello,

This series adds a dedicated ODROID-XU device tree and enhances it with LED configuration, to match the downstream 3.14 based behavior.

Regards,
Andreas

v3 -> v4:
* Rebased pinctrl (.label field dropped, const'ified, __initconst)
* Edited dts subjects to match Kukjin's preferred style

v2 -> v3:
* Actually rebased pinctrl (.svc, .{g,w}eint_{con,mask,pend} fields dropped)
* Added wake-up IRQ controller node (Tomasz Figa)

v1 -> v2:
* Inserted needed Sobs from Hakjoo Kim

Andreas F?rber (3):
ARM: dts: Clean up exynos5410-smdk5410 indentation
ARM: dts: Prepare exynos5410-odroidxu device tree
ARM: dts: Add LEDs to exynos5410-odroidxu

Hakjoo Kim (2):
pinctrl: exynos: add exynos5410 SoC specific data
ARM: dts: add pinctrl support to Exynos5410

 .../bindings/pinctrl/samsung-pinctrl.txt           |   1 +
 arch/arm/boot/dts/Makefile                         |   1 +
 arch/arm/boot/dts/exynos5410-odroidxu.dts          | 103 ++++++
 arch/arm/boot/dts/exynos5410-pinctrl.dtsi          | 406 +++++++++++++++++++++
 arch/arm/boot/dts/exynos5410-smdk5410.dts          |   6 +-
 arch/arm/boot/dts/exynos5410.dtsi                  |  36 ++
 drivers/pinctrl/samsung/pinctrl-exynos.c           | 103 ++++++
 drivers/pinctrl/samsung/pinctrl-samsung.c          |   2 +
 drivers/pinctrl/samsung/pinctrl-samsung.h          |   1 +
 9 files changed, 656 insertions(+), 3 deletions(-)
 create mode 100644 arch/arm/boot/dts/exynos5410-odroidxu.dts
 create mode 100644 arch/arm/boot/dts/exynos5410-pinctrl.dtsi
Signature · 1 line
2.3.1
#1 lore raw

PATCH v4 1/5 ARM: dts: Clean up exynos5410-smdk5410 indentation

The UART status properties are indented one level too deep, and we want to derive a device tree for the ODROID-XU. Fix this before it propagates.

---
v1 -> v2 -> v3: Unchanged

 arch/arm/boot/dts/exynos5410-smdk5410.dts | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
arch/arm/boot/dts/exynos5410-smdk5410.dts +3 -3
index be3e02530b42..cebeaab3abec 100644
@@ -62,13 +62,13 @@
 };
 
 &uart0 {
-		status = "okay";
+	status = "okay";
 };
 
 &uart1 {
-		status = "okay";
+	status = "okay";
 };
 
 &uart2 {
-		status = "okay";
+	status = "okay";
 };
Signature · 1 line
2.3.1
#4 lore raw

PATCH v4 2/5 ARM: dts: Prepare exynos5410-odroidxu device tree

In reply to Andreas Färber

Derived from exynos5410-smdk5410.dts.

---
v1 -> v2 -> v3: Unchanged

 arch/arm/boot/dts/Makefile                |  1 +
 arch/arm/boot/dts/exynos5410-odroidxu.dts | 78 +++++++++++++++++++++++++++++++
 2 files changed, 79 insertions(+)
 create mode 100644 arch/arm/boot/dts/exynos5410-odroidxu.dts
arch/arm/boot/dts/Makefile +1 -0
index a1c776b8dcec..b040737edcbc 100644
@@ -103,6 +103,7 @@ dtb-$(CONFIG_ARCH_EXYNOS5) += \
 	exynos5250-snow.dtb \
 	exynos5250-spring.dtb \
 	exynos5260-xyref5260.dtb \
+	exynos5410-odroidxu.dtb \
 	exynos5410-smdk5410.dtb \
 	exynos5420-arndale-octa.dtb \
 	exynos5420-peach-pit.dtb \
arch/arm/boot/dts/exynos5410-odroidxu.dts new file +78 -0

78 lines not on this page · raw message

Signature · 1 line
2.3.1
#10 lore raw

PATCH v4 3/5 pinctrl: exynos: add exynos5410 SoC specific data

In reply to Andreas Färber

From: Hakjoo Kim <[email protected]>

Add Samsung EXYNOS5410 SoC specific data to enable pinctrl support for all platforms based on EXYNOS5410.

[AF: Rebased onto Exynos5260, irq_chip consolidation, const'ification]

---
v2 -> v3:
* Rebased (.svc, .{g,w}eint_{con,mask,pend} fields dropped)

v1 -> v2:
* Filled in Sob from Hakjoo Kim

 .../bindings/pinctrl/samsung-pinctrl.txt           |   1 +
 drivers/pinctrl/samsung/pinctrl-exynos.c           | 103 +++++++++++++++++++++
 drivers/pinctrl/samsung/pinctrl-samsung.c          |   2 +
 drivers/pinctrl/samsung/pinctrl-samsung.h          |   1 +
 4 files changed, 107 insertions(+)
Documentation/devicetree/bindings/pinctrl/samsung-pinctrl.txt +1 -0
index 9d2a995293e6..6db16b90873a 100644
@@ -17,6 +17,7 @@ Required Properties:
   - "samsung,exynos4x12-pinctrl": for Exynos4x12 compatible pin-controller.
   - "samsung,exynos5250-pinctrl": for Exynos5250 compatible pin-controller.
   - "samsung,exynos5260-pinctrl": for Exynos5260 compatible pin-controller.
+  - "samsung,exynos5410-pinctrl": for Exynos5410 compatible pin-controller.
   - "samsung,exynos5420-pinctrl": for Exynos5420 compatible pin-controller.
   - "samsung,exynos7-pinctrl": for Exynos7 compatible pin-controller.
 
drivers/pinctrl/samsung/pinctrl-exynos.c +103 -0

109 lines not on this page · raw message

drivers/pinctrl/samsung/pinctrl-samsung.c +2 -0
index ec580af35856..1f45636b011d 100644
@@ -1237,6 +1237,8 @@ static const struct of_device_id samsung_pinctrl_dt_match[] = {
 		.data = (void *)exynos5250_pin_ctrl },
 	{ .compatible = "samsung,exynos5260-pinctrl",
 		.data = (void *)exynos5260_pin_ctrl },
+	{ .compatible = "samsung,exynos5410-pinctrl",
+		.data = (void *)exynos5410_pin_ctrl },
 	{ .compatible = "samsung,exynos5420-pinctrl",
 		.data = (void *)exynos5420_pin_ctrl },
 	{ .compatible = "samsung,s5pv210-pinctrl",
drivers/pinctrl/samsung/pinctrl-samsung.h +1 -0
index 1b8c0139d604..b87e2f58ded7 100644
@@ -270,6 +270,7 @@ extern const struct samsung_pin_ctrl exynos4x12_pin_ctrl[];
 extern const struct samsung_pin_ctrl exynos4415_pin_ctrl[];
 extern const struct samsung_pin_ctrl exynos5250_pin_ctrl[];
 extern const struct samsung_pin_ctrl exynos5260_pin_ctrl[];
+extern const struct samsung_pin_ctrl exynos5410_pin_ctrl[];
 extern const struct samsung_pin_ctrl exynos5420_pin_ctrl[];
 extern const struct samsung_pin_ctrl exynos7_pin_ctrl[];
 extern const struct samsung_pin_ctrl s3c64xx_pin_ctrl[];
Signature · 1 line
2.3.1
#13 lore raw

PATCH v4 4/5 ARM: dts: add pinctrl support to Exynos5410

In reply to Andreas Färber

From: Hakjoo Kim <[email protected]>

Add the required pin configuration support to Exynos5410 using pinctrl interface.

[AF: Rebased, style changes]

---
v2 -> v3:
* Added wake-up IRQ controller node (Tomasz Figa)

v1 -> v2:
* Filled in Sob from Hakjoo Kim

 arch/arm/boot/dts/exynos5410-pinctrl.dtsi | 406 ++++++++++++++++++++++++++++++
 arch/arm/boot/dts/exynos5410.dtsi         |  36 +++
 2 files changed, 442 insertions(+)
 create mode 100644 arch/arm/boot/dts/exynos5410-pinctrl.dtsi
arch/arm/boot/dts/exynos5410-pinctrl.dtsi new file +406 -0
new file mode 100644
index 000000000000..f9aa6bb55464
@@ -0,0 +1,406 @@
+/*
+ * Exynos5410 SoC pin-mux and pin-config device tree source
+ *
+ * Copyright (c) 2013 Hardkernel Co., Ltd.
+ *              http://www.hardkernel.com
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ */
+
+&pinctrl_0 {
+	gpa0: gpa0 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpa1: gpa1 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpa2: gpa2 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpb0: gpb0 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpb1: gpb1 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpb2: gpb2 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpb3: gpb3 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpc0: gpc0 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpc3: gpc3 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpc1: gpc1 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpc2: gpc2 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpm5: gpm5 {
+		gpio-controller;
+		#gpio-cells = <2>;
+	};
+
+	gpd1: gpd1 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpe0: gpe0 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpe1: gpe1 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpf0: gpf0 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpf1: gpf1 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpg0: gpg0 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpg1: gpg1 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpg2: gpg2 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gph0: gph0 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gph1: gph1 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpm7: gpm7 {
+		gpio-controller;
+		#gpio-cells = <2>;
+	};
+
+	gpy0: gpy0 {
+		gpio-controller;
+		#gpio-cells = <2>;
+	};
+
+	gpy1: gpy1 {
+		gpio-controller;
+		#gpio-cells = <2>;
+	};
+
+	gpy2: gpy2 {
+		gpio-controller;
+		#gpio-cells = <2>;
+	};
+
+	gpy3: gpy3 {
+		gpio-controller;
+		#gpio-cells = <2>;
+	};
+
+	gpy4: gpy4 {
+		gpio-controller;
+		#gpio-cells = <2>;
+	};
+
+	gpy5: gpy5 {
+		gpio-controller;
+		#gpio-cells = <2>;
+	};
+
+	gpy6: gpy6 {
+		gpio-controller;
+		#gpio-cells = <2>;
+	};
+
+	gpy7: gpy7 {
+		gpio-controller;
+		#gpio-cells = <2>;
+	};
+
+	gpx0: gpx0 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		interrupt-parent = <&combiner>;
+		#interrupt-cells = <2>;
+		interrupts = <23 0>,
+		             <24 0>,
+		             <25 0>,
+		             <25 1>,
+		             <26 0>,
+		             <26 1>,
+		             <27 0>,
+		             <27 1>;
+	};
+
+	gpx1: gpx1 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		interrupt-parent = <&combiner>;
+		#interrupt-cells = <2>;
+		interrupts = <28 0>,
+		             <28 1>,
+		             <29 0>,
+		             <29 1>,
+		             <30 0>,
+		             <30 1>,
+		             <31 0>,
+		             <31 1>;
+	};
+
+	gpx2: gpx2 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpx3: gpx3 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+};
+
+&pinctrl_1 {
+	gpj0: gpj0 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpj1: gpj1 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpj2: gpj2 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpj3: gpj3 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpj4: gpj4 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpk0: gpk0 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpk1: gpk1 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpk2: gpk2 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpk3: gpk3 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+};
+
+&pinctrl_2 {
+	gpv0: gpv0 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpv1: gpv1 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpv2: gpv2 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpv3: gpv3 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+
+	gpv4: gpv4 {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+};
+
+&pinctrl_3 {
+	gpz: gpz {
+		gpio-controller;
+		#gpio-cells = <2>;
+
+		interrupt-controller;
+		#interrupt-cells = <2>;
+	};
+};
arch/arm/boot/dts/exynos5410.dtsi +36 -0
index 731eefd23fa9..460335606466 100644
@@ -21,6 +21,10 @@
 	interrupt-parent = <&gic>;
 
 	aliases {
+		pinctrl0 = &pinctrl_0;
+		pinctrl1 = &pinctrl_1;
+		pinctrl2 = &pinctrl_2;
+		pinctrl3 = &pinctrl_3;
 		serial0 = &uart0;
 		serial1 = &uart1;
 		serial2 = &uart2;
@@ -218,4 +222,36 @@
 			status = "disabled";
 		};
 	};
+
+	pinctrl_0: pinctrl at 13400000 {
+		compatible = "samsung,exynos5410-pinctrl";
+		reg = <0x13400000 0x1000>;
+		interrupts = <0 45 0>;
+
+		wakeup-interrupt-controller {
+			compatible = "samsung,exynos4210-wakeup-eint";
+			interrupt-parent = <&gic>;
+			interrupts = <0 32 0>;
+		};
+	};
+
+	pinctrl_1: pinctrl at 14000000 {
+		compatible = "samsung,exynos5410-pinctrl";
+		reg = <0x14000000 0x1000>;
+		interrupts = <0 46 0>;
+	};
+
+	pinctrl_2: pinctrl at 10d10000 {
+		compatible = "samsung,exynos5410-pinctrl";
+		reg = <0x10d10000 0x1000>;
+		interrupts = <0 50 0>;
+	};
+
+	pinctrl_3: pinctrl at 03860000 {
+		compatible = "samsung,exynos5410-pinctrl";
+		reg = <0x03860000 0x1000>;
+		interrupts = <0 47 0>;
+	};
 };
+
+#include "exynos5410-pinctrl.dtsi"
Signature · 1 line
2.3.1
#15 lore raw

PATCH v4 5/5 ARM: dts: Add LEDs to exynos5410-odroidxu

In reply to Andreas Färber

---
v2 -> v3: Unchanged

v1 -> v2:
* Filled in Sob from Hakjoo Kim

 arch/arm/boot/dts/exynos5410-odroidxu.dts | 25 +++++++++++++++++++++++++
 1 file changed, 25 insertions(+)
arch/arm/boot/dts/exynos5410-odroidxu.dts +25 -0
index 97310bb727e2..b02cd3ab7b38 100644
@@ -15,6 +15,7 @@
 
 /dts-v1/;
 #include "exynos5410.dtsi"
+#include <dt-bindings/gpio/gpio.h>
 / {
 	model = "ODROID-XU based on EXYNOS5410";
 	compatible = "hardkernel,odroid-xu", "samsung,exynos5410", "samsung,exynos5";
@@ -39,6 +40,30 @@
 		reg = <0x02037000 0x1000>;
 	};
 
+	leds {
+		compatible = "gpio-leds";
+
+		blue {
+			label = "blue:heartbeat";
+			gpios = <&gpb2 2 GPIO_ACTIVE_HIGH>;
+			default-state = "off";
+			linux,default-trigger = "heartbeat";
+		};
+
+		green {
+			label = "green:activity";
+			gpios = <&gpb2 1 GPIO_ACTIVE_HIGH>;
+			default-state = "off";
+			linux,default-trigger = "mmc0";
+		};
+
+		red {
+			label = "red:activity";
+			gpios = <&gpx2 3 GPIO_ACTIVE_HIGH>;
+			default-state = "off";
+			linux,default-trigger = "mmc1";
+		};
+	};
 };
 
 &mmc_0 {
Signature · 1 line
2.3.1
Reviewed-by on v4 2/5
#5 lore raw

Re: [PATCH v4 2/5] ARM: dts: Prepare exynos5410-odroidxu device tree

In reply to Andreas Färber

Hello Andreas,

Quoted 48 lines · Andreas F?rber

Derived from exynos5410-smdk5410.dts.

---
v1 -> v2 -> v3: Unchanged

 arch/arm/boot/dts/Makefile                |  1 +
 arch/arm/boot/dts/exynos5410-odroidxu.dts | 78 +++++++++++++++++++++++++++++++
 2 files changed, 79 insertions(+)
 create mode 100644 arch/arm/boot/dts/exynos5410-odroidxu.dts
arch/arm/boot/dts/Makefile +1 -0
index a1c776b8dcec..b040737edcbc 100644
@@ -103,6 +103,7 @@ dtb-$(CONFIG_ARCH_EXYNOS5) += \
        exynos5250-snow.dtb \
        exynos5250-spring.dtb \
        exynos5260-xyref5260.dtb \
+       exynos5410-odroidxu.dtb \
        exynos5410-smdk5410.dtb \
        exynos5420-arndale-octa.dtb \
        exynos5420-peach-pit.dtb \
arch/arm/boot/dts/exynos5410-odroidxu.dts new file +19 -0
new file mode 100644
index 000000000000..97310bb727e2
@@ -0,0 +1,78 @@
+/*
+ * Hardkernel ODROID-XU device tree source
+ *
+ * Copyright (c) 2014 SUSE LINUX Products GmbH
+ *
+ * Based on exynos5410-smdk5410.dts:
+ *
+ * Copyright (c) 2013 Samsung Electronics Co., Ltd.
+ *             http://www.samsung.com
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+*/
+
+/dts-v1/;
+#include "exynos5410.dtsi"
+/ {
+       model = "ODROID-XU based on EXYNOS5410";

arch/arm/boot/dts/exynos5410-odroidxu.dts line 29

Quoted 10 lines
arch/arm/boot/dts/exynos5410-odroidxu.dts new file +10 -0
+       compatible = "hardkernel,odroid-xu", "samsung,exynos5410", "samsung,exynos5";
+
+       memory {
+               reg = <0x40000000 0x80000000>;
+       };
+
+       chosen {
+               bootargs = "console=ttySAC2,115200";
+       };
+

After commit a208ffd251d0 ("of: Enable console on serial ports specified by /chosen/stdout-path") the kernel is able to know what serial console to use if the DT defined an stdout-path property so should be preferred instead of using a console= parameter.

I'll post today a series to change that on all exynos5 boards so you can base on that.

arch/arm/boot/dts/exynos5410-odroidxu.dts line 36

Quoted 7 lines
arch/arm/boot/dts/exynos5410-odroidxu.dts new file +7 -0
+       fin_pll: xxti {
+               compatible = "fixed-clock";
+               clock-frequency = <24000000>;
+               clock-output-names = "fin_pll";
+               #clock-cells = <0>;
+       };
+

I think this should be defined in exynos5410.dtsi instead since is an IP block in the SoC and referenced in the .dts using a label to change the clock-frequency in the board.

Quoted 33 lines
arch/arm/boot/dts/exynos5410-odroidxu.dts new file +33 -0
+       firmware at 02037000 {
+               compatible = "samsung,secure-firmware";
+               reg = <0x02037000 0x1000>;
+       };
+
+};
+
+&mmc_0 {
+       status = "okay";
+       num-slots = <1>;
+       cap-mmc-highspeed;
+       broken-cd;
+       card-detect-delay = <200>;
+       samsung,dw-mshc-ciu-div = <3>;
+       samsung,dw-mshc-sdr-timing = <2 3>;
+       samsung,dw-mshc-ddr-timing = <1 2>;
+       bus-width = <8>;
+};
+
+&mmc_2 {
+       status = "okay";
+       num-slots = <1>;
+       cap-sd-highspeed;
+       card-detect-delay = <200>;
+       samsung,dw-mshc-ciu-div = <3>;
+       samsung,dw-mshc-sdr-timing = <2 3>;
+       samsung,dw-mshc-ddr-timing = <1 2>;
+       bus-width = <4>;
+       disable-wp;
+};
+
+&uart0 {
+       status = "okay";

arch/arm/boot/dts/exynos5410-odroidxu.dts

Quoted 10 lines
arch/arm/boot/dts/exynos5410-odroidxu.dts new file +9 -1
+};
+
+&uart1 {
+       status = "okay";
+};
+
+&uart2 {
+       status = "okay";
+};
--

With those two changes:

Best regards,
Javier

Reviewed-by on v4 5/5
#16 lore raw

Re: [PATCH v4 5/5] ARM: dts: Add LEDs to exynos5410-odroidxu

In reply to Andreas Färber

Hello Andreas,

Quoted 40 lines · Andreas F?rber

---
v2 -> v3: Unchanged

v1 -> v2:
* Filled in Sob from Hakjoo Kim

 arch/arm/boot/dts/exynos5410-odroidxu.dts | 25 +++++++++++++++++++++++++
 1 file changed, 25 insertions(+)
arch/arm/boot/dts/exynos5410-odroidxu.dts +14 -0
index 97310bb727e2..b02cd3ab7b38 100644
@@ -15,6 +15,7 @@
 
 /dts-v1/;
 #include "exynos5410.dtsi"
+#include <dt-bindings/gpio/gpio.h>
 / {
        model = "ODROID-XU based on EXYNOS5410";
        compatible = "hardkernel,odroid-xu", "samsung,exynos5410", "samsung,exynos5";
@@ -39,6 +40,30 @@
                reg = <0x02037000 0x1000>;
        };
 
+       leds {
+               compatible = "gpio-leds";
+
+               blue {
+                       label = "blue:heartbeat";
+                       gpios = <&gpb2 2 GPIO_ACTIVE_HIGH>;
+                       default-state = "off";
+                       linux,default-trigger = "heartbeat";
+               };
+
+               green {
+                       label = "green:activity";
+                       gpios = <&gpb2 1 GPIO_ACTIVE_HIGH>;

arch/arm/boot/dts/exynos5410-odroidxu.dts line 65

Quoted 10 lines
arch/arm/boot/dts/exynos5410-odroidxu.dts +10 -0
+                       default-state = "off";
+                       linux,default-trigger = "mmc0";
+               };
+
+               red {
+                       label = "red:activity";
+                       gpios = <&gpx2 3 GPIO_ACTIVE_HIGH>;
+                       default-state = "off";
+                       linux,default-trigger = "mmc1";
+               };

I see that you are sorting alphabetically using the node name but for example in pinctrl lines we were sorting using the GPIO bank and offset so if we want to use the same policy here, this should be green, blue and red.

Either way is good to me though so is up to you.

Best regards,
Javier

#6 lore raw

Re: [PATCH v4 2/5] ARM: dts: Prepare exynos5410-odroidxu device tree

In reply to Javier Martinez Canillas

Hi Javier,

Am 16.03.2015 um 08:56 schrieb Javier Martinez Canillas:

Quoted 6 lines · Andreas F?rber
Quoted 5 lines

Derived from exynos5410-smdk5410.dts.

---
v1 -> v2 -> v3: Unchanged

Forgot to update the in-patch changelogs: v4 is unchanged as well

Quoted 59 lines
Quoted 43 lines
 arch/arm/boot/dts/Makefile                |  1 +
 arch/arm/boot/dts/exynos5410-odroidxu.dts | 78 +++++++++++++++++++++++++++++++
 2 files changed, 79 insertions(+)
 create mode 100644 arch/arm/boot/dts/exynos5410-odroidxu.dts
arch/arm/boot/dts/Makefile +1 -0
index a1c776b8dcec..b040737edcbc 100644
@@ -103,6 +103,7 @@ dtb-$(CONFIG_ARCH_EXYNOS5) += \
        exynos5250-snow.dtb \
        exynos5250-spring.dtb \
        exynos5260-xyref5260.dtb \
+       exynos5410-odroidxu.dtb \
        exynos5410-smdk5410.dtb \
        exynos5420-arndale-octa.dtb \
        exynos5420-peach-pit.dtb \
arch/arm/boot/dts/exynos5410-odroidxu.dts new file +19 -0
new file mode 100644
index 000000000000..97310bb727e2
@@ -0,0 +1,78 @@
+/*
+ * Hardkernel ODROID-XU device tree source
+ *
+ * Copyright (c) 2014 SUSE LINUX Products GmbH
+ *
+ * Based on exynos5410-smdk5410.dts:
+ *
+ * Copyright (c) 2013 Samsung Electronics Co., Ltd.
+ *             http://www.samsung.com
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+*/
+
+/dts-v1/;
+#include "exynos5410.dtsi"
+/ {
+       model = "ODROID-XU based on EXYNOS5410";

arch/arm/boot/dts/exynos5410-odroidxu.dts line 29

Quoted 10 lines
arch/arm/boot/dts/exynos5410-odroidxu.dts new file +10 -0
+       compatible = "hardkernel,odroid-xu", "samsung,exynos5410", "samsung,exynos5";
+
+       memory {
+               reg = <0x40000000 0x80000000>;
+       };
+
+       chosen {
+               bootargs = "console=ttySAC2,115200";
+       };
+

After commit a208ffd251d0 ("of: Enable console on serial ports specified by /chosen/stdout-path") the kernel is able to know what serial console to use if the DT defined an stdout-path property so should be preferred instead of using a console= parameter.

Quoted 2 lines

I'll post today a series to change that on all exynos5 boards so you can base on that.

Okay, if no one else does, I could update smdk5410 before splitting.

Quoted 11 lines

arch/arm/boot/dts/exynos5410-odroidxu.dts line 36

Quoted 7 lines
arch/arm/boot/dts/exynos5410-odroidxu.dts new file +7 -0
+       fin_pll: xxti {
+               compatible = "fixed-clock";
+               clock-frequency = <24000000>;
+               clock-output-names = "fin_pll";
+               #clock-cells = <0>;
+       };
+

I think this should be defined in exynos5410.dtsi instead since is an IP block in the SoC and referenced in the .dts using a label to change the clock-frequency in the board.

I hope you understood that this is a literal copy of smdk5410, so I'm not going to make random changes here. If the Samsung guys want to make this change for smdk5410, then fine, but otherwise - like for Snow and Spring - I want to keep the diff -u low between the two.

Quoted 46 lines
Quoted 33 lines
arch/arm/boot/dts/exynos5410-odroidxu.dts new file +33 -0
+       firmware at 02037000 {
+               compatible = "samsung,secure-firmware";
+               reg = <0x02037000 0x1000>;
+       };
+
+};
+
+&mmc_0 {
+       status = "okay";
+       num-slots = <1>;
+       cap-mmc-highspeed;
+       broken-cd;
+       card-detect-delay = <200>;
+       samsung,dw-mshc-ciu-div = <3>;
+       samsung,dw-mshc-sdr-timing = <2 3>;
+       samsung,dw-mshc-ddr-timing = <1 2>;
+       bus-width = <8>;
+};
+
+&mmc_2 {
+       status = "okay";
+       num-slots = <1>;
+       cap-sd-highspeed;
+       card-detect-delay = <200>;
+       samsung,dw-mshc-ciu-div = <3>;
+       samsung,dw-mshc-sdr-timing = <2 3>;
+       samsung,dw-mshc-ddr-timing = <1 2>;
+       bus-width = <4>;
+       disable-wp;
+};
+
+&uart0 {
+       status = "okay";

arch/arm/boot/dts/exynos5410-odroidxu.dts

Quoted 10 lines
arch/arm/boot/dts/exynos5410-odroidxu.dts new file +9 -1
+};
+
+&uart1 {
+       status = "okay";
+};
+
+&uart2 {
+       status = "okay";
+};
--

With those two changes:

Quoted 1 line

Thanks, first review after posting for the third time... ;)

Regards,
Andreas

Signature · 3 lines
SUSE Linux GmbH, Maxfeldstr. 5, 90409 N?rnberg, Germany
GF: Felix Imend?rffer, Jane Smithard, Jennifer Guild, Dilip Upmanyu,
Graham Norton; HRB 21284 (AG N?rnberg)
#7 lore raw

Re: [PATCH v4 2/5] ARM: dts: Prepare exynos5410-odroidxu device tree

Hello Andreas,

Quoted 11 lines · Andreas F?rber

Am 16.03.2015 um 08:56 schrieb Javier Martinez Canillas:

Quoted 4 lines

I think this should be defined in exynos5410.dtsi instead since is an IP block in the SoC and referenced in the .dts using a label to change the clock-frequency in the board.

I hope you understood that this is a literal copy of smdk5410, so I'm not going to make random changes here. If the Samsung guys want to make this change for smdk5410, then fine, but otherwise - like for Snow and Spring - I want to keep the diff -u low between the two.

Yes I did understand that it was a copy but I thought it could be improved anyways. But I don't have a strong opinion either to block this series and always both DTS can be changed as a follow-up. So I'm ok with your decision to keeping the delta to the minimum for now.

Quoted 5 lines
Quoted 2 lines

Thanks, first review after posting for the third time... ;)

You are welcome.

I usually try to review new Exynos5 DTS but I missed your series before because I was not in the cc list. I only noticed now because you talked about it on irc.

Quoted 3 lines

Regards,
Andreas

Best regards,
Javier

#8 lore raw

RE: [PATCH v4 2/5] ARM: dts: Prepare exynos5410-odroidxu device tree

Quoted 3 lines · Javier Martinez Canillas

Hello Andreas,

Hi,

Quoted 13 lines · Andreas F?rber
Quoted 11 lines

Am 16.03.2015 um 08:56 schrieb Javier Martinez Canillas:

Quoted 4 lines

I think this should be defined in exynos5410.dtsi instead since is an IP block in the SoC and referenced in the .dts using a label to change the clock-frequency in the board.

I hope you understood that this is a literal copy of smdk5410, so I'm not going to make random changes here. If the Samsung guys want to make this change for smdk5410, then fine, but otherwise - like for Snow and Spring - I want to keep the diff -u low between the two.

Quoted 5 lines

Yes I did understand that it was a copy but I thought it could be improved anyways. But I don't have a strong opinion either to block this series and always both DTS can be changed as a follow-up. So I'm ok with your decision to keeping the delta to the minimum for now.

Yeah, everybody can update everything in mainline if it can be got review in mailinglist. BTW asthe fin_pll can be different according to board condition that's why it is defined in each boart DT file, it is mostly same on each boards though...So I think keeping it would be more make sense.

Thanks,
Kukjin

Acked-by on v4 3/5
#11 lore raw

Re: [PATCH v4 3/5] pinctrl: exynos: add exynos5410 SoC specific data

In reply to Andreas Färber

Hi Andreas, Hakjoo,

Thanks for the patch.

2015-03-16 7:00 GMT+09:00 Andreas F?rber <[email protected]>:

Quoted 12 lines

From: Hakjoo Kim <[email protected]>

Add Samsung EXYNOS5410 SoC specific data to enable pinctrl support for all platforms based on EXYNOS5410.

[AF: Rebased onto Exynos5260, irq_chip consolidation, const'ification]

---
v2 -> v3:
* Rebased (.svc, .{g,w}eint_{con,mask,pend} fields dropped)

Quoted 9 lines

v1 -> v2:
* Filled in Sob from Hakjoo Kim

 .../bindings/pinctrl/samsung-pinctrl.txt           |   1 +
 drivers/pinctrl/samsung/pinctrl-exynos.c           | 103 +++++++++++++++++++++
 drivers/pinctrl/samsung/pinctrl-samsung.c          |   2 +
 drivers/pinctrl/samsung/pinctrl-samsung.h          |   1 +
 4 files changed, 107 insertions(+)

Best regards,
Tomasz

#20 lore raw
In reply to Andreas Färber
Quoted 5 lines · Andreas F?rber

Hello,

This series adds a dedicated ODROID-XU device tree and enhances it with LED configuration, to match the downstream 3.14 based behavior.

Any word on merging this?

Cheers,

- Ben
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 472 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20150331/fc608a74/attachment.sig>

#9 lore raw

Re: [PATCH v4 2/5] ARM: dts: Prepare exynos5410-odroidxu device tree

In reply to Andreas Färber

W dniu 16.03.2015 o 19:27, Andreas F?rber pisze:

Quoted 71 lines

Hi Javier,

Am 16.03.2015 um 08:56 schrieb Javier Martinez Canillas:

Quoted 6 lines · Andreas F?rber
Quoted 5 lines

Derived from exynos5410-smdk5410.dts.

---
v1 -> v2 -> v3: Unchanged

Forgot to update the in-patch changelogs: v4 is unchanged as well

Quoted 59 lines
Quoted 43 lines
 arch/arm/boot/dts/Makefile                |  1 +
 arch/arm/boot/dts/exynos5410-odroidxu.dts | 78 +++++++++++++++++++++++++++++++
 2 files changed, 79 insertions(+)
 create mode 100644 arch/arm/boot/dts/exynos5410-odroidxu.dts
arch/arm/boot/dts/Makefile +1 -0
index a1c776b8dcec..b040737edcbc 100644
@@ -103,6 +103,7 @@ dtb-$(CONFIG_ARCH_EXYNOS5) += \
        exynos5250-snow.dtb \
        exynos5250-spring.dtb \
        exynos5260-xyref5260.dtb \
+       exynos5410-odroidxu.dtb \
        exynos5410-smdk5410.dtb \
        exynos5420-arndale-octa.dtb \
        exynos5420-peach-pit.dtb \
arch/arm/boot/dts/exynos5410-odroidxu.dts new file +19 -0
new file mode 100644
index 000000000000..97310bb727e2
@@ -0,0 +1,78 @@
+/*
+ * Hardkernel ODROID-XU device tree source
+ *
+ * Copyright (c) 2014 SUSE LINUX Products GmbH
+ *
+ * Based on exynos5410-smdk5410.dts:
+ *
+ * Copyright (c) 2013 Samsung Electronics Co., Ltd.
+ *             http://www.samsung.com
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+*/
+
+/dts-v1/;
+#include "exynos5410.dtsi"
+/ {
+       model = "ODROID-XU based on EXYNOS5410";

arch/arm/boot/dts/exynos5410-odroidxu.dts line 29

Quoted 10 lines
arch/arm/boot/dts/exynos5410-odroidxu.dts new file +10 -0
+       compatible = "hardkernel,odroid-xu", "samsung,exynos5410", "samsung,exynos5";
+
+       memory {
+               reg = <0x40000000 0x80000000>;
+       };
+
+       chosen {
+               bootargs = "console=ttySAC2,115200";
+       };
+

After commit a208ffd251d0 ("of: Enable console on serial ports specified by /chosen/stdout-path") the kernel is able to know what serial console to use if the DT defined an stdout-path property so should be preferred instead of using a console= parameter.

Quoted 4 lines
Quoted 2 lines

I'll post today a series to change that on all exynos5 boards so you can base on that.

Okay, if no one else does, I could update smdk5410 before splitting.

Could you do this? At least for new board if you cannot test it on SMDK5410.

Quoted 9 lines
Quoted 9 lines
Quoted 8 lines
arch/arm/boot/dts/exynos5410-odroidxu.dts new file +7 -0
+       fin_pll: xxti {
+               compatible = "fixed-clock";
+               clock-frequency = <24000000>;
+               clock-output-names = "fin_pll";
+               #clock-cells = <0>;
+       };
+
Quoted 8 lines
Quoted 3 lines

I think this should be defined in exynos5410.dtsi instead since is an IP block in the SoC and referenced in the .dts using a label to change the clock-frequency in the board.

I hope you understood that this is a literal copy of smdk5410, so I'm not going to make random changes here. If the Samsung guys want to make this change for smdk5410, then fine, but otherwise - like for Snow and Spring - I want to keep the diff -u low between the two.

Moving the node to DTSI won't change the DTB for boards so the change is safe. However to me it looks unusual that exynos5410.dtsi references fin_pll phandle which is defined in the board.

However Kukjin mentioned that it is fine so it is okay with me also.

The rest looks fine, so:

Best regards,
Krzysztof

#12 lore raw

Re: [PATCH v4 3/5] pinctrl: exynos: add exynos5410 SoC specific data

In reply to Tomasz Figa

W dniu 24.03.2015 o 02:22, Tomasz Figa pisze:

Quoted 20 lines

Hi Andreas, Hakjoo,

Thanks for the patch.

2015-03-16 7:00 GMT+09:00 Andreas F?rber <[email protected]>:

Quoted 15 lines

From: Hakjoo Kim <[email protected]>

Add Samsung EXYNOS5410 SoC specific data to enable pinctrl support for all platforms based on EXYNOS5410.

[AF: Rebased onto Exynos5260, irq_chip consolidation, const'ification]

---
v2 -> v3:
* Rebased (.svc, .{g,w}eint_{con,mask,pend} fields dropped)

v1 -> v2:
* Filled in Sob from Hakjoo Kim

Quoted 8 lines
Quoted 6 lines
 .../bindings/pinctrl/samsung-pinctrl.txt           |   1 +
 drivers/pinctrl/samsung/pinctrl-exynos.c           | 103 +++++++++++++++++++++
 drivers/pinctrl/samsung/pinctrl-samsung.c          |   2 +
 drivers/pinctrl/samsung/pinctrl-samsung.h          |   1 +
 4 files changed, 107 insertions(+)

So I assume this may go through Kukjin tree.

Best regards,
Krzysztof

Reviewed-by on v4 1/5 Applied
#3 lore raw

Re: [PATCH v4 1/5] ARM: dts: Clean up exynos5410-smdk5410 indentation

In reply to Andreas Färber

W dniu 16.03.2015 o 07:00, Andreas F?rber pisze:

Quoted 4 lines

The UART status properties are indented one level too deep, and we want to derive a device tree for the ODROID-XU. Fix this before it propagates.

Applied to my tree. If Kukjin won't grab it from here, I'll push it later to Kukjin depending on other pull requests.

Best regards,
Krzysztof

Reviewed-by on v4 4/5
#14 lore raw

Re: [PATCH v4 4/5] ARM: dts: add pinctrl support to Exynos5410

In reply to Andreas Färber

W dniu 16.03.2015 o 07:00, Andreas F?rber pisze:

Quoted 12 lines

From: Hakjoo Kim <[email protected]>

Add the required pin configuration support to Exynos5410 using pinctrl interface.

[AF: Rebased, style changes]

---
v2 -> v3:
* Added wake-up IRQ controller node (Tomasz Figa)

Quoted 7 lines

v1 -> v2:
* Filled in Sob from Hakjoo Kim

 arch/arm/boot/dts/exynos5410-pinctrl.dtsi | 406 ++++++++++++++++++++++++++++++
 arch/arm/boot/dts/exynos5410.dtsi         |  36 +++
 2 files changed, 442 insertions(+)
 create mode 100644 arch/arm/boot/dts/exynos5410-pinctrl.dtsi

Changes look fine:

Best regards,
Krzysztof

#17 lore raw

Re: [PATCH v4 5/5] ARM: dts: Add LEDs to exynos5410-odroidxu

In reply to Andreas Färber

W dniu 16.03.2015 o 07:00, Andreas F?rber pisze:

Quoted 10 lines

---
v2 -> v3: Unchanged

v1 -> v2:
* Filled in Sob from Hakjoo Kim

 arch/arm/boot/dts/exynos5410-odroidxu.dts | 25 +++++++++++++++++++++++++
 1 file changed, 25 insertions(+)

What is the rationale behind doing this in separate patch, not as part of 2/5? You can just add new board DTS with all of its features at once, but maybe I am missing something?

Best regards,
Krzysztof

#18 lore raw

Re: [PATCH v4 5/5] ARM: dts: Add LEDs to exynos5410-odroidxu

Am 02.06.2015 um 22:02 schrieb Krzysztof Kozlowski:

Quoted 9 lines

W dniu 16.03.2015 o 07:00, Andreas F?rber pisze:

Quoted 8 lines

---
v2 -> v3: Unchanged

v1 -> v2:
* Filled in Sob from Hakjoo Kim

Quoted 6 lines
Quoted 2 lines
 arch/arm/boot/dts/exynos5410-odroidxu.dts | 25 +++++++++++++++++++++++++
 1 file changed, 25 insertions(+)

What is the rationale behind doing this in separate patch, not as part of 2/5? You can just add new board DTS with all of its features at once, but maybe I am missing something?

This patch depends on the pinctrl driver, 2/5 on nothing.

By keeping it a separate patch it was intended to go in more quickly (clear fail there ;)) and it's easier to review the actual changes - squashing is always easier than picking apart.

Thanks for your review! Both me and Ben have follow-ups once this moves forward.

Kind regards,
Andreas

Signature · 3 lines
SUSE Linux GmbH, Maxfeldstr. 5, 90409 N?rnberg, Germany
GF: Felix Imend?rffer, Jane Smithard, Dilip Upmanyu, Graham Norton; HRB
21284 (AG N?rnberg)
#19 lore raw

Re: [PATCH v4 5/5] ARM: dts: Add LEDs to exynos5410-odroidxu

Quoted 17 lines · Andreas F?rber

Am 02.06.2015 um 22:02 schrieb Krzysztof Kozlowski:

Quoted 9 lines

W dniu 16.03.2015 o 07:00, Andreas F?rber pisze:

Quoted 8 lines

---
v2 -> v3: Unchanged

v1 -> v2:
* Filled in Sob from Hakjoo Kim

Quoted 6 lines
Quoted 2 lines
 arch/arm/boot/dts/exynos5410-odroidxu.dts | 25 +++++++++++++++++++++++++
 1 file changed, 25 insertions(+)

What is the rationale behind doing this in separate patch, not as part of 2/5? You can just add new board DTS with all of its features at once, but maybe I am missing something?

Quoted 5 lines

This patch depends on the pinctrl driver, 2/5 on nothing.

By keeping it a separate patch it was intended to go in more quickly (clear fail there ;)) and it's easier to review the actual changes - squashing is always easier than picking apart.

OK, I'm fine with it.

The patch looks good:

Can you resend everything with the change in chosen/console?

Best regards,
Krzysztof