All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/6] dt-bindings: clock: Add TMU clock ID to Exynos5410
@ 2016-05-31 18:39 ` Krzysztof Kozlowski
  0 siblings, 0 replies; 34+ messages in thread
From: Krzysztof Kozlowski @ 2016-05-31 18:39 UTC (permalink / raw)
  To: Kukjin Kim, Krzysztof Kozlowski, Sylwester Nawrocki, Tomasz Figa,
	Michael Turquette, Stephen Boyd, Javier Martinez Canillas,
	devicetree, linux-arm-kernel, linux-samsung-soc, linux-kernel,
	linux-clk
  Cc: Krzysztof Kozlowski

Add ID for TMU clock to Exynos5410. Use the same number as for
Exynos5420 just in case in future these drivers were merged.

Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
---
 include/dt-bindings/clock/exynos5410.h | 1 +
 1 file changed, 1 insertion(+)

diff --git a/include/dt-bindings/clock/exynos5410.h b/include/dt-bindings/clock/exynos5410.h
index e94b7bbfd6af..705b2aa84317 100644
--- a/include/dt-bindings/clock/exynos5410.h
+++ b/include/dt-bindings/clock/exynos5410.h
@@ -50,6 +50,7 @@
 #define CLK_PWM			279
 #define CLK_MCT			315
 #define CLK_RTC			317
+#define CLK_TMU			318
 #define CLK_MMC0		351
 #define CLK_MMC1		352
 #define CLK_MMC2		353
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 34+ messages in thread

* [PATCH 1/6] dt-bindings: clock: Add TMU clock ID to Exynos5410
@ 2016-05-31 18:39 ` Krzysztof Kozlowski
  0 siblings, 0 replies; 34+ messages in thread
From: Krzysztof Kozlowski @ 2016-05-31 18:39 UTC (permalink / raw)
  To: linux-arm-kernel

Add ID for TMU clock to Exynos5410. Use the same number as for
Exynos5420 just in case in future these drivers were merged.

Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
---
 include/dt-bindings/clock/exynos5410.h | 1 +
 1 file changed, 1 insertion(+)

diff --git a/include/dt-bindings/clock/exynos5410.h b/include/dt-bindings/clock/exynos5410.h
index e94b7bbfd6af..705b2aa84317 100644
--- a/include/dt-bindings/clock/exynos5410.h
+++ b/include/dt-bindings/clock/exynos5410.h
@@ -50,6 +50,7 @@
 #define CLK_PWM			279
 #define CLK_MCT			315
 #define CLK_RTC			317
+#define CLK_TMU			318
 #define CLK_MMC0		351
 #define CLK_MMC1		352
 #define CLK_MMC2		353
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 34+ messages in thread

* [PATCH 2/6] clk: samsung: exynos5410: Add TMU clock
  2016-05-31 18:39 ` Krzysztof Kozlowski
@ 2016-05-31 18:39   ` Krzysztof Kozlowski
  -1 siblings, 0 replies; 34+ messages in thread
From: Krzysztof Kozlowski @ 2016-05-31 18:39 UTC (permalink / raw)
  To: Kukjin Kim, Krzysztof Kozlowski, Sylwester Nawrocki, Tomasz Figa,
	Michael Turquette, Stephen Boyd, Javier Martinez Canillas,
	devicetree, linux-arm-kernel, linux-samsung-soc, linux-kernel,
	linux-clk
  Cc: Krzysztof Kozlowski

Add clock for TMU to the Exynos5410 clock driver.

Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
---
 drivers/clk/samsung/clk-exynos5410.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/clk/samsung/clk-exynos5410.c b/drivers/clk/samsung/clk-exynos5410.c
index 6c2e59c576ee..db9978dc6e83 100644
--- a/drivers/clk/samsung/clk-exynos5410.c
+++ b/drivers/clk/samsung/clk-exynos5410.c
@@ -160,6 +160,7 @@ static struct samsung_div_clock exynos5410_div_clks[] __initdata = {
 static struct samsung_gate_clock exynos5410_gate_clks[] __initdata = {
 	GATE(CLK_MCT, "mct", "aclk66", GATE_IP_PERIS, 18, 0, 0),
 	GATE(CLK_RTC, "rtc", "aclk66", GATE_IP_PERIS, 20, 0, 0),
+	GATE(CLK_TMU, "tmu", "aclk66", GATE_IP_PERIS, 21, 0, 0),
 
 	GATE(CLK_SCLK_MMC0, "sclk_mmc0", "div_mmc_pre0",
 			SRC_MASK_FSYS, 0, CLK_SET_RATE_PARENT, 0),
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 34+ messages in thread

* [PATCH 2/6] clk: samsung: exynos5410: Add TMU clock
@ 2016-05-31 18:39   ` Krzysztof Kozlowski
  0 siblings, 0 replies; 34+ messages in thread
From: Krzysztof Kozlowski @ 2016-05-31 18:39 UTC (permalink / raw)
  To: linux-arm-kernel

Add clock for TMU to the Exynos5410 clock driver.

Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
---
 drivers/clk/samsung/clk-exynos5410.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/clk/samsung/clk-exynos5410.c b/drivers/clk/samsung/clk-exynos5410.c
index 6c2e59c576ee..db9978dc6e83 100644
--- a/drivers/clk/samsung/clk-exynos5410.c
+++ b/drivers/clk/samsung/clk-exynos5410.c
@@ -160,6 +160,7 @@ static struct samsung_div_clock exynos5410_div_clks[] __initdata = {
 static struct samsung_gate_clock exynos5410_gate_clks[] __initdata = {
 	GATE(CLK_MCT, "mct", "aclk66", GATE_IP_PERIS, 18, 0, 0),
 	GATE(CLK_RTC, "rtc", "aclk66", GATE_IP_PERIS, 20, 0, 0),
+	GATE(CLK_TMU, "tmu", "aclk66", GATE_IP_PERIS, 21, 0, 0),
 
 	GATE(CLK_SCLK_MMC0, "sclk_mmc0", "div_mmc_pre0",
 			SRC_MASK_FSYS, 0, CLK_SET_RATE_PARENT, 0),
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 34+ messages in thread

* [PATCH 3/6] ARM: dts: exynos: Interrupt for USB DWC3-1 differs between Exynos5420 and 5410
  2016-05-31 18:39 ` Krzysztof Kozlowski
@ 2016-05-31 18:39   ` Krzysztof Kozlowski
  -1 siblings, 0 replies; 34+ messages in thread
From: Krzysztof Kozlowski @ 2016-05-31 18:39 UTC (permalink / raw)
  To: Kukjin Kim, Krzysztof Kozlowski, Sylwester Nawrocki, Tomasz Figa,
	Michael Turquette, Stephen Boyd, Javier Martinez Canillas,
	devicetree, linux-arm-kernel, linux-samsung-soc, linux-kernel,
	linux-clk
  Cc: Krzysztof Kozlowski

On Exynos5410 the SPI interrupt for second USB DWC3 (called DRD: Dual
Role Device) is different - 200 instead of 73.

Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
---
 arch/arm/boot/dts/exynos5410.dtsi | 4 ++++
 arch/arm/boot/dts/exynos5420.dtsi | 4 ++++
 arch/arm/boot/dts/exynos54xx.dtsi | 1 -
 3 files changed, 8 insertions(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/exynos5410.dtsi b/arch/arm/boot/dts/exynos5410.dtsi
index a937d9bdad90..994d16a44fe4 100644
--- a/arch/arm/boot/dts/exynos5410.dtsi
+++ b/arch/arm/boot/dts/exynos5410.dtsi
@@ -267,6 +267,10 @@
 	clock-names = "usbdrd30";
 };
 
+&usbdrd_dwc3_1 {
+	interrupts = <0 200 0>;
+};
+
 &usbdrd_phy1 {
 	clocks = <&clock CLK_USBD301>, <&clock CLK_SCLK_USBPHY301>;
 	clock-names = "phy", "ref";
diff --git a/arch/arm/boot/dts/exynos5420.dtsi b/arch/arm/boot/dts/exynos5420.dtsi
index 8b1e706e9250..265747bb19d1 100644
--- a/arch/arm/boot/dts/exynos5420.dtsi
+++ b/arch/arm/boot/dts/exynos5420.dtsi
@@ -1046,6 +1046,10 @@
 	clock-names = "usbdrd30";
 };
 
+&usbdrd_dwc3_1 {
+	interrupts = <0 73 0>;
+};
+
 &usbdrd_phy1 {
 	clocks = <&clock CLK_USBD301>, <&clock CLK_SCLK_USBPHY301>;
 	clock-names = "phy", "ref";
diff --git a/arch/arm/boot/dts/exynos54xx.dtsi b/arch/arm/boot/dts/exynos54xx.dtsi
index 44a8391c8524..0eb8aa31b7d9 100644
--- a/arch/arm/boot/dts/exynos54xx.dtsi
+++ b/arch/arm/boot/dts/exynos54xx.dtsi
@@ -141,7 +141,6 @@
 			usbdrd_dwc3_1: dwc3@12400000 {
 				compatible = "snps,dwc3";
 				reg = <0x12400000 0x10000>;
-				interrupts = <0 73 0>;
 				phys = <&usbdrd_phy1 0>, <&usbdrd_phy1 1>;
 				phy-names = "usb2-phy", "usb3-phy";
 			};
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 34+ messages in thread

* [PATCH 3/6] ARM: dts: exynos: Interrupt for USB DWC3-1 differs between Exynos5420 and 5410
@ 2016-05-31 18:39   ` Krzysztof Kozlowski
  0 siblings, 0 replies; 34+ messages in thread
From: Krzysztof Kozlowski @ 2016-05-31 18:39 UTC (permalink / raw)
  To: linux-arm-kernel

On Exynos5410 the SPI interrupt for second USB DWC3 (called DRD: Dual
Role Device) is different - 200 instead of 73.

Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
---
 arch/arm/boot/dts/exynos5410.dtsi | 4 ++++
 arch/arm/boot/dts/exynos5420.dtsi | 4 ++++
 arch/arm/boot/dts/exynos54xx.dtsi | 1 -
 3 files changed, 8 insertions(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/exynos5410.dtsi b/arch/arm/boot/dts/exynos5410.dtsi
index a937d9bdad90..994d16a44fe4 100644
--- a/arch/arm/boot/dts/exynos5410.dtsi
+++ b/arch/arm/boot/dts/exynos5410.dtsi
@@ -267,6 +267,10 @@
 	clock-names = "usbdrd30";
 };
 
+&usbdrd_dwc3_1 {
+	interrupts = <0 200 0>;
+};
+
 &usbdrd_phy1 {
 	clocks = <&clock CLK_USBD301>, <&clock CLK_SCLK_USBPHY301>;
 	clock-names = "phy", "ref";
diff --git a/arch/arm/boot/dts/exynos5420.dtsi b/arch/arm/boot/dts/exynos5420.dtsi
index 8b1e706e9250..265747bb19d1 100644
--- a/arch/arm/boot/dts/exynos5420.dtsi
+++ b/arch/arm/boot/dts/exynos5420.dtsi
@@ -1046,6 +1046,10 @@
 	clock-names = "usbdrd30";
 };
 
+&usbdrd_dwc3_1 {
+	interrupts = <0 73 0>;
+};
+
 &usbdrd_phy1 {
 	clocks = <&clock CLK_USBD301>, <&clock CLK_SCLK_USBPHY301>;
 	clock-names = "phy", "ref";
diff --git a/arch/arm/boot/dts/exynos54xx.dtsi b/arch/arm/boot/dts/exynos54xx.dtsi
index 44a8391c8524..0eb8aa31b7d9 100644
--- a/arch/arm/boot/dts/exynos54xx.dtsi
+++ b/arch/arm/boot/dts/exynos54xx.dtsi
@@ -141,7 +141,6 @@
 			usbdrd_dwc3_1: dwc3 at 12400000 {
 				compatible = "snps,dwc3";
 				reg = <0x12400000 0x10000>;
-				interrupts = <0 73 0>;
 				phys = <&usbdrd_phy1 0>, <&usbdrd_phy1 1>;
 				phy-names = "usb2-phy", "usb3-phy";
 			};
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 34+ messages in thread

* [PATCH 4/6] ARM: dts: exynos: Add Thermal Management Unit to Exynos5410
  2016-05-31 18:39 ` Krzysztof Kozlowski
@ 2016-05-31 18:39   ` Krzysztof Kozlowski
  -1 siblings, 0 replies; 34+ messages in thread
From: Krzysztof Kozlowski @ 2016-05-31 18:39 UTC (permalink / raw)
  To: Kukjin Kim, Krzysztof Kozlowski, Sylwester Nawrocki, Tomasz Figa,
	Michael Turquette, Stephen Boyd, Javier Martinez Canillas,
	devicetree, linux-arm-kernel, linux-samsung-soc, linux-kernel,
	linux-clk
  Cc: Krzysztof Kozlowski

Add nodes for Thermal Management Unit to exynos5410.dtsi. Use the same
compatible as for Exynos5420 however without second base for TRIMINFO
register.

Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
---
 arch/arm/boot/dts/exynos5410.dtsi | 55 +++++++++++++++++++++++++++++++++++++++
 1 file changed, 55 insertions(+)

diff --git a/arch/arm/boot/dts/exynos5410.dtsi b/arch/arm/boot/dts/exynos5410.dtsi
index 994d16a44fe4..f1effd3f03c4 100644
--- a/arch/arm/boot/dts/exynos5410.dtsi
+++ b/arch/arm/boot/dts/exynos5410.dtsi
@@ -81,6 +81,42 @@
 			#clock-cells = <1>;
 		};
 
+		tmu_cpu0: tmu@10060000 {
+			compatible = "samsung,exynos5420-tmu";
+			reg = <0x10060000 0x100>;
+			interrupts = <0 65 0>;
+			clocks = <&clock CLK_TMU>;
+			clock-names = "tmu_apbif";
+			#include "exynos4412-tmu-sensor-conf.dtsi"
+		};
+
+		tmu_cpu1: tmu@10064000 {
+			compatible = "samsung,exynos5420-tmu";
+			reg = <0x10064000 0x100>;
+			interrupts = <0 183 0>;
+			clocks = <&clock CLK_TMU>;
+			clock-names = "tmu_apbif";
+			#include "exynos4412-tmu-sensor-conf.dtsi"
+		};
+
+		tmu_cpu2: tmu@10068000 {
+			compatible = "samsung,exynos5420-tmu";
+			reg = <0x10068000 0x100>;
+			interrupts = <0 184 0>;
+			clocks = <&clock CLK_TMU>;
+			clock-names = "tmu_apbif";
+			#include "exynos4412-tmu-sensor-conf.dtsi"
+		};
+
+		tmu_cpu3: tmu@1006c000 {
+			compatible = "samsung,exynos5420-tmu";
+			reg = <0x1006c000 0x100>;
+			interrupts = <0 185 0>;
+			clocks = <&clock CLK_TMU>;
+			clock-names = "tmu_apbif";
+			#include "exynos4412-tmu-sensor-conf.dtsi"
+		};
+
 		mmc_0: mmc@12200000 {
 			compatible = "samsung,exynos5250-dw-mshc";
 			reg = <0x12200000 0x1000>;
@@ -147,6 +183,25 @@
 			interrupts = <0 47 0>;
 		};
 	};
+
+	thermal-zones {
+		cpu0_thermal: cpu0-thermal {
+			thermal-sensors = <&tmu_cpu0>;
+			#include "exynos5420-trip-points.dtsi"
+		};
+		cpu1_thermal: cpu1-thermal {
+		       thermal-sensors = <&tmu_cpu1>;
+		       #include "exynos5420-trip-points.dtsi"
+		};
+		cpu2_thermal: cpu2-thermal {
+		       thermal-sensors = <&tmu_cpu2>;
+		       #include "exynos5420-trip-points.dtsi"
+		};
+		cpu3_thermal: cpu3-thermal {
+		       thermal-sensors = <&tmu_cpu3>;
+		       #include "exynos5420-trip-points.dtsi"
+		};
+	};
 };
 
 &i2c_0 {
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 34+ messages in thread

* [PATCH 4/6] ARM: dts: exynos: Add Thermal Management Unit to Exynos5410
@ 2016-05-31 18:39   ` Krzysztof Kozlowski
  0 siblings, 0 replies; 34+ messages in thread
From: Krzysztof Kozlowski @ 2016-05-31 18:39 UTC (permalink / raw)
  To: linux-arm-kernel

Add nodes for Thermal Management Unit to exynos5410.dtsi. Use the same
compatible as for Exynos5420 however without second base for TRIMINFO
register.

Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
---
 arch/arm/boot/dts/exynos5410.dtsi | 55 +++++++++++++++++++++++++++++++++++++++
 1 file changed, 55 insertions(+)

diff --git a/arch/arm/boot/dts/exynos5410.dtsi b/arch/arm/boot/dts/exynos5410.dtsi
index 994d16a44fe4..f1effd3f03c4 100644
--- a/arch/arm/boot/dts/exynos5410.dtsi
+++ b/arch/arm/boot/dts/exynos5410.dtsi
@@ -81,6 +81,42 @@
 			#clock-cells = <1>;
 		};
 
+		tmu_cpu0: tmu at 10060000 {
+			compatible = "samsung,exynos5420-tmu";
+			reg = <0x10060000 0x100>;
+			interrupts = <0 65 0>;
+			clocks = <&clock CLK_TMU>;
+			clock-names = "tmu_apbif";
+			#include "exynos4412-tmu-sensor-conf.dtsi"
+		};
+
+		tmu_cpu1: tmu at 10064000 {
+			compatible = "samsung,exynos5420-tmu";
+			reg = <0x10064000 0x100>;
+			interrupts = <0 183 0>;
+			clocks = <&clock CLK_TMU>;
+			clock-names = "tmu_apbif";
+			#include "exynos4412-tmu-sensor-conf.dtsi"
+		};
+
+		tmu_cpu2: tmu at 10068000 {
+			compatible = "samsung,exynos5420-tmu";
+			reg = <0x10068000 0x100>;
+			interrupts = <0 184 0>;
+			clocks = <&clock CLK_TMU>;
+			clock-names = "tmu_apbif";
+			#include "exynos4412-tmu-sensor-conf.dtsi"
+		};
+
+		tmu_cpu3: tmu at 1006c000 {
+			compatible = "samsung,exynos5420-tmu";
+			reg = <0x1006c000 0x100>;
+			interrupts = <0 185 0>;
+			clocks = <&clock CLK_TMU>;
+			clock-names = "tmu_apbif";
+			#include "exynos4412-tmu-sensor-conf.dtsi"
+		};
+
 		mmc_0: mmc at 12200000 {
 			compatible = "samsung,exynos5250-dw-mshc";
 			reg = <0x12200000 0x1000>;
@@ -147,6 +183,25 @@
 			interrupts = <0 47 0>;
 		};
 	};
+
+	thermal-zones {
+		cpu0_thermal: cpu0-thermal {
+			thermal-sensors = <&tmu_cpu0>;
+			#include "exynos5420-trip-points.dtsi"
+		};
+		cpu1_thermal: cpu1-thermal {
+		       thermal-sensors = <&tmu_cpu1>;
+		       #include "exynos5420-trip-points.dtsi"
+		};
+		cpu2_thermal: cpu2-thermal {
+		       thermal-sensors = <&tmu_cpu2>;
+		       #include "exynos5420-trip-points.dtsi"
+		};
+		cpu3_thermal: cpu3-thermal {
+		       thermal-sensors = <&tmu_cpu3>;
+		       #include "exynos5420-trip-points.dtsi"
+		};
+	};
 };
 
 &i2c_0 {
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 34+ messages in thread

* [PATCH 5/6] ARM: dts: exynos: Configure PWM, usb3503, PMIC and thermal on Odroid XU board
  2016-05-31 18:39 ` Krzysztof Kozlowski
@ 2016-05-31 18:39   ` Krzysztof Kozlowski
  -1 siblings, 0 replies; 34+ messages in thread
From: Krzysztof Kozlowski @ 2016-05-31 18:39 UTC (permalink / raw)
  To: Kukjin Kim, Krzysztof Kozlowski, Sylwester Nawrocki, Tomasz Figa,
	Michael Turquette, Stephen Boyd, Javier Martinez Canillas,
	devicetree, linux-arm-kernel, linux-samsung-soc, linux-kernel,
	linux-clk
  Cc: Krzysztof Kozlowski

Extend the DTS for Exynos5410-based Odroid XU board with:
1. Proper PWM outputs,
2. usb3503 USB HUB (with integrated LAN9730 ethernet adapter (smsc95xx)),
3. Maxim 77802 PMIC (regulators, 32 kHz clocks, RTC),
4. CPU thermal (trip points are the same as in Odroid XU3/XU4 but
   cooling maps are different as there is no CPU freq and only one
   cluster available for now),
5. Regulator supplies for USB 3.0.

Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>

---

Sources:
1. XU schematics
2. Hardkernel kernel tree:
   https://github.com/hardkernel/linux.git
   branch: odroidxu-3.4.y
   file: arch/arm/mach-exynos/board-odroidxu-power.c

Still USB over-current is reported:
[    2.115186] usb usb3-port1: over-current condition
[    2.118555] usb usb4-port1: over-current condition
---
 arch/arm/boot/dts/exynos5410-odroidxu.dts | 461 +++++++++++++++++++++++++++++-
 1 file changed, 460 insertions(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/exynos5410-odroidxu.dts b/arch/arm/boot/dts/exynos5410-odroidxu.dts
index 9fe04500ecaf..d9499310a301 100644
--- a/arch/arm/boot/dts/exynos5410-odroidxu.dts
+++ b/arch/arm/boot/dts/exynos5410-odroidxu.dts
@@ -12,6 +12,7 @@
 
 /dts-v1/;
 #include "exynos5410.dtsi"
+#include <dt-bindings/clock/maxim,max77802.h>
 #include <dt-bindings/gpio/gpio.h>
 #include <dt-bindings/interrupt-controller/irq.h>
 #include "exynos54xx-odroidxu-leds.dtsi"
@@ -57,6 +58,387 @@
 	};
 };
 
+&cpu0_thermal {
+	thermal-sensors = <&tmu_cpu0 0>;
+	polling-delay-passive = <0>;
+	polling-delay = <0>;
+
+	trips {
+		cpu_alert0: cpu-alert-0 {
+			temperature = <50000>; /* millicelsius */
+			hysteresis = <5000>; /* millicelsius */
+			type = "active";
+		};
+		cpu_alert1: cpu-alert-1 {
+			temperature = <60000>; /* millicelsius */
+			hysteresis = <5000>; /* millicelsius */
+			type = "active";
+		};
+		cpu_alert2: cpu-alert-2 {
+			temperature = <70000>; /* millicelsius */
+			hysteresis = <5000>; /* millicelsius */
+			type = "active";
+		};
+		cpu_crit0: cpu-crit-0 {
+			temperature = <120000>; /* millicelsius */
+			hysteresis = <0>; /* millicelsius */
+			type = "critical";
+		};
+	};
+
+	cooling-maps {
+		map0 {
+			trip = <&cpu_alert0>;
+			cooling-device = <&fan0 0 1>;
+		};
+		map1 {
+			trip = <&cpu_alert1>;
+			cooling-device = <&fan0 1 2>;
+		};
+		map2 {
+			trip = <&cpu_alert2>;
+			cooling-device = <&fan0 2 3>;
+		};
+	};
+};
+
+&hsi2c_4 {
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <400000>;
+	status = "okay";
+
+	usb3503: usb-hub@08 {
+		compatible = "smsc,usb3503";
+		reg = <0x08>;
+
+		intn-gpios = <&gpx0 7 GPIO_ACTIVE_HIGH>;
+		connect-gpios = <&gpx0 6 GPIO_ACTIVE_HIGH>;
+		reset-gpios = <&gpx1 4 GPIO_ACTIVE_HIGH>;
+		initial-mode = <1>;
+
+		clock-names = "refclk";
+		clocks = <&pmu_system_controller 0>;
+		refclk-frequency = <24000000>;
+	};
+
+	max77802: pmic@09 {
+		compatible = "maxim,max77802";
+		reg = <0x9>;
+		interrupt-parent = <&gpx0>;
+		interrupts = <4 IRQ_TYPE_NONE>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&max77802_irq>, <&pmic_dvs_1>, <&pmic_dvs_2>,
+			    <&pmic_dvs_3>;
+		#clock-cells = <1>;
+
+		inl1-supply = <&buck5_reg>;
+		inl2-supply = <&buck7_reg>;
+		inl3-supply = <&buck9_reg>;
+		inl4-supply = <&buck9_reg>;
+		inl5-supply = <&buck9_reg>;
+		inl6-supply = <&buck10_reg>;
+		inl7-supply = <&buck9_reg>;
+		/* inl9 supply is BOOST, not configured here */
+		inl10-supply = <&buck7_reg>;
+
+		regulators {
+			buck1_reg: BUCK1 {
+				regulator-name = "vdd_mif";
+				regulator-min-microvolt = <800000>;
+				regulator-max-microvolt = <1300000>;
+				regulator-always-on;
+				regulator-boot-on;
+			};
+
+			buck2_reg: BUCK2 {
+				regulator-name = "vdd_arm";
+				regulator-min-microvolt = <800000>;
+				regulator-max-microvolt = <1500000>;
+				regulator-always-on;
+				regulator-boot-on;
+			};
+
+			buck3_reg: BUCK3 {
+				regulator-name = "vdd_int";
+				regulator-min-microvolt = <800000>;
+				regulator-max-microvolt = <1400000>;
+				regulator-always-on;
+				regulator-boot-on;
+			};
+
+			buck4_reg: BUCK4 {
+				regulator-name = "vdd_g3d";
+				regulator-min-microvolt = <800000>;
+				regulator-max-microvolt = <1400000>;
+				regulator-always-on;
+				regulator-boot-on;
+			};
+
+			buck5_reg: BUCK5 {
+				regulator-name = "vdd_mem";
+				regulator-min-microvolt = <800000>;
+				regulator-max-microvolt = <1500000>;
+				regulator-always-on;
+				regulator-boot-on;
+			};
+
+			buck6_reg: BUCK6 {
+				regulator-name = "vdd_kfc";
+				regulator-min-microvolt = <800000>;
+				regulator-max-microvolt = <1500000>;
+				regulator-always-on;
+				regulator-boot-on;
+			};
+
+			buck7_reg: BUCK7 {
+				regulator-name = "buck7";
+				regulator-min-microvolt = <1300000>;
+				regulator-max-microvolt = <1300000>;
+				regulator-always-on;
+				regulator-boot-on;
+			};
+
+			buck8_reg: BUCK8 {
+				/* vdd_mmc0 */
+				regulator-name = "vddf_2v85";
+				regulator-min-microvolt = <2850000>;
+				regulator-max-microvolt = <2850000>;
+				regulator-always-on;
+				regulator-boot-on;
+			};
+
+			buck9_reg: BUCK9 {
+				regulator-name = "buck9";
+				regulator-min-microvolt = <3000000>;
+				regulator-max-microvolt = <3000000>;
+				regulator-always-on;
+				regulator-boot-on;
+			};
+
+			buck10_reg: BUCK10 {
+				regulator-name = "buck10";
+				regulator-min-microvolt = <2950000>;
+				regulator-max-microvolt = <2950000>;
+				regulator-always-on;
+				regulator-boot-on;
+			};
+
+			ldo1_reg: LDO1 {
+				regulator-name = "vdd_alive";
+				regulator-min-microvolt = <1000000>;
+				regulator-max-microvolt = <1000000>;
+				regulator-always-on;
+			};
+
+			ldo2_reg: LDO2 {
+				regulator-name = "vddq_m1_m2";
+				regulator-min-microvolt = <1200000>;
+				regulator-max-microvolt = <1200000>;
+				regulator-always-on;
+			};
+
+			ldo3_reg: LDO3 {
+				regulator-name = "vddq_gpio";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+			};
+
+			ldo4_reg: LDO4 {
+				regulator-name = "vddq_mmc2";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <3000000>;
+				/* Having it off prevents reboot */
+				regulator-always-on;
+			};
+
+			ldo5_reg: LDO5 {
+				regulator-name = "vdd18_hsic";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+			};
+
+			ldo6_reg: LDO6 {
+				regulator-name = "vdd18_bpll";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+			};
+
+			ldo7_reg: LDO7 {
+				regulator-name = "vddq_lcd";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+			};
+
+			ldo8_reg: LDO8 {
+				regulator-name = "vdd10_hdmi";
+				regulator-min-microvolt = <1000000>;
+				regulator-max-microvolt = <1000000>;
+				regulator-always-on;
+			};
+
+			ldo9_reg: LDO9 {
+				regulator-name = "ldo9";
+			};
+
+			ldo10_reg: LDO10 {
+				regulator-name = "vdd18_mipi";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+			};
+
+			ldo11_reg: LDO11 {
+				regulator-name = "vddq_mmc01";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				/*
+				 * Having it off prevents accessing MMC after
+				 * reboot with error:
+				 * MMC Device 1: Clock OFF has been failed.
+				 */
+				regulator-always-on;
+			};
+
+			ldo12_reg: LDO12 {
+				regulator-name = "vdd33_usb3";
+				regulator-min-microvolt = <3300000>;
+				regulator-max-microvolt = <3300000>;
+				regulator-always-on;
+			};
+
+			ldo13_reg: LDO13 {
+				regulator-name = "vddq_abbg0";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+			};
+
+			ldo14_reg: LDO14 {
+				regulator-name = "vddq_abbg1";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+			};
+
+			ldo15_reg: LDO15 {
+				regulator-name = "vdd10_usb3";
+				regulator-min-microvolt = <1000000>;
+				regulator-max-microvolt = <1000000>;
+				regulator-always-on;
+			};
+
+			ldo16_reg: LDO16 {
+				regulator-name = "ldo16";
+			};
+
+			ldo17_reg: LDO17 {
+				regulator-name = "cam_sensor_core";
+				regulator-min-microvolt = <1200000>;
+				regulator-max-microvolt = <1200000>;
+			};
+
+			ldo18_reg: LDO18 {
+				regulator-name = "ldo18";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+			};
+
+			ldo19_reg: LDO19 {
+				regulator-name = "ldo19";
+			};
+
+			ldo20_reg: LDO20 {
+				regulator-name = "vdd_mmc0";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+			};
+
+			ldo21_reg: LDO21 {
+				/* vdd_mmc2 */
+				regulator-name = "vddf_2v8";
+				regulator-min-microvolt = <2850000>;
+				regulator-max-microvolt = <2850000>;
+			};
+
+			ldo22_reg: LDO22 {
+				regulator-name = "ldo22";
+			};
+
+			ldo23_reg: LDO23 {
+				regulator-name = "dp_p3v3";
+				regulator-min-microvolt = <3300000>;
+				regulator-max-microvolt = <3300000>;
+				regulator-always-on;
+			};
+
+			ldo24_reg: LDO24 {
+				regulator-name = "cam_af";
+				regulator-min-microvolt = <2800000>;
+				regulator-max-microvolt = <2800000>;
+			};
+
+			ldo25_reg: LDO25 {
+				regulator-name = "eth_p3v3";
+				regulator-min-microvolt = <3300000>;
+				regulator-max-microvolt = <3300000>;
+				regulator-always-on;
+			};
+
+			ldo26_reg: LDO26 {
+				regulator-name = "usb30_extclk";
+				regulator-min-microvolt = <3300000>;
+				regulator-max-microvolt = <3300000>;
+				regulator-always-on;
+			};
+
+			ldo27_reg: LDO27 {
+				regulator-name = "ldo27";
+			};
+
+			ldo28_reg: LDO28 {
+				regulator-name = "ldo28";
+			};
+
+			ldo29_reg: LDO29 {
+				regulator-name = "ldo29";
+			};
+
+			ldo30_reg: LDO30 {
+				regulator-name = "vddq_e1_e2";
+				regulator-min-microvolt = <1200000>;
+				regulator-max-microvolt = <1200000>;
+				regulator-always-on;
+			};
+
+			ldo31_reg: LDO31 {
+				regulator-name = "ldo31";
+			};
+
+			/* On revisions with ti,ina231 this is sensor VS */
+			ldo32_reg: LDO32 {
+				regulator-name = "vs_power_meter";
+				regulator-min-microvolt = <3300000>;
+				regulator-max-microvolt = <3300000>;
+			};
+
+			ldo33_reg: LDO33 {
+				regulator-name = "ldo33";
+			};
+
+			ldo34_reg: LDO34 {
+				regulator-name = "ldo34";
+			};
+
+			ldo35_reg: LDO35 {
+				regulator-name = "ldo35";
+			};
+		};
+	};
+};
+
 &mmc_0 {
 	status = "okay";
 	mmc-pwrseq = <&emmc_pwrseq>;
@@ -73,6 +455,8 @@
 	cap-mmc-highspeed;
 	mmc-hs200-1_8v;
 	mmc-hs400-1_8v;
+	vmmc-supply = <&ldo20_reg>;
+	vqmmc-supply = <&ldo11_reg>;
 };
 
 &mmc_2 {
@@ -85,17 +469,66 @@
 	pinctrl-0 = <&sd2_clk &sd2_cmd &sd2_cd &sd2_bus1 &sd2_bus4>;
 	bus-width = <4>;
 	cap-sd-highspeed;
+	vmmc-supply = <&ldo21_reg>;
+	vqmmc-supply = <&ldo4_reg>;
 };
 
 &pinctrl_0 {
 	emmc_nrst_pin: emmc-nrst {
 		samsung,pins = "gpd1-0";
-		samsung,pin-function = <0>;
+		samsung,pin-function = <2>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	pmic_dvs_3: pmic-dvs-3 {
+		samsung,pins = "gpx0-0";
+		samsung,pin-function = <1>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	pmic_dvs_2: pmic-dvs-2 {
+		samsung,pins = "gpx0-1";
+		samsung,pin-function = <1>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	pmic_dvs_1: pmic-dvs-1 {
+		samsung,pins = "gpx0-2";
+		samsung,pin-function = <1>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+		samsung,pin-val = <1>;
+	};
+
+	max77802_irq: max77802-irq {
+		samsung,pins = "gpx0-4";
+		samsung,pin-function = <0xf>;
 		samsung,pin-pud = <0>;
 		samsung,pin-drv = <0>;
 	};
 };
 
+&pwm {
+	/*
+	 * PWM 0 -- fan
+	 * PWM 1 -- Green LED
+	 * PWM 2 -- Blue LED
+	 * PWM 3 -- on MIPI connector for backlight
+	 */
+	pinctrl-0 = <&pwm0_out &pwm1_out &pwm2_out &pwm3_out>;
+	pinctrl-names = "default";
+	status = "okay";
+};
+
+&rtc {
+	status = "okay";
+	clocks = <&clock CLK_RTC>, <&max77802 MAX77802_CLK_32K_AP>;
+	clock-names = "rtc", "rtc_src";
+};
+
 &serial_0 {
 	status = "okay";
 };
@@ -112,6 +545,22 @@
 	status = "okay";
 };
 
+&tmu_cpu0 {
+	vtmu-supply = <&ldo10_reg>;
+};
+
+&tmu_cpu1 {
+	vtmu-supply = <&ldo10_reg>;
+};
+
+&tmu_cpu2 {
+	vtmu-supply = <&ldo10_reg>;
+};
+
+&tmu_cpu3 {
+	vtmu-supply = <&ldo10_reg>;
+};
+
 &usbdrd_dwc3_0 {
 	dr_mode = "host";
 };
@@ -119,3 +568,13 @@
 &usbdrd_dwc3_1 {
 	dr_mode = "peripheral";
 };
+
+&usbdrd3_0 {
+	vdd33-supply = <&ldo12_reg>;
+	vdd10-supply = <&ldo15_reg>;
+};
+
+&usbdrd3_1 {
+	vdd33-supply = <&ldo12_reg>;
+	vdd10-supply = <&ldo15_reg>;
+};
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 34+ messages in thread

* [PATCH 5/6] ARM: dts: exynos: Configure PWM, usb3503, PMIC and thermal on Odroid XU board
@ 2016-05-31 18:39   ` Krzysztof Kozlowski
  0 siblings, 0 replies; 34+ messages in thread
From: Krzysztof Kozlowski @ 2016-05-31 18:39 UTC (permalink / raw)
  To: linux-arm-kernel

Extend the DTS for Exynos5410-based Odroid XU board with:
1. Proper PWM outputs,
2. usb3503 USB HUB (with integrated LAN9730 ethernet adapter (smsc95xx)),
3. Maxim 77802 PMIC (regulators, 32 kHz clocks, RTC),
4. CPU thermal (trip points are the same as in Odroid XU3/XU4 but
   cooling maps are different as there is no CPU freq and only one
   cluster available for now),
5. Regulator supplies for USB 3.0.

Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>

---

Sources:
1. XU schematics
2. Hardkernel kernel tree:
   https://github.com/hardkernel/linux.git
   branch: odroidxu-3.4.y
   file: arch/arm/mach-exynos/board-odroidxu-power.c

Still USB over-current is reported:
[    2.115186] usb usb3-port1: over-current condition
[    2.118555] usb usb4-port1: over-current condition
---
 arch/arm/boot/dts/exynos5410-odroidxu.dts | 461 +++++++++++++++++++++++++++++-
 1 file changed, 460 insertions(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/exynos5410-odroidxu.dts b/arch/arm/boot/dts/exynos5410-odroidxu.dts
index 9fe04500ecaf..d9499310a301 100644
--- a/arch/arm/boot/dts/exynos5410-odroidxu.dts
+++ b/arch/arm/boot/dts/exynos5410-odroidxu.dts
@@ -12,6 +12,7 @@
 
 /dts-v1/;
 #include "exynos5410.dtsi"
+#include <dt-bindings/clock/maxim,max77802.h>
 #include <dt-bindings/gpio/gpio.h>
 #include <dt-bindings/interrupt-controller/irq.h>
 #include "exynos54xx-odroidxu-leds.dtsi"
@@ -57,6 +58,387 @@
 	};
 };
 
+&cpu0_thermal {
+	thermal-sensors = <&tmu_cpu0 0>;
+	polling-delay-passive = <0>;
+	polling-delay = <0>;
+
+	trips {
+		cpu_alert0: cpu-alert-0 {
+			temperature = <50000>; /* millicelsius */
+			hysteresis = <5000>; /* millicelsius */
+			type = "active";
+		};
+		cpu_alert1: cpu-alert-1 {
+			temperature = <60000>; /* millicelsius */
+			hysteresis = <5000>; /* millicelsius */
+			type = "active";
+		};
+		cpu_alert2: cpu-alert-2 {
+			temperature = <70000>; /* millicelsius */
+			hysteresis = <5000>; /* millicelsius */
+			type = "active";
+		};
+		cpu_crit0: cpu-crit-0 {
+			temperature = <120000>; /* millicelsius */
+			hysteresis = <0>; /* millicelsius */
+			type = "critical";
+		};
+	};
+
+	cooling-maps {
+		map0 {
+			trip = <&cpu_alert0>;
+			cooling-device = <&fan0 0 1>;
+		};
+		map1 {
+			trip = <&cpu_alert1>;
+			cooling-device = <&fan0 1 2>;
+		};
+		map2 {
+			trip = <&cpu_alert2>;
+			cooling-device = <&fan0 2 3>;
+		};
+	};
+};
+
+&hsi2c_4 {
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <400000>;
+	status = "okay";
+
+	usb3503: usb-hub at 08 {
+		compatible = "smsc,usb3503";
+		reg = <0x08>;
+
+		intn-gpios = <&gpx0 7 GPIO_ACTIVE_HIGH>;
+		connect-gpios = <&gpx0 6 GPIO_ACTIVE_HIGH>;
+		reset-gpios = <&gpx1 4 GPIO_ACTIVE_HIGH>;
+		initial-mode = <1>;
+
+		clock-names = "refclk";
+		clocks = <&pmu_system_controller 0>;
+		refclk-frequency = <24000000>;
+	};
+
+	max77802: pmic at 09 {
+		compatible = "maxim,max77802";
+		reg = <0x9>;
+		interrupt-parent = <&gpx0>;
+		interrupts = <4 IRQ_TYPE_NONE>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&max77802_irq>, <&pmic_dvs_1>, <&pmic_dvs_2>,
+			    <&pmic_dvs_3>;
+		#clock-cells = <1>;
+
+		inl1-supply = <&buck5_reg>;
+		inl2-supply = <&buck7_reg>;
+		inl3-supply = <&buck9_reg>;
+		inl4-supply = <&buck9_reg>;
+		inl5-supply = <&buck9_reg>;
+		inl6-supply = <&buck10_reg>;
+		inl7-supply = <&buck9_reg>;
+		/* inl9 supply is BOOST, not configured here */
+		inl10-supply = <&buck7_reg>;
+
+		regulators {
+			buck1_reg: BUCK1 {
+				regulator-name = "vdd_mif";
+				regulator-min-microvolt = <800000>;
+				regulator-max-microvolt = <1300000>;
+				regulator-always-on;
+				regulator-boot-on;
+			};
+
+			buck2_reg: BUCK2 {
+				regulator-name = "vdd_arm";
+				regulator-min-microvolt = <800000>;
+				regulator-max-microvolt = <1500000>;
+				regulator-always-on;
+				regulator-boot-on;
+			};
+
+			buck3_reg: BUCK3 {
+				regulator-name = "vdd_int";
+				regulator-min-microvolt = <800000>;
+				regulator-max-microvolt = <1400000>;
+				regulator-always-on;
+				regulator-boot-on;
+			};
+
+			buck4_reg: BUCK4 {
+				regulator-name = "vdd_g3d";
+				regulator-min-microvolt = <800000>;
+				regulator-max-microvolt = <1400000>;
+				regulator-always-on;
+				regulator-boot-on;
+			};
+
+			buck5_reg: BUCK5 {
+				regulator-name = "vdd_mem";
+				regulator-min-microvolt = <800000>;
+				regulator-max-microvolt = <1500000>;
+				regulator-always-on;
+				regulator-boot-on;
+			};
+
+			buck6_reg: BUCK6 {
+				regulator-name = "vdd_kfc";
+				regulator-min-microvolt = <800000>;
+				regulator-max-microvolt = <1500000>;
+				regulator-always-on;
+				regulator-boot-on;
+			};
+
+			buck7_reg: BUCK7 {
+				regulator-name = "buck7";
+				regulator-min-microvolt = <1300000>;
+				regulator-max-microvolt = <1300000>;
+				regulator-always-on;
+				regulator-boot-on;
+			};
+
+			buck8_reg: BUCK8 {
+				/* vdd_mmc0 */
+				regulator-name = "vddf_2v85";
+				regulator-min-microvolt = <2850000>;
+				regulator-max-microvolt = <2850000>;
+				regulator-always-on;
+				regulator-boot-on;
+			};
+
+			buck9_reg: BUCK9 {
+				regulator-name = "buck9";
+				regulator-min-microvolt = <3000000>;
+				regulator-max-microvolt = <3000000>;
+				regulator-always-on;
+				regulator-boot-on;
+			};
+
+			buck10_reg: BUCK10 {
+				regulator-name = "buck10";
+				regulator-min-microvolt = <2950000>;
+				regulator-max-microvolt = <2950000>;
+				regulator-always-on;
+				regulator-boot-on;
+			};
+
+			ldo1_reg: LDO1 {
+				regulator-name = "vdd_alive";
+				regulator-min-microvolt = <1000000>;
+				regulator-max-microvolt = <1000000>;
+				regulator-always-on;
+			};
+
+			ldo2_reg: LDO2 {
+				regulator-name = "vddq_m1_m2";
+				regulator-min-microvolt = <1200000>;
+				regulator-max-microvolt = <1200000>;
+				regulator-always-on;
+			};
+
+			ldo3_reg: LDO3 {
+				regulator-name = "vddq_gpio";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+			};
+
+			ldo4_reg: LDO4 {
+				regulator-name = "vddq_mmc2";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <3000000>;
+				/* Having it off prevents reboot */
+				regulator-always-on;
+			};
+
+			ldo5_reg: LDO5 {
+				regulator-name = "vdd18_hsic";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+			};
+
+			ldo6_reg: LDO6 {
+				regulator-name = "vdd18_bpll";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+			};
+
+			ldo7_reg: LDO7 {
+				regulator-name = "vddq_lcd";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+			};
+
+			ldo8_reg: LDO8 {
+				regulator-name = "vdd10_hdmi";
+				regulator-min-microvolt = <1000000>;
+				regulator-max-microvolt = <1000000>;
+				regulator-always-on;
+			};
+
+			ldo9_reg: LDO9 {
+				regulator-name = "ldo9";
+			};
+
+			ldo10_reg: LDO10 {
+				regulator-name = "vdd18_mipi";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+			};
+
+			ldo11_reg: LDO11 {
+				regulator-name = "vddq_mmc01";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				/*
+				 * Having it off prevents accessing MMC after
+				 * reboot with error:
+				 * MMC Device 1: Clock OFF has been failed.
+				 */
+				regulator-always-on;
+			};
+
+			ldo12_reg: LDO12 {
+				regulator-name = "vdd33_usb3";
+				regulator-min-microvolt = <3300000>;
+				regulator-max-microvolt = <3300000>;
+				regulator-always-on;
+			};
+
+			ldo13_reg: LDO13 {
+				regulator-name = "vddq_abbg0";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+			};
+
+			ldo14_reg: LDO14 {
+				regulator-name = "vddq_abbg1";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+			};
+
+			ldo15_reg: LDO15 {
+				regulator-name = "vdd10_usb3";
+				regulator-min-microvolt = <1000000>;
+				regulator-max-microvolt = <1000000>;
+				regulator-always-on;
+			};
+
+			ldo16_reg: LDO16 {
+				regulator-name = "ldo16";
+			};
+
+			ldo17_reg: LDO17 {
+				regulator-name = "cam_sensor_core";
+				regulator-min-microvolt = <1200000>;
+				regulator-max-microvolt = <1200000>;
+			};
+
+			ldo18_reg: LDO18 {
+				regulator-name = "ldo18";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+			};
+
+			ldo19_reg: LDO19 {
+				regulator-name = "ldo19";
+			};
+
+			ldo20_reg: LDO20 {
+				regulator-name = "vdd_mmc0";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+			};
+
+			ldo21_reg: LDO21 {
+				/* vdd_mmc2 */
+				regulator-name = "vddf_2v8";
+				regulator-min-microvolt = <2850000>;
+				regulator-max-microvolt = <2850000>;
+			};
+
+			ldo22_reg: LDO22 {
+				regulator-name = "ldo22";
+			};
+
+			ldo23_reg: LDO23 {
+				regulator-name = "dp_p3v3";
+				regulator-min-microvolt = <3300000>;
+				regulator-max-microvolt = <3300000>;
+				regulator-always-on;
+			};
+
+			ldo24_reg: LDO24 {
+				regulator-name = "cam_af";
+				regulator-min-microvolt = <2800000>;
+				regulator-max-microvolt = <2800000>;
+			};
+
+			ldo25_reg: LDO25 {
+				regulator-name = "eth_p3v3";
+				regulator-min-microvolt = <3300000>;
+				regulator-max-microvolt = <3300000>;
+				regulator-always-on;
+			};
+
+			ldo26_reg: LDO26 {
+				regulator-name = "usb30_extclk";
+				regulator-min-microvolt = <3300000>;
+				regulator-max-microvolt = <3300000>;
+				regulator-always-on;
+			};
+
+			ldo27_reg: LDO27 {
+				regulator-name = "ldo27";
+			};
+
+			ldo28_reg: LDO28 {
+				regulator-name = "ldo28";
+			};
+
+			ldo29_reg: LDO29 {
+				regulator-name = "ldo29";
+			};
+
+			ldo30_reg: LDO30 {
+				regulator-name = "vddq_e1_e2";
+				regulator-min-microvolt = <1200000>;
+				regulator-max-microvolt = <1200000>;
+				regulator-always-on;
+			};
+
+			ldo31_reg: LDO31 {
+				regulator-name = "ldo31";
+			};
+
+			/* On revisions with ti,ina231 this is sensor VS */
+			ldo32_reg: LDO32 {
+				regulator-name = "vs_power_meter";
+				regulator-min-microvolt = <3300000>;
+				regulator-max-microvolt = <3300000>;
+			};
+
+			ldo33_reg: LDO33 {
+				regulator-name = "ldo33";
+			};
+
+			ldo34_reg: LDO34 {
+				regulator-name = "ldo34";
+			};
+
+			ldo35_reg: LDO35 {
+				regulator-name = "ldo35";
+			};
+		};
+	};
+};
+
 &mmc_0 {
 	status = "okay";
 	mmc-pwrseq = <&emmc_pwrseq>;
@@ -73,6 +455,8 @@
 	cap-mmc-highspeed;
 	mmc-hs200-1_8v;
 	mmc-hs400-1_8v;
+	vmmc-supply = <&ldo20_reg>;
+	vqmmc-supply = <&ldo11_reg>;
 };
 
 &mmc_2 {
@@ -85,17 +469,66 @@
 	pinctrl-0 = <&sd2_clk &sd2_cmd &sd2_cd &sd2_bus1 &sd2_bus4>;
 	bus-width = <4>;
 	cap-sd-highspeed;
+	vmmc-supply = <&ldo21_reg>;
+	vqmmc-supply = <&ldo4_reg>;
 };
 
 &pinctrl_0 {
 	emmc_nrst_pin: emmc-nrst {
 		samsung,pins = "gpd1-0";
-		samsung,pin-function = <0>;
+		samsung,pin-function = <2>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	pmic_dvs_3: pmic-dvs-3 {
+		samsung,pins = "gpx0-0";
+		samsung,pin-function = <1>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	pmic_dvs_2: pmic-dvs-2 {
+		samsung,pins = "gpx0-1";
+		samsung,pin-function = <1>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	pmic_dvs_1: pmic-dvs-1 {
+		samsung,pins = "gpx0-2";
+		samsung,pin-function = <1>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+		samsung,pin-val = <1>;
+	};
+
+	max77802_irq: max77802-irq {
+		samsung,pins = "gpx0-4";
+		samsung,pin-function = <0xf>;
 		samsung,pin-pud = <0>;
 		samsung,pin-drv = <0>;
 	};
 };
 
+&pwm {
+	/*
+	 * PWM 0 -- fan
+	 * PWM 1 -- Green LED
+	 * PWM 2 -- Blue LED
+	 * PWM 3 -- on MIPI connector for backlight
+	 */
+	pinctrl-0 = <&pwm0_out &pwm1_out &pwm2_out &pwm3_out>;
+	pinctrl-names = "default";
+	status = "okay";
+};
+
+&rtc {
+	status = "okay";
+	clocks = <&clock CLK_RTC>, <&max77802 MAX77802_CLK_32K_AP>;
+	clock-names = "rtc", "rtc_src";
+};
+
 &serial_0 {
 	status = "okay";
 };
@@ -112,6 +545,22 @@
 	status = "okay";
 };
 
+&tmu_cpu0 {
+	vtmu-supply = <&ldo10_reg>;
+};
+
+&tmu_cpu1 {
+	vtmu-supply = <&ldo10_reg>;
+};
+
+&tmu_cpu2 {
+	vtmu-supply = <&ldo10_reg>;
+};
+
+&tmu_cpu3 {
+	vtmu-supply = <&ldo10_reg>;
+};
+
 &usbdrd_dwc3_0 {
 	dr_mode = "host";
 };
@@ -119,3 +568,13 @@
 &usbdrd_dwc3_1 {
 	dr_mode = "peripheral";
 };
+
+&usbdrd3_0 {
+	vdd33-supply = <&ldo12_reg>;
+	vdd10-supply = <&ldo15_reg>;
+};
+
+&usbdrd3_1 {
+	vdd33-supply = <&ldo12_reg>;
+	vdd10-supply = <&ldo15_reg>;
+};
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 34+ messages in thread

* [PATCH 6/6] ARM: dts: exynos: No need to enable TMU nodes on Odroid XU3 family
  2016-05-31 18:39 ` Krzysztof Kozlowski
@ 2016-05-31 18:39   ` Krzysztof Kozlowski
  -1 siblings, 0 replies; 34+ messages in thread
From: Krzysztof Kozlowski @ 2016-05-31 18:39 UTC (permalink / raw)
  To: Kukjin Kim, Krzysztof Kozlowski, Sylwester Nawrocki, Tomasz Figa,
	Michael Turquette, Stephen Boyd, Javier Martinez Canillas,
	devicetree, linux-arm-kernel, linux-samsung-soc, linux-kernel,
	linux-clk
  Cc: Krzysztof Kozlowski

The thermal nodes are not disabled in exynos5420.dtsi so there is no
need to manually enable them on Odroid XU3/XU3-Lite/XU4 boards.

Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
---
 arch/arm/boot/dts/exynos5422-odroidxu3-common.dtsi | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/arch/arm/boot/dts/exynos5422-odroidxu3-common.dtsi b/arch/arm/boot/dts/exynos5422-odroidxu3-common.dtsi
index 20fa7612080d..c08392b9e0dd 100644
--- a/arch/arm/boot/dts/exynos5422-odroidxu3-common.dtsi
+++ b/arch/arm/boot/dts/exynos5422-odroidxu3-common.dtsi
@@ -388,27 +388,22 @@
 
 &tmu_cpu0 {
 	vtmu-supply = <&ldo7_reg>;
-	status = "okay";
 };
 
 &tmu_cpu1 {
 	vtmu-supply = <&ldo7_reg>;
-	status = "okay";
 };
 
 &tmu_cpu2 {
 	vtmu-supply = <&ldo7_reg>;
-	status = "okay";
 };
 
 &tmu_cpu3 {
 	vtmu-supply = <&ldo7_reg>;
-	status = "okay";
 };
 
 &tmu_gpu {
 	vtmu-supply = <&ldo7_reg>;
-	status = "okay";
 };
 
 &rtc {
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 34+ messages in thread

* [PATCH 6/6] ARM: dts: exynos: No need to enable TMU nodes on Odroid XU3 family
@ 2016-05-31 18:39   ` Krzysztof Kozlowski
  0 siblings, 0 replies; 34+ messages in thread
From: Krzysztof Kozlowski @ 2016-05-31 18:39 UTC (permalink / raw)
  To: linux-arm-kernel

The thermal nodes are not disabled in exynos5420.dtsi so there is no
need to manually enable them on Odroid XU3/XU3-Lite/XU4 boards.

Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
---
 arch/arm/boot/dts/exynos5422-odroidxu3-common.dtsi | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/arch/arm/boot/dts/exynos5422-odroidxu3-common.dtsi b/arch/arm/boot/dts/exynos5422-odroidxu3-common.dtsi
index 20fa7612080d..c08392b9e0dd 100644
--- a/arch/arm/boot/dts/exynos5422-odroidxu3-common.dtsi
+++ b/arch/arm/boot/dts/exynos5422-odroidxu3-common.dtsi
@@ -388,27 +388,22 @@
 
 &tmu_cpu0 {
 	vtmu-supply = <&ldo7_reg>;
-	status = "okay";
 };
 
 &tmu_cpu1 {
 	vtmu-supply = <&ldo7_reg>;
-	status = "okay";
 };
 
 &tmu_cpu2 {
 	vtmu-supply = <&ldo7_reg>;
-	status = "okay";
 };
 
 &tmu_cpu3 {
 	vtmu-supply = <&ldo7_reg>;
-	status = "okay";
 };
 
 &tmu_gpu {
 	vtmu-supply = <&ldo7_reg>;
-	status = "okay";
 };
 
 &rtc {
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 34+ messages in thread

* Re: [PATCH 1/6] dt-bindings: clock: Add TMU clock ID to Exynos5410
  2016-05-31 18:39 ` Krzysztof Kozlowski
@ 2016-05-31 18:53   ` Javier Martinez Canillas
  -1 siblings, 0 replies; 34+ messages in thread
From: Javier Martinez Canillas @ 2016-05-31 18:53 UTC (permalink / raw)
  To: Krzysztof Kozlowski, Kukjin Kim, Krzysztof Kozlowski,
	Sylwester Nawrocki, Tomasz Figa, Michael Turquette, Stephen Boyd,
	devicetree, linux-arm-kernel, linux-samsung-soc, linux-kernel,
	linux-clk

Hello Krzysztof,

On 05/31/2016 02:39 PM, Krzysztof Kozlowski wrote:
> Add ID for TMU clock to Exynos5410. Use the same number as for
> Exynos5420 just in case in future these drivers were merged.
> 
> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
> ---

Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com>

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America

^ permalink raw reply	[flat|nested] 34+ messages in thread

* [PATCH 1/6] dt-bindings: clock: Add TMU clock ID to Exynos5410
@ 2016-05-31 18:53   ` Javier Martinez Canillas
  0 siblings, 0 replies; 34+ messages in thread
From: Javier Martinez Canillas @ 2016-05-31 18:53 UTC (permalink / raw)
  To: linux-arm-kernel

Hello Krzysztof,

On 05/31/2016 02:39 PM, Krzysztof Kozlowski wrote:
> Add ID for TMU clock to Exynos5410. Use the same number as for
> Exynos5420 just in case in future these drivers were merged.
> 
> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
> ---

Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com>

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH 2/6] clk: samsung: exynos5410: Add TMU clock
  2016-05-31 18:39   ` Krzysztof Kozlowski
@ 2016-05-31 18:56     ` Javier Martinez Canillas
  -1 siblings, 0 replies; 34+ messages in thread
From: Javier Martinez Canillas @ 2016-05-31 18:56 UTC (permalink / raw)
  To: Krzysztof Kozlowski, Kukjin Kim, Krzysztof Kozlowski,
	Sylwester Nawrocki, Tomasz Figa, Michael Turquette, Stephen Boyd,
	devicetree, linux-arm-kernel, linux-samsung-soc, linux-kernel,
	linux-clk

Hello Krzysztof,

On 05/31/2016 02:39 PM, Krzysztof Kozlowski wrote:
> Add clock for TMU to the Exynos5410 clock driver.
> 
> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
> ---
>  drivers/clk/samsung/clk-exynos5410.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/clk/samsung/clk-exynos5410.c b/drivers/clk/samsung/clk-exynos5410.c
> index 6c2e59c576ee..db9978dc6e83 100644
> --- a/drivers/clk/samsung/clk-exynos5410.c
> +++ b/drivers/clk/samsung/clk-exynos5410.c
> @@ -160,6 +160,7 @@ static struct samsung_div_clock exynos5410_div_clks[] __initdata = {
>  static struct samsung_gate_clock exynos5410_gate_clks[] __initdata = {
>  	GATE(CLK_MCT, "mct", "aclk66", GATE_IP_PERIS, 18, 0, 0),
>  	GATE(CLK_RTC, "rtc", "aclk66", GATE_IP_PERIS, 20, 0, 0),
> +	GATE(CLK_TMU, "tmu", "aclk66", GATE_IP_PERIS, 21, 0, 0),
>  
>  	GATE(CLK_SCLK_MMC0, "sclk_mmc0", "div_mmc_pre0",
>  			SRC_MASK_FSYS, 0, CLK_SET_RATE_PARENT, 0),
> 

Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com>

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America

^ permalink raw reply	[flat|nested] 34+ messages in thread

* [PATCH 2/6] clk: samsung: exynos5410: Add TMU clock
@ 2016-05-31 18:56     ` Javier Martinez Canillas
  0 siblings, 0 replies; 34+ messages in thread
From: Javier Martinez Canillas @ 2016-05-31 18:56 UTC (permalink / raw)
  To: linux-arm-kernel

Hello Krzysztof,

On 05/31/2016 02:39 PM, Krzysztof Kozlowski wrote:
> Add clock for TMU to the Exynos5410 clock driver.
> 
> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
> ---
>  drivers/clk/samsung/clk-exynos5410.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/clk/samsung/clk-exynos5410.c b/drivers/clk/samsung/clk-exynos5410.c
> index 6c2e59c576ee..db9978dc6e83 100644
> --- a/drivers/clk/samsung/clk-exynos5410.c
> +++ b/drivers/clk/samsung/clk-exynos5410.c
> @@ -160,6 +160,7 @@ static struct samsung_div_clock exynos5410_div_clks[] __initdata = {
>  static struct samsung_gate_clock exynos5410_gate_clks[] __initdata = {
>  	GATE(CLK_MCT, "mct", "aclk66", GATE_IP_PERIS, 18, 0, 0),
>  	GATE(CLK_RTC, "rtc", "aclk66", GATE_IP_PERIS, 20, 0, 0),
> +	GATE(CLK_TMU, "tmu", "aclk66", GATE_IP_PERIS, 21, 0, 0),
>  
>  	GATE(CLK_SCLK_MMC0, "sclk_mmc0", "div_mmc_pre0",
>  			SRC_MASK_FSYS, 0, CLK_SET_RATE_PARENT, 0),
> 

Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com>

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH 3/6] ARM: dts: exynos: Interrupt for USB DWC3-1 differs between Exynos5420 and 5410
  2016-05-31 18:39   ` Krzysztof Kozlowski
@ 2016-05-31 19:01     ` Javier Martinez Canillas
  -1 siblings, 0 replies; 34+ messages in thread
From: Javier Martinez Canillas @ 2016-05-31 19:01 UTC (permalink / raw)
  To: Krzysztof Kozlowski, Kukjin Kim, Krzysztof Kozlowski,
	Sylwester Nawrocki, Tomasz Figa, Michael Turquette, Stephen Boyd,
	devicetree, linux-arm-kernel, linux-samsung-soc, linux-kernel,
	linux-clk

Hello Krzysztof,

On 05/31/2016 02:39 PM, Krzysztof Kozlowski wrote:
> On Exynos5410 the SPI interrupt for second USB DWC3 (called DRD: Dual
> Role Device) is different - 200 instead of 73.
> 
> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
> ---
>  arch/arm/boot/dts/exynos5410.dtsi | 4 ++++
>  arch/arm/boot/dts/exynos5420.dtsi | 4 ++++
>  arch/arm/boot/dts/exynos54xx.dtsi | 1 -
>  3 files changed, 8 insertions(+), 1 deletion(-)
> 
> diff --git a/arch/arm/boot/dts/exynos5410.dtsi b/arch/arm/boot/dts/exynos5410.dtsi
> index a937d9bdad90..994d16a44fe4 100644
> --- a/arch/arm/boot/dts/exynos5410.dtsi
> +++ b/arch/arm/boot/dts/exynos5410.dtsi
> @@ -267,6 +267,10 @@
>  	clock-names = "usbdrd30";
>  };
>  
> +&usbdrd_dwc3_1 {
> +	interrupts = <0 200 0>;

Please use GIC_SPI from <dt-bindings/interrupt-controller/arm-gic.h> instead 0.

Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com>

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America

^ permalink raw reply	[flat|nested] 34+ messages in thread

* [PATCH 3/6] ARM: dts: exynos: Interrupt for USB DWC3-1 differs between Exynos5420 and 5410
@ 2016-05-31 19:01     ` Javier Martinez Canillas
  0 siblings, 0 replies; 34+ messages in thread
From: Javier Martinez Canillas @ 2016-05-31 19:01 UTC (permalink / raw)
  To: linux-arm-kernel

Hello Krzysztof,

On 05/31/2016 02:39 PM, Krzysztof Kozlowski wrote:
> On Exynos5410 the SPI interrupt for second USB DWC3 (called DRD: Dual
> Role Device) is different - 200 instead of 73.
> 
> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
> ---
>  arch/arm/boot/dts/exynos5410.dtsi | 4 ++++
>  arch/arm/boot/dts/exynos5420.dtsi | 4 ++++
>  arch/arm/boot/dts/exynos54xx.dtsi | 1 -
>  3 files changed, 8 insertions(+), 1 deletion(-)
> 
> diff --git a/arch/arm/boot/dts/exynos5410.dtsi b/arch/arm/boot/dts/exynos5410.dtsi
> index a937d9bdad90..994d16a44fe4 100644
> --- a/arch/arm/boot/dts/exynos5410.dtsi
> +++ b/arch/arm/boot/dts/exynos5410.dtsi
> @@ -267,6 +267,10 @@
>  	clock-names = "usbdrd30";
>  };
>  
> +&usbdrd_dwc3_1 {
> +	interrupts = <0 200 0>;

Please use GIC_SPI from <dt-bindings/interrupt-controller/arm-gic.h> instead 0.

Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com>

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH 4/6] ARM: dts: exynos: Add Thermal Management Unit to Exynos5410
  2016-05-31 18:39   ` Krzysztof Kozlowski
@ 2016-05-31 19:21     ` Javier Martinez Canillas
  -1 siblings, 0 replies; 34+ messages in thread
From: Javier Martinez Canillas @ 2016-05-31 19:21 UTC (permalink / raw)
  To: Krzysztof Kozlowski, Kukjin Kim, Krzysztof Kozlowski,
	Sylwester Nawrocki, Tomasz Figa, Michael Turquette, Stephen Boyd,
	devicetree, linux-arm-kernel, linux-samsung-soc, linux-kernel,
	linux-clk

Hello Krzysztof,

On 05/31/2016 02:39 PM, Krzysztof Kozlowski wrote:
> Add nodes for Thermal Management Unit to exynos5410.dtsi. Use the same
> compatible as for Exynos5420 however without second base for TRIMINFO
> register.
> 
> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
> ---
>  arch/arm/boot/dts/exynos5410.dtsi | 55 +++++++++++++++++++++++++++++++++++++++
>  1 file changed, 55 insertions(+)
> 
> diff --git a/arch/arm/boot/dts/exynos5410.dtsi b/arch/arm/boot/dts/exynos5410.dtsi
> index 994d16a44fe4..f1effd3f03c4 100644
> --- a/arch/arm/boot/dts/exynos5410.dtsi
> +++ b/arch/arm/boot/dts/exynos5410.dtsi
> @@ -81,6 +81,42 @@
>  			#clock-cells = <1>;
>  		};
>  
> +		tmu_cpu0: tmu@10060000 {
> +			compatible = "samsung,exynos5420-tmu";
> +			reg = <0x10060000 0x100>;
> +			interrupts = <0 65 0>;

Please use GIC_SPI instead of 0 on these.

> +			clocks = <&clock CLK_TMU>;
> +			clock-names = "tmu_apbif";
> +			#include "exynos4412-tmu-sensor-conf.dtsi"
> +		};
> +
> +		tmu_cpu1: tmu@10064000 {
> +			compatible = "samsung,exynos5420-tmu";
> +			reg = <0x10064000 0x100>;
> +			interrupts = <0 183 0>;
> +			clocks = <&clock CLK_TMU>;
> +			clock-names = "tmu_apbif";
> +			#include "exynos4412-tmu-sensor-conf.dtsi"
> +		};
> +
> +		tmu_cpu2: tmu@10068000 {
> +			compatible = "samsung,exynos5420-tmu";
> +			reg = <0x10068000 0x100>;
> +			interrupts = <0 184 0>;
> +			clocks = <&clock CLK_TMU>;
> +			clock-names = "tmu_apbif";
> +			#include "exynos4412-tmu-sensor-conf.dtsi"
> +		};
> +
> +		tmu_cpu3: tmu@1006c000 {
> +			compatible = "samsung,exynos5420-tmu";
> +			reg = <0x1006c000 0x100>;
> +			interrupts = <0 185 0>;
> +			clocks = <&clock CLK_TMU>;
> +			clock-names = "tmu_apbif";
> +			#include "exynos4412-tmu-sensor-conf.dtsi"
> +		};
> +

Exynos5420 has 5 TMU channels and you are adding only 4 so I guess this
is another difference with Exynos5410 besides the TRIMINFO register not
being misplaced? Probably is worth to mention it in the commit message.

Anyway, the patch looks good to me.

Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com>

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America

^ permalink raw reply	[flat|nested] 34+ messages in thread

* [PATCH 4/6] ARM: dts: exynos: Add Thermal Management Unit to Exynos5410
@ 2016-05-31 19:21     ` Javier Martinez Canillas
  0 siblings, 0 replies; 34+ messages in thread
From: Javier Martinez Canillas @ 2016-05-31 19:21 UTC (permalink / raw)
  To: linux-arm-kernel

Hello Krzysztof,

On 05/31/2016 02:39 PM, Krzysztof Kozlowski wrote:
> Add nodes for Thermal Management Unit to exynos5410.dtsi. Use the same
> compatible as for Exynos5420 however without second base for TRIMINFO
> register.
> 
> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
> ---
>  arch/arm/boot/dts/exynos5410.dtsi | 55 +++++++++++++++++++++++++++++++++++++++
>  1 file changed, 55 insertions(+)
> 
> diff --git a/arch/arm/boot/dts/exynos5410.dtsi b/arch/arm/boot/dts/exynos5410.dtsi
> index 994d16a44fe4..f1effd3f03c4 100644
> --- a/arch/arm/boot/dts/exynos5410.dtsi
> +++ b/arch/arm/boot/dts/exynos5410.dtsi
> @@ -81,6 +81,42 @@
>  			#clock-cells = <1>;
>  		};
>  
> +		tmu_cpu0: tmu at 10060000 {
> +			compatible = "samsung,exynos5420-tmu";
> +			reg = <0x10060000 0x100>;
> +			interrupts = <0 65 0>;

Please use GIC_SPI instead of 0 on these.

> +			clocks = <&clock CLK_TMU>;
> +			clock-names = "tmu_apbif";
> +			#include "exynos4412-tmu-sensor-conf.dtsi"
> +		};
> +
> +		tmu_cpu1: tmu at 10064000 {
> +			compatible = "samsung,exynos5420-tmu";
> +			reg = <0x10064000 0x100>;
> +			interrupts = <0 183 0>;
> +			clocks = <&clock CLK_TMU>;
> +			clock-names = "tmu_apbif";
> +			#include "exynos4412-tmu-sensor-conf.dtsi"
> +		};
> +
> +		tmu_cpu2: tmu at 10068000 {
> +			compatible = "samsung,exynos5420-tmu";
> +			reg = <0x10068000 0x100>;
> +			interrupts = <0 184 0>;
> +			clocks = <&clock CLK_TMU>;
> +			clock-names = "tmu_apbif";
> +			#include "exynos4412-tmu-sensor-conf.dtsi"
> +		};
> +
> +		tmu_cpu3: tmu at 1006c000 {
> +			compatible = "samsung,exynos5420-tmu";
> +			reg = <0x1006c000 0x100>;
> +			interrupts = <0 185 0>;
> +			clocks = <&clock CLK_TMU>;
> +			clock-names = "tmu_apbif";
> +			#include "exynos4412-tmu-sensor-conf.dtsi"
> +		};
> +

Exynos5420 has 5 TMU channels and you are adding only 4 so I guess this
is another difference with Exynos5410 besides the TRIMINFO register not
being misplaced? Probably is worth to mention it in the commit message.

Anyway, the patch looks good to me.

Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com>

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH 3/6] ARM: dts: exynos: Interrupt for USB DWC3-1 differs between Exynos5420 and 5410
  2016-05-31 19:01     ` Javier Martinez Canillas
@ 2016-05-31 19:26       ` Krzysztof Kozlowski
  -1 siblings, 0 replies; 34+ messages in thread
From: Krzysztof Kozlowski @ 2016-05-31 19:26 UTC (permalink / raw)
  To: Javier Martinez Canillas
  Cc: Kukjin Kim, Sylwester Nawrocki, Tomasz Figa, Michael Turquette,
	Stephen Boyd, devicetree, linux-arm-kernel, linux-samsung-soc,
	linux-kernel, linux-clk

On Tue, May 31, 2016 at 9:01 PM, Javier Martinez Canillas
<javier@osg.samsung.com> wrote:
> Hello Krzysztof,
>
> On 05/31/2016 02:39 PM, Krzysztof Kozlowski wrote:
>> On Exynos5410 the SPI interrupt for second USB DWC3 (called DRD: Dual
>> Role Device) is different - 200 instead of 73.
>>
>> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
>> ---
>>  arch/arm/boot/dts/exynos5410.dtsi | 4 ++++
>>  arch/arm/boot/dts/exynos5420.dtsi | 4 ++++
>>  arch/arm/boot/dts/exynos54xx.dtsi | 1 -
>>  3 files changed, 8 insertions(+), 1 deletion(-)
>>
>> diff --git a/arch/arm/boot/dts/exynos5410.dtsi b/arch/arm/boot/dts/exynos5410.dtsi
>> index a937d9bdad90..994d16a44fe4 100644
>> --- a/arch/arm/boot/dts/exynos5410.dtsi
>> +++ b/arch/arm/boot/dts/exynos5410.dtsi
>> @@ -267,6 +267,10 @@
>>       clock-names = "usbdrd30";
>>  };
>>
>> +&usbdrd_dwc3_1 {
>> +     interrupts = <0 200 0>;
>
> Please use GIC_SPI from <dt-bindings/interrupt-controller/arm-gic.h> instead 0.
>
> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com>

Sure, thanks for feedback.

Krzysztof

^ permalink raw reply	[flat|nested] 34+ messages in thread

* [PATCH 3/6] ARM: dts: exynos: Interrupt for USB DWC3-1 differs between Exynos5420 and 5410
@ 2016-05-31 19:26       ` Krzysztof Kozlowski
  0 siblings, 0 replies; 34+ messages in thread
From: Krzysztof Kozlowski @ 2016-05-31 19:26 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, May 31, 2016 at 9:01 PM, Javier Martinez Canillas
<javier@osg.samsung.com> wrote:
> Hello Krzysztof,
>
> On 05/31/2016 02:39 PM, Krzysztof Kozlowski wrote:
>> On Exynos5410 the SPI interrupt for second USB DWC3 (called DRD: Dual
>> Role Device) is different - 200 instead of 73.
>>
>> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
>> ---
>>  arch/arm/boot/dts/exynos5410.dtsi | 4 ++++
>>  arch/arm/boot/dts/exynos5420.dtsi | 4 ++++
>>  arch/arm/boot/dts/exynos54xx.dtsi | 1 -
>>  3 files changed, 8 insertions(+), 1 deletion(-)
>>
>> diff --git a/arch/arm/boot/dts/exynos5410.dtsi b/arch/arm/boot/dts/exynos5410.dtsi
>> index a937d9bdad90..994d16a44fe4 100644
>> --- a/arch/arm/boot/dts/exynos5410.dtsi
>> +++ b/arch/arm/boot/dts/exynos5410.dtsi
>> @@ -267,6 +267,10 @@
>>       clock-names = "usbdrd30";
>>  };
>>
>> +&usbdrd_dwc3_1 {
>> +     interrupts = <0 200 0>;
>
> Please use GIC_SPI from <dt-bindings/interrupt-controller/arm-gic.h> instead 0.
>
> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com>

Sure, thanks for feedback.

Krzysztof

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH 4/6] ARM: dts: exynos: Add Thermal Management Unit to Exynos5410
  2016-05-31 19:21     ` Javier Martinez Canillas
@ 2016-05-31 19:28       ` Krzysztof Kozlowski
  -1 siblings, 0 replies; 34+ messages in thread
From: Krzysztof Kozlowski @ 2016-05-31 19:28 UTC (permalink / raw)
  To: Javier Martinez Canillas
  Cc: Kukjin Kim, Sylwester Nawrocki, Tomasz Figa, Michael Turquette,
	Stephen Boyd, devicetree, linux-arm-kernel, linux-samsung-soc,
	linux-kernel, linux-clk

On Tue, May 31, 2016 at 9:21 PM, Javier Martinez Canillas
<javier@osg.samsung.com> wrote:
> Hello Krzysztof,
>
> On 05/31/2016 02:39 PM, Krzysztof Kozlowski wrote:
>> Add nodes for Thermal Management Unit to exynos5410.dtsi. Use the same
>> compatible as for Exynos5420 however without second base for TRIMINFO
>> register.
>>
>> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
>> ---
>>  arch/arm/boot/dts/exynos5410.dtsi | 55 +++++++++++++++++++++++++++++++++++++++
>>  1 file changed, 55 insertions(+)
>>
>> diff --git a/arch/arm/boot/dts/exynos5410.dtsi b/arch/arm/boot/dts/exynos5410.dtsi
>> index 994d16a44fe4..f1effd3f03c4 100644
>> --- a/arch/arm/boot/dts/exynos5410.dtsi
>> +++ b/arch/arm/boot/dts/exynos5410.dtsi
>> @@ -81,6 +81,42 @@
>>                       #clock-cells = <1>;
>>               };
>>
>> +             tmu_cpu0: tmu@10060000 {
>> +                     compatible = "samsung,exynos5420-tmu";
>> +                     reg = <0x10060000 0x100>;
>> +                     interrupts = <0 65 0>;
>
> Please use GIC_SPI instead of 0 on these.

ok

>
>> +                     clocks = <&clock CLK_TMU>;
>> +                     clock-names = "tmu_apbif";
>> +                     #include "exynos4412-tmu-sensor-conf.dtsi"
>> +             };
>> +
>> +             tmu_cpu1: tmu@10064000 {
>> +                     compatible = "samsung,exynos5420-tmu";
>> +                     reg = <0x10064000 0x100>;
>> +                     interrupts = <0 183 0>;
>> +                     clocks = <&clock CLK_TMU>;
>> +                     clock-names = "tmu_apbif";
>> +                     #include "exynos4412-tmu-sensor-conf.dtsi"
>> +             };
>> +
>> +             tmu_cpu2: tmu@10068000 {
>> +                     compatible = "samsung,exynos5420-tmu";
>> +                     reg = <0x10068000 0x100>;
>> +                     interrupts = <0 184 0>;
>> +                     clocks = <&clock CLK_TMU>;
>> +                     clock-names = "tmu_apbif";
>> +                     #include "exynos4412-tmu-sensor-conf.dtsi"
>> +             };
>> +
>> +             tmu_cpu3: tmu@1006c000 {
>> +                     compatible = "samsung,exynos5420-tmu";
>> +                     reg = <0x1006c000 0x100>;
>> +                     interrupts = <0 185 0>;
>> +                     clocks = <&clock CLK_TMU>;
>> +                     clock-names = "tmu_apbif";
>> +                     #include "exynos4412-tmu-sensor-conf.dtsi"
>> +             };
>> +
>
> Exynos5420 has 5 TMU channels and you are adding only 4 so I guess this
> is another difference with Exynos5410 besides the TRIMINFO register not
> being misplaced? Probably is worth to mention it in the commit message.


Yes, indeed there is no GPU thermal zone. I'll mention it.

Best regards,
Krzysztof

^ permalink raw reply	[flat|nested] 34+ messages in thread

* [PATCH 4/6] ARM: dts: exynos: Add Thermal Management Unit to Exynos5410
@ 2016-05-31 19:28       ` Krzysztof Kozlowski
  0 siblings, 0 replies; 34+ messages in thread
From: Krzysztof Kozlowski @ 2016-05-31 19:28 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, May 31, 2016 at 9:21 PM, Javier Martinez Canillas
<javier@osg.samsung.com> wrote:
> Hello Krzysztof,
>
> On 05/31/2016 02:39 PM, Krzysztof Kozlowski wrote:
>> Add nodes for Thermal Management Unit to exynos5410.dtsi. Use the same
>> compatible as for Exynos5420 however without second base for TRIMINFO
>> register.
>>
>> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
>> ---
>>  arch/arm/boot/dts/exynos5410.dtsi | 55 +++++++++++++++++++++++++++++++++++++++
>>  1 file changed, 55 insertions(+)
>>
>> diff --git a/arch/arm/boot/dts/exynos5410.dtsi b/arch/arm/boot/dts/exynos5410.dtsi
>> index 994d16a44fe4..f1effd3f03c4 100644
>> --- a/arch/arm/boot/dts/exynos5410.dtsi
>> +++ b/arch/arm/boot/dts/exynos5410.dtsi
>> @@ -81,6 +81,42 @@
>>                       #clock-cells = <1>;
>>               };
>>
>> +             tmu_cpu0: tmu at 10060000 {
>> +                     compatible = "samsung,exynos5420-tmu";
>> +                     reg = <0x10060000 0x100>;
>> +                     interrupts = <0 65 0>;
>
> Please use GIC_SPI instead of 0 on these.

ok

>
>> +                     clocks = <&clock CLK_TMU>;
>> +                     clock-names = "tmu_apbif";
>> +                     #include "exynos4412-tmu-sensor-conf.dtsi"
>> +             };
>> +
>> +             tmu_cpu1: tmu at 10064000 {
>> +                     compatible = "samsung,exynos5420-tmu";
>> +                     reg = <0x10064000 0x100>;
>> +                     interrupts = <0 183 0>;
>> +                     clocks = <&clock CLK_TMU>;
>> +                     clock-names = "tmu_apbif";
>> +                     #include "exynos4412-tmu-sensor-conf.dtsi"
>> +             };
>> +
>> +             tmu_cpu2: tmu at 10068000 {
>> +                     compatible = "samsung,exynos5420-tmu";
>> +                     reg = <0x10068000 0x100>;
>> +                     interrupts = <0 184 0>;
>> +                     clocks = <&clock CLK_TMU>;
>> +                     clock-names = "tmu_apbif";
>> +                     #include "exynos4412-tmu-sensor-conf.dtsi"
>> +             };
>> +
>> +             tmu_cpu3: tmu at 1006c000 {
>> +                     compatible = "samsung,exynos5420-tmu";
>> +                     reg = <0x1006c000 0x100>;
>> +                     interrupts = <0 185 0>;
>> +                     clocks = <&clock CLK_TMU>;
>> +                     clock-names = "tmu_apbif";
>> +                     #include "exynos4412-tmu-sensor-conf.dtsi"
>> +             };
>> +
>
> Exynos5420 has 5 TMU channels and you are adding only 4 so I guess this
> is another difference with Exynos5410 besides the TRIMINFO register not
> being misplaced? Probably is worth to mention it in the commit message.


Yes, indeed there is no GPU thermal zone. I'll mention it.

Best regards,
Krzysztof

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH 5/6] ARM: dts: exynos: Configure PWM, usb3503, PMIC and thermal on Odroid XU board
  2016-05-31 18:39   ` Krzysztof Kozlowski
@ 2016-05-31 19:36     ` Javier Martinez Canillas
  -1 siblings, 0 replies; 34+ messages in thread
From: Javier Martinez Canillas @ 2016-05-31 19:36 UTC (permalink / raw)
  To: Krzysztof Kozlowski, Kukjin Kim, Krzysztof Kozlowski,
	Sylwester Nawrocki, Tomasz Figa, Michael Turquette, Stephen Boyd,
	devicetree, linux-arm-kernel, linux-samsung-soc, linux-kernel,
	linux-clk

Hello Krzysztof,

On 05/31/2016 02:39 PM, Krzysztof Kozlowski wrote:
> Extend the DTS for Exynos5410-based Odroid XU board with:
> 1. Proper PWM outputs,
> 2. usb3503 USB HUB (with integrated LAN9730 ethernet adapter (smsc95xx)),
> 3. Maxim 77802 PMIC (regulators, 32 kHz clocks, RTC),
> 4. CPU thermal (trip points are the same as in Odroid XU3/XU4 but
>    cooling maps are different as there is no CPU freq and only one
>    cluster available for now),
> 5. Regulator supplies for USB 3.0.
> 
> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
> 
> ---
> 

[snip]

> +
> +			ldo10_reg: LDO10 {
> +				regulator-name = "vdd18_mipi";
> +				regulator-min-microvolt = <1800000>;
> +				regulator-max-microvolt = <1800000>;
> +				regulator-always-on;
> +			};
> +

[snip]

> +
> +			ldo12_reg: LDO12 {
> +				regulator-name = "vdd33_usb3";
> +				regulator-min-microvolt = <3300000>;
> +				regulator-max-microvolt = <3300000>;
> +				regulator-always-on;
> +			};
> +

[snip]

> +
> +			ldo15_reg: LDO15 {
> +				regulator-name = "vdd10_usb3";
> +				regulator-min-microvolt = <1000000>;
> +				regulator-max-microvolt = <1000000>;
> +				regulator-always-on;
> +			};
> +

I see that LDO 10, 12 and 15 are used by still marked as always-on. Did
you try not marking as always-on those or that also causes issues like
in the other regulators were you added comments about being always-on?

Besides that, patch looks good to me.

Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com>

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America

^ permalink raw reply	[flat|nested] 34+ messages in thread

* [PATCH 5/6] ARM: dts: exynos: Configure PWM, usb3503, PMIC and thermal on Odroid XU board
@ 2016-05-31 19:36     ` Javier Martinez Canillas
  0 siblings, 0 replies; 34+ messages in thread
From: Javier Martinez Canillas @ 2016-05-31 19:36 UTC (permalink / raw)
  To: linux-arm-kernel

Hello Krzysztof,

On 05/31/2016 02:39 PM, Krzysztof Kozlowski wrote:
> Extend the DTS for Exynos5410-based Odroid XU board with:
> 1. Proper PWM outputs,
> 2. usb3503 USB HUB (with integrated LAN9730 ethernet adapter (smsc95xx)),
> 3. Maxim 77802 PMIC (regulators, 32 kHz clocks, RTC),
> 4. CPU thermal (trip points are the same as in Odroid XU3/XU4 but
>    cooling maps are different as there is no CPU freq and only one
>    cluster available for now),
> 5. Regulator supplies for USB 3.0.
> 
> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
> 
> ---
> 

[snip]

> +
> +			ldo10_reg: LDO10 {
> +				regulator-name = "vdd18_mipi";
> +				regulator-min-microvolt = <1800000>;
> +				regulator-max-microvolt = <1800000>;
> +				regulator-always-on;
> +			};
> +

[snip]

> +
> +			ldo12_reg: LDO12 {
> +				regulator-name = "vdd33_usb3";
> +				regulator-min-microvolt = <3300000>;
> +				regulator-max-microvolt = <3300000>;
> +				regulator-always-on;
> +			};
> +

[snip]

> +
> +			ldo15_reg: LDO15 {
> +				regulator-name = "vdd10_usb3";
> +				regulator-min-microvolt = <1000000>;
> +				regulator-max-microvolt = <1000000>;
> +				regulator-always-on;
> +			};
> +

I see that LDO 10, 12 and 15 are used by still marked as always-on. Did
you try not marking as always-on those or that also causes issues like
in the other regulators were you added comments about being always-on?

Besides that, patch looks good to me.

Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com>

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH 6/6] ARM: dts: exynos: No need to enable TMU nodes on Odroid XU3 family
  2016-05-31 18:39   ` Krzysztof Kozlowski
@ 2016-05-31 19:37     ` Javier Martinez Canillas
  -1 siblings, 0 replies; 34+ messages in thread
From: Javier Martinez Canillas @ 2016-05-31 19:37 UTC (permalink / raw)
  To: Krzysztof Kozlowski, Kukjin Kim, Krzysztof Kozlowski,
	Sylwester Nawrocki, Tomasz Figa, Michael Turquette, Stephen Boyd,
	devicetree, linux-arm-kernel, linux-samsung-soc, linux-kernel,
	linux-clk

Hello Krzysztof,

On 05/31/2016 02:39 PM, Krzysztof Kozlowski wrote:
> The thermal nodes are not disabled in exynos5420.dtsi so there is no
> need to manually enable them on Odroid XU3/XU3-Lite/XU4 boards.
> 
> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
> ---

Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com>

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America

^ permalink raw reply	[flat|nested] 34+ messages in thread

* [PATCH 6/6] ARM: dts: exynos: No need to enable TMU nodes on Odroid XU3 family
@ 2016-05-31 19:37     ` Javier Martinez Canillas
  0 siblings, 0 replies; 34+ messages in thread
From: Javier Martinez Canillas @ 2016-05-31 19:37 UTC (permalink / raw)
  To: linux-arm-kernel

Hello Krzysztof,

On 05/31/2016 02:39 PM, Krzysztof Kozlowski wrote:
> The thermal nodes are not disabled in exynos5420.dtsi so there is no
> need to manually enable them on Odroid XU3/XU3-Lite/XU4 boards.
> 
> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
> ---

Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com>

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH 5/6] ARM: dts: exynos: Configure PWM, usb3503, PMIC and thermal on Odroid XU board
  2016-05-31 19:36     ` Javier Martinez Canillas
@ 2016-05-31 20:05       ` Krzysztof Kozlowski
  -1 siblings, 0 replies; 34+ messages in thread
From: Krzysztof Kozlowski @ 2016-05-31 20:05 UTC (permalink / raw)
  To: Javier Martinez Canillas
  Cc: Kukjin Kim, Sylwester Nawrocki, Tomasz Figa, Michael Turquette,
	Stephen Boyd, devicetree, linux-arm-kernel, linux-samsung-soc,
	linux-kernel, linux-clk

On Tue, May 31, 2016 at 9:36 PM, Javier Martinez Canillas
<javier@osg.samsung.com> wrote:
> Hello Krzysztof,
>
> On 05/31/2016 02:39 PM, Krzysztof Kozlowski wrote:
>> Extend the DTS for Exynos5410-based Odroid XU board with:
>> 1. Proper PWM outputs,
>> 2. usb3503 USB HUB (with integrated LAN9730 ethernet adapter (smsc95xx)),
>> 3. Maxim 77802 PMIC (regulators, 32 kHz clocks, RTC),
>> 4. CPU thermal (trip points are the same as in Odroid XU3/XU4 but
>>    cooling maps are different as there is no CPU freq and only one
>>    cluster available for now),
>> 5. Regulator supplies for USB 3.0.
>>
>> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
>>
>> ---
>>
>
> [snip]
>
>> +
>> +                     ldo10_reg: LDO10 {
>> +                             regulator-name = "vdd18_mipi";
>> +                             regulator-min-microvolt = <1800000>;
>> +                             regulator-max-microvolt = <1800000>;
>> +                             regulator-always-on;
>> +                     };
>> +
>
> [snip]
>
>> +
>> +                     ldo12_reg: LDO12 {
>> +                             regulator-name = "vdd33_usb3";
>> +                             regulator-min-microvolt = <3300000>;
>> +                             regulator-max-microvolt = <3300000>;
>> +                             regulator-always-on;
>> +                     };
>> +
>
> [snip]
>
>> +
>> +                     ldo15_reg: LDO15 {
>> +                             regulator-name = "vdd10_usb3";
>> +                             regulator-min-microvolt = <1000000>;
>> +                             regulator-max-microvolt = <1000000>;
>> +                             regulator-always-on;
>> +                     };
>> +
>
> I see that LDO 10, 12 and 15 are used by still marked as always-on. Did
> you try not marking as always-on those or that also causes issues like
> in the other regulators were you added comments about being always-on?
>
> Besides that, patch looks good to me.

The LDO10 is supplying few more elements (MIPI, HDMI, ADC and
something called EFNAND). Having it non-always-on still works but
maybe because I did not test these elements.

LDO12 and LDO15 supply also VDD10_HSIC and UHOST (used by USB2.0 ports
and attached on board: usb3503 and lan9730) so if it is not enabled by
USB 3.0, then they won't work. I guess the usb 2.0 driver should also
take regulators.

So overall the board works after removing always-on but it is not
properly described in DT so I prefer to leave them.

Best regards,
Krzysztof

^ permalink raw reply	[flat|nested] 34+ messages in thread

* [PATCH 5/6] ARM: dts: exynos: Configure PWM, usb3503, PMIC and thermal on Odroid XU board
@ 2016-05-31 20:05       ` Krzysztof Kozlowski
  0 siblings, 0 replies; 34+ messages in thread
From: Krzysztof Kozlowski @ 2016-05-31 20:05 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, May 31, 2016 at 9:36 PM, Javier Martinez Canillas
<javier@osg.samsung.com> wrote:
> Hello Krzysztof,
>
> On 05/31/2016 02:39 PM, Krzysztof Kozlowski wrote:
>> Extend the DTS for Exynos5410-based Odroid XU board with:
>> 1. Proper PWM outputs,
>> 2. usb3503 USB HUB (with integrated LAN9730 ethernet adapter (smsc95xx)),
>> 3. Maxim 77802 PMIC (regulators, 32 kHz clocks, RTC),
>> 4. CPU thermal (trip points are the same as in Odroid XU3/XU4 but
>>    cooling maps are different as there is no CPU freq and only one
>>    cluster available for now),
>> 5. Regulator supplies for USB 3.0.
>>
>> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
>>
>> ---
>>
>
> [snip]
>
>> +
>> +                     ldo10_reg: LDO10 {
>> +                             regulator-name = "vdd18_mipi";
>> +                             regulator-min-microvolt = <1800000>;
>> +                             regulator-max-microvolt = <1800000>;
>> +                             regulator-always-on;
>> +                     };
>> +
>
> [snip]
>
>> +
>> +                     ldo12_reg: LDO12 {
>> +                             regulator-name = "vdd33_usb3";
>> +                             regulator-min-microvolt = <3300000>;
>> +                             regulator-max-microvolt = <3300000>;
>> +                             regulator-always-on;
>> +                     };
>> +
>
> [snip]
>
>> +
>> +                     ldo15_reg: LDO15 {
>> +                             regulator-name = "vdd10_usb3";
>> +                             regulator-min-microvolt = <1000000>;
>> +                             regulator-max-microvolt = <1000000>;
>> +                             regulator-always-on;
>> +                     };
>> +
>
> I see that LDO 10, 12 and 15 are used by still marked as always-on. Did
> you try not marking as always-on those or that also causes issues like
> in the other regulators were you added comments about being always-on?
>
> Besides that, patch looks good to me.

The LDO10 is supplying few more elements (MIPI, HDMI, ADC and
something called EFNAND). Having it non-always-on still works but
maybe because I did not test these elements.

LDO12 and LDO15 supply also VDD10_HSIC and UHOST (used by USB2.0 ports
and attached on board: usb3503 and lan9730) so if it is not enabled by
USB 3.0, then they won't work. I guess the usb 2.0 driver should also
take regulators.

So overall the board works after removing always-on but it is not
properly described in DT so I prefer to leave them.

Best regards,
Krzysztof

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH 5/6] ARM: dts: exynos: Configure PWM, usb3503, PMIC and thermal on Odroid XU board
  2016-05-31 20:05       ` Krzysztof Kozlowski
@ 2016-05-31 20:10         ` Javier Martinez Canillas
  -1 siblings, 0 replies; 34+ messages in thread
From: Javier Martinez Canillas @ 2016-05-31 20:10 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Kukjin Kim, Sylwester Nawrocki, Tomasz Figa, Michael Turquette,
	Stephen Boyd, devicetree, linux-arm-kernel, linux-samsung-soc,
	linux-kernel, linux-clk

Hello Krzysztof,

On 05/31/2016 04:05 PM, Krzysztof Kozlowski wrote:
> On Tue, May 31, 2016 at 9:36 PM, Javier Martinez Canillas

[snip]

>>
>> I see that LDO 10, 12 and 15 are used by still marked as always-on. Did
>> you try not marking as always-on those or that also causes issues like
>> in the other regulators were you added comments about being always-on?
>>
>> Besides that, patch looks good to me.
> 
> The LDO10 is supplying few more elements (MIPI, HDMI, ADC and
> something called EFNAND). Having it non-always-on still works but
> maybe because I did not test these elements.
> 
> LDO12 and LDO15 supply also VDD10_HSIC and UHOST (used by USB2.0 ports
> and attached on board: usb3503 and lan9730) so if it is not enabled by
> USB 3.0, then they won't work. I guess the usb 2.0 driver should also
> take regulators.
> 
> So overall the board works after removing always-on but it is not
> properly described in DT so I prefer to leave them.
> 

Agreed, thanks a lot for your explanations.

> Best regards,
> Krzysztof

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America

^ permalink raw reply	[flat|nested] 34+ messages in thread

* [PATCH 5/6] ARM: dts: exynos: Configure PWM, usb3503, PMIC and thermal on Odroid XU board
@ 2016-05-31 20:10         ` Javier Martinez Canillas
  0 siblings, 0 replies; 34+ messages in thread
From: Javier Martinez Canillas @ 2016-05-31 20:10 UTC (permalink / raw)
  To: linux-arm-kernel

Hello Krzysztof,

On 05/31/2016 04:05 PM, Krzysztof Kozlowski wrote:
> On Tue, May 31, 2016 at 9:36 PM, Javier Martinez Canillas

[snip]

>>
>> I see that LDO 10, 12 and 15 are used by still marked as always-on. Did
>> you try not marking as always-on those or that also causes issues like
>> in the other regulators were you added comments about being always-on?
>>
>> Besides that, patch looks good to me.
> 
> The LDO10 is supplying few more elements (MIPI, HDMI, ADC and
> something called EFNAND). Having it non-always-on still works but
> maybe because I did not test these elements.
> 
> LDO12 and LDO15 supply also VDD10_HSIC and UHOST (used by USB2.0 ports
> and attached on board: usb3503 and lan9730) so if it is not enabled by
> USB 3.0, then they won't work. I guess the usb 2.0 driver should also
> take regulators.
> 
> So overall the board works after removing always-on but it is not
> properly described in DT so I prefer to leave them.
> 

Agreed, thanks a lot for your explanations.

> Best regards,
> Krzysztof

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PATCH 2/6] clk: samsung: exynos5410: Add TMU clock
  2016-05-31 18:56     ` Javier Martinez Canillas
@ 2016-06-01  9:59       ` Sylwester Nawrocki
  -1 siblings, 0 replies; 34+ messages in thread
From: Sylwester Nawrocki @ 2016-06-01  9:59 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Javier Martinez Canillas, Kukjin Kim, Krzysztof Kozlowski,
	Tomasz Figa, Michael Turquette, Stephen Boyd, devicetree,
	linux-arm-kernel, linux-samsung-soc, linux-kernel, linux-clk

On 05/31/2016 08:56 PM, Javier Martinez Canillas wrote:
> On 05/31/2016 02:39 PM, Krzysztof Kozlowski wrote:
>> > Add clock for TMU to the Exynos5410 clock driver.
>> > 
>> > Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
>> > ---
>> >  drivers/clk/samsung/clk-exynos5410.c | 1 +
>> >  1 file changed, 1 insertion(+)
>> > 
>> > diff --git a/drivers/clk/samsung/clk-exynos5410.c b/drivers/clk/samsung/clk-exynos5410.c
>> > index 6c2e59c576ee..db9978dc6e83 100644
>> > --- a/drivers/clk/samsung/clk-exynos5410.c
>> > +++ b/drivers/clk/samsung/clk-exynos5410.c
>> > @@ -160,6 +160,7 @@ static struct samsung_div_clock exynos5410_div_clks[] __initdata = {
>> >  static struct samsung_gate_clock exynos5410_gate_clks[] __initdata = {
>> >  	GATE(CLK_MCT, "mct", "aclk66", GATE_IP_PERIS, 18, 0, 0),
>> >  	GATE(CLK_RTC, "rtc", "aclk66", GATE_IP_PERIS, 20, 0, 0),
>> > +	GATE(CLK_TMU, "tmu", "aclk66", GATE_IP_PERIS, 21, 0, 0),
>> >  
>> >  	GATE(CLK_SCLK_MMC0, "sclk_mmc0", "div_mmc_pre0",
>> >  			SRC_MASK_FSYS, 0, CLK_SET_RATE_PARENT, 0),
>> > 
> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com>

I have applied patches 1/6, 2/6. I will hold back for a moment
with providing another tag for the "dt-bindings" patches, in case
there are more such patches submitted in the coming days.

-- 
Thanks,
Sylwester

^ permalink raw reply	[flat|nested] 34+ messages in thread

* [PATCH 2/6] clk: samsung: exynos5410: Add TMU clock
@ 2016-06-01  9:59       ` Sylwester Nawrocki
  0 siblings, 0 replies; 34+ messages in thread
From: Sylwester Nawrocki @ 2016-06-01  9:59 UTC (permalink / raw)
  To: linux-arm-kernel

On 05/31/2016 08:56 PM, Javier Martinez Canillas wrote:
> On 05/31/2016 02:39 PM, Krzysztof Kozlowski wrote:
>> > Add clock for TMU to the Exynos5410 clock driver.
>> > 
>> > Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
>> > ---
>> >  drivers/clk/samsung/clk-exynos5410.c | 1 +
>> >  1 file changed, 1 insertion(+)
>> > 
>> > diff --git a/drivers/clk/samsung/clk-exynos5410.c b/drivers/clk/samsung/clk-exynos5410.c
>> > index 6c2e59c576ee..db9978dc6e83 100644
>> > --- a/drivers/clk/samsung/clk-exynos5410.c
>> > +++ b/drivers/clk/samsung/clk-exynos5410.c
>> > @@ -160,6 +160,7 @@ static struct samsung_div_clock exynos5410_div_clks[] __initdata = {
>> >  static struct samsung_gate_clock exynos5410_gate_clks[] __initdata = {
>> >  	GATE(CLK_MCT, "mct", "aclk66", GATE_IP_PERIS, 18, 0, 0),
>> >  	GATE(CLK_RTC, "rtc", "aclk66", GATE_IP_PERIS, 20, 0, 0),
>> > +	GATE(CLK_TMU, "tmu", "aclk66", GATE_IP_PERIS, 21, 0, 0),
>> >  
>> >  	GATE(CLK_SCLK_MMC0, "sclk_mmc0", "div_mmc_pre0",
>> >  			SRC_MASK_FSYS, 0, CLK_SET_RATE_PARENT, 0),
>> > 
> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com>

I have applied patches 1/6, 2/6. I will hold back for a moment
with providing another tag for the "dt-bindings" patches, in case
there are more such patches submitted in the coming days.

-- 
Thanks,
Sylwester

^ permalink raw reply	[flat|nested] 34+ messages in thread

end of thread, other threads:[~2016-06-01  9:59 UTC | newest]

Thread overview: 34+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-05-31 18:39 [PATCH 1/6] dt-bindings: clock: Add TMU clock ID to Exynos5410 Krzysztof Kozlowski
2016-05-31 18:39 ` Krzysztof Kozlowski
2016-05-31 18:39 ` [PATCH 2/6] clk: samsung: exynos5410: Add TMU clock Krzysztof Kozlowski
2016-05-31 18:39   ` Krzysztof Kozlowski
2016-05-31 18:56   ` Javier Martinez Canillas
2016-05-31 18:56     ` Javier Martinez Canillas
2016-06-01  9:59     ` Sylwester Nawrocki
2016-06-01  9:59       ` Sylwester Nawrocki
2016-05-31 18:39 ` [PATCH 3/6] ARM: dts: exynos: Interrupt for USB DWC3-1 differs between Exynos5420 and 5410 Krzysztof Kozlowski
2016-05-31 18:39   ` Krzysztof Kozlowski
2016-05-31 19:01   ` Javier Martinez Canillas
2016-05-31 19:01     ` Javier Martinez Canillas
2016-05-31 19:26     ` Krzysztof Kozlowski
2016-05-31 19:26       ` Krzysztof Kozlowski
2016-05-31 18:39 ` [PATCH 4/6] ARM: dts: exynos: Add Thermal Management Unit to Exynos5410 Krzysztof Kozlowski
2016-05-31 18:39   ` Krzysztof Kozlowski
2016-05-31 19:21   ` Javier Martinez Canillas
2016-05-31 19:21     ` Javier Martinez Canillas
2016-05-31 19:28     ` Krzysztof Kozlowski
2016-05-31 19:28       ` Krzysztof Kozlowski
2016-05-31 18:39 ` [PATCH 5/6] ARM: dts: exynos: Configure PWM, usb3503, PMIC and thermal on Odroid XU board Krzysztof Kozlowski
2016-05-31 18:39   ` Krzysztof Kozlowski
2016-05-31 19:36   ` Javier Martinez Canillas
2016-05-31 19:36     ` Javier Martinez Canillas
2016-05-31 20:05     ` Krzysztof Kozlowski
2016-05-31 20:05       ` Krzysztof Kozlowski
2016-05-31 20:10       ` Javier Martinez Canillas
2016-05-31 20:10         ` Javier Martinez Canillas
2016-05-31 18:39 ` [PATCH 6/6] ARM: dts: exynos: No need to enable TMU nodes on Odroid XU3 family Krzysztof Kozlowski
2016-05-31 18:39   ` Krzysztof Kozlowski
2016-05-31 19:37   ` Javier Martinez Canillas
2016-05-31 19:37     ` Javier Martinez Canillas
2016-05-31 18:53 ` [PATCH 1/6] dt-bindings: clock: Add TMU clock ID to Exynos5410 Javier Martinez Canillas
2016-05-31 18:53   ` Javier Martinez Canillas

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.