All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v4 0/4] ARM: dts: exynos: Prepare Spring
@ 2014-07-31 16:08 ` Andreas Färber
  0 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 16:08 UTC (permalink / raw)
  To: linux-samsung-soc
  Cc: linux-arm-kernel, devicetree, Stephan van Schaik,
	Vincent Palatin, Doug Anderson, Javier Martinez Canillas,
	Andreas Färber

Hello,

Based on the preinstalled 3.8 based ChromeOS kernel and previous 3.15 
based attempts by Stephan and me that broke for 3.16, I've prepared a 
device tree for the HP Chromebook 11 aka Google Spring.

v4 fixes a pinctrl bug.

Not yet enabled are trackpad, Wifi and sound.

My rebasing branch for testing is here:
https://github.com/afaerber/linux/commits/spring-next

Regards,
Andreas

v1 -> v2:
* Dropped 3 documentation patches from series:
  2 picked up,
  https://patchwork.kernel.org/patch/4397271/
  https://patchwork.kernel.org/patch/4397291/
  1 already sent separately as v2, pending.
  https://patchwork.kernel.org/patch/4424881/
* Minimized and beautified Spring device tree and to some degree Snow as well.
  See individual patches.

v2 -> v3:
* Rebased: Two -cros-common cleanup patches were already applied
* Lots of small cleanups for both Snow and Spring
* Enabled I2S in Spring for symmetry
* Added lid-switch and gpio-keys pinctrls to Spring

v3 -> v4:
* Fixed pin-function 1 -> 0 for dp-hpd pinctrl, style cleanup


Andreas Färber (4):
  ARM: dts: Fix MMC pinctrl for exynos5250-snow
  ARM: dts: Fold exynos5250-cros-common into exynos5250-snow
  ARM: dts: Clean up exynos5250-snow
  ARM: dts: Add exynos5250-spring device tree

 arch/arm/boot/dts/Makefile                    |   1 +
 arch/arm/boot/dts/exynos5250-cros-common.dtsi | 164 --------
 arch/arm/boot/dts/exynos5250-snow.dts         | 338 ++++++++++------
 arch/arm/boot/dts/exynos5250-spring.dts       | 539 ++++++++++++++++++++++++++
 4 files changed, 770 insertions(+), 272 deletions(-)
 delete mode 100644 arch/arm/boot/dts/exynos5250-cros-common.dtsi
 create mode 100644 arch/arm/boot/dts/exynos5250-spring.dts

-- 
1.9.3

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

* [PATCH v4 0/4] ARM: dts: exynos: Prepare Spring
@ 2014-07-31 16:08 ` Andreas Färber
  0 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 16:08 UTC (permalink / raw)
  To: linux-arm-kernel

Hello,

Based on the preinstalled 3.8 based ChromeOS kernel and previous 3.15 
based attempts by Stephan and me that broke for 3.16, I've prepared a 
device tree for the HP Chromebook 11 aka Google Spring.

v4 fixes a pinctrl bug.

Not yet enabled are trackpad, Wifi and sound.

My rebasing branch for testing is here:
https://github.com/afaerber/linux/commits/spring-next

Regards,
Andreas

v1 -> v2:
* Dropped 3 documentation patches from series:
  2 picked up,
  https://patchwork.kernel.org/patch/4397271/
  https://patchwork.kernel.org/patch/4397291/
  1 already sent separately as v2, pending.
  https://patchwork.kernel.org/patch/4424881/
* Minimized and beautified Spring device tree and to some degree Snow as well.
  See individual patches.

v2 -> v3:
* Rebased: Two -cros-common cleanup patches were already applied
* Lots of small cleanups for both Snow and Spring
* Enabled I2S in Spring for symmetry
* Added lid-switch and gpio-keys pinctrls to Spring

v3 -> v4:
* Fixed pin-function 1 -> 0 for dp-hpd pinctrl, style cleanup


Andreas F?rber (4):
  ARM: dts: Fix MMC pinctrl for exynos5250-snow
  ARM: dts: Fold exynos5250-cros-common into exynos5250-snow
  ARM: dts: Clean up exynos5250-snow
  ARM: dts: Add exynos5250-spring device tree

 arch/arm/boot/dts/Makefile                    |   1 +
 arch/arm/boot/dts/exynos5250-cros-common.dtsi | 164 --------
 arch/arm/boot/dts/exynos5250-snow.dts         | 338 ++++++++++------
 arch/arm/boot/dts/exynos5250-spring.dts       | 539 ++++++++++++++++++++++++++
 4 files changed, 770 insertions(+), 272 deletions(-)
 delete mode 100644 arch/arm/boot/dts/exynos5250-cros-common.dtsi
 create mode 100644 arch/arm/boot/dts/exynos5250-spring.dts

-- 
1.9.3

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

* [PATCH v4 1/4] ARM: dts: Fix MMC pinctrl for exynos5250-snow
  2014-07-31 16:08 ` Andreas Färber
  (?)
@ 2014-07-31 16:08   ` Andreas Färber
  -1 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 16:08 UTC (permalink / raw)
  To: linux-samsung-soc
  Cc: linux-arm-kernel, devicetree, Stephan van Schaik,
	Vincent Palatin, Doug Anderson, Javier Martinez Canillas,
	Andreas Färber, Jaehoon Chung, Ben Dooks, Kukjin Kim,
	Rob Herring, Pawel Moll, Mark Rutland, Ian Campbell, Kumar Gala,
	Russell King, open list

The pinctrl properties should be on the device directly and not on the
slot sub-node.

Reported-by: Doug Anderson <dianders@chromium.org>
Cc: Jaehoon Chung <jh80.chung@samsung.com>
Signed-off-by: Andreas Färber <afaerber@suse.de>
---
 v3 -> v4: Unchanged
 
 v3: New (Doug Anderson)
 Redundant with Jaehoon Chung's general slot@0 deprecation,
 in case that hits the tree earlier.

 arch/arm/boot/dts/exynos5250-snow.dts | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/arch/arm/boot/dts/exynos5250-snow.dts b/arch/arm/boot/dts/exynos5250-snow.dts
index f2b8c4116541..eb437f6afec1 100644
--- a/arch/arm/boot/dts/exynos5250-snow.dts
+++ b/arch/arm/boot/dts/exynos5250-snow.dts
@@ -240,10 +240,8 @@
 	 */
 	mmc@12230000 {
 		status = "okay";
-		slot@0 {
-			pinctrl-names = "default";
-			pinctrl-0 = <&sd3_clk &sd3_cmd &sd3_bus4>;
-		};
+		pinctrl-names = "default";
+		pinctrl-0 = <&sd3_clk &sd3_cmd &sd3_bus4>;
 	};
 
 	i2c@12CD0000 {
-- 
1.9.3


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

* [PATCH v4 1/4] ARM: dts: Fix MMC pinctrl for exynos5250-snow
@ 2014-07-31 16:08   ` Andreas Färber
  0 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 16:08 UTC (permalink / raw)
  To: linux-samsung-soc
  Cc: linux-arm-kernel, devicetree, Stephan van Schaik,
	Vincent Palatin, Doug Anderson, Javier Martinez Canillas,
	Andreas Färber, Jaehoon Chung, Ben Dooks, Kukjin Kim,
	Rob Herring, Pawel Moll, Mark Rutland, Ian Campbell, Kumar Gala,
	Russell King, open list

The pinctrl properties should be on the device directly and not on the
slot sub-node.

Reported-by: Doug Anderson <dianders@chromium.org>
Cc: Jaehoon Chung <jh80.chung@samsung.com>
Signed-off-by: Andreas Färber <afaerber@suse.de>
---
 v3 -> v4: Unchanged
 
 v3: New (Doug Anderson)
 Redundant with Jaehoon Chung's general slot@0 deprecation,
 in case that hits the tree earlier.

 arch/arm/boot/dts/exynos5250-snow.dts | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/arch/arm/boot/dts/exynos5250-snow.dts b/arch/arm/boot/dts/exynos5250-snow.dts
index f2b8c4116541..eb437f6afec1 100644
--- a/arch/arm/boot/dts/exynos5250-snow.dts
+++ b/arch/arm/boot/dts/exynos5250-snow.dts
@@ -240,10 +240,8 @@
 	 */
 	mmc@12230000 {
 		status = "okay";
-		slot@0 {
-			pinctrl-names = "default";
-			pinctrl-0 = <&sd3_clk &sd3_cmd &sd3_bus4>;
-		};
+		pinctrl-names = "default";
+		pinctrl-0 = <&sd3_clk &sd3_cmd &sd3_bus4>;
 	};
 
 	i2c@12CD0000 {
-- 
1.9.3

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

* [PATCH v4 1/4] ARM: dts: Fix MMC pinctrl for exynos5250-snow
@ 2014-07-31 16:08   ` Andreas Färber
  0 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 16:08 UTC (permalink / raw)
  To: linux-arm-kernel

The pinctrl properties should be on the device directly and not on the
slot sub-node.

Reported-by: Doug Anderson <dianders@chromium.org>
Cc: Jaehoon Chung <jh80.chung@samsung.com>
Signed-off-by: Andreas F?rber <afaerber@suse.de>
---
 v3 -> v4: Unchanged
 
 v3: New (Doug Anderson)
 Redundant with Jaehoon Chung's general slot at 0 deprecation,
 in case that hits the tree earlier.

 arch/arm/boot/dts/exynos5250-snow.dts | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/arch/arm/boot/dts/exynos5250-snow.dts b/arch/arm/boot/dts/exynos5250-snow.dts
index f2b8c4116541..eb437f6afec1 100644
--- a/arch/arm/boot/dts/exynos5250-snow.dts
+++ b/arch/arm/boot/dts/exynos5250-snow.dts
@@ -240,10 +240,8 @@
 	 */
 	mmc at 12230000 {
 		status = "okay";
-		slot at 0 {
-			pinctrl-names = "default";
-			pinctrl-0 = <&sd3_clk &sd3_cmd &sd3_bus4>;
-		};
+		pinctrl-names = "default";
+		pinctrl-0 = <&sd3_clk &sd3_cmd &sd3_bus4>;
 	};
 
 	i2c at 12CD0000 {
-- 
1.9.3

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

* [PATCH v4 2/4] ARM: dts: Fold exynos5250-cros-common into exynos5250-snow
  2014-07-31 16:08 ` Andreas Färber
  (?)
@ 2014-07-31 16:08   ` Andreas Färber
  -1 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 16:08 UTC (permalink / raw)
  To: linux-samsung-soc
  Cc: linux-arm-kernel, devicetree, Stephan van Schaik,
	Vincent Palatin, Doug Anderson, Javier Martinez Canillas,
	Andreas Färber, Ben Dooks, Kukjin Kim, Rob Herring,
	Pawel Moll, Mark Rutland, Ian Campbell, Kumar Gala, Russell King,
	open list

The remaining common ChromeOS pieces are fairly minor.

Suggested-by: Doug Anderson <dianders@chromium.org>
Signed-off-by: Andreas Färber <afaerber@suse.de>
---
 v3 -> v4: Unchanged
 
 v2 -> v3:
 * Renamed subject to match Kukjin's style
 * Rebased onto MMC pinctrl bug fix (Doug Anderson)
 
 v2: New (Doug Anderson)

 arch/arm/boot/dts/exynos5250-cros-common.dtsi | 164 --------------------------
 arch/arm/boot/dts/exynos5250-snow.dts         | 164 +++++++++++++++++++++++---
 2 files changed, 145 insertions(+), 183 deletions(-)
 delete mode 100644 arch/arm/boot/dts/exynos5250-cros-common.dtsi

diff --git a/arch/arm/boot/dts/exynos5250-cros-common.dtsi b/arch/arm/boot/dts/exynos5250-cros-common.dtsi
deleted file mode 100644
index e603e9c70142..000000000000
--- a/arch/arm/boot/dts/exynos5250-cros-common.dtsi
+++ /dev/null
@@ -1,164 +0,0 @@
-/*
- * Common device tree include for all Exynos 5250 boards based off of Daisy.
- *
- * Copyright (c) 2012 Google, Inc
- *
- * 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.
-*/
-
-/ {
-	aliases {
-	};
-
-	memory {
-		reg = <0x40000000 0x80000000>;
-	};
-
-	chosen {
-	};
-
-	pinctrl@11400000 {
-		/*
-		 * Disabled pullups since external part has its own pullups and
-		 * double-pulling gets us out of spec in some cases.
-		 */
-		i2c2_bus: i2c2-bus {
-			samsung,pin-pud = <0>;
-		};
-	};
-
-	i2c@12C60000 {
-		status = "okay";
-		samsung,i2c-sda-delay = <100>;
-		samsung,i2c-max-bus-freq = <378000>;
-	};
-
-	i2c@12C70000 {
-		status = "okay";
-		samsung,i2c-sda-delay = <100>;
-		samsung,i2c-max-bus-freq = <378000>;
-	};
-
-	i2c@12C80000 {
-		status = "okay";
-		samsung,i2c-sda-delay = <100>;
-		samsung,i2c-max-bus-freq = <66000>;
-
-		hdmiddc@50 {
-			compatible = "samsung,exynos4210-hdmiddc";
-			reg = <0x50>;
-		};
-	};
-
-	i2c@12C90000 {
-		status = "okay";
-		samsung,i2c-sda-delay = <100>;
-		samsung,i2c-max-bus-freq = <66000>;
-	};
-
-	i2c@12CA0000 {
-		status = "okay";
-		samsung,i2c-sda-delay = <100>;
-		samsung,i2c-max-bus-freq = <66000>;
-	};
-
-	i2c@12CB0000 {
-		status = "okay";
-		samsung,i2c-sda-delay = <100>;
-		samsung,i2c-max-bus-freq = <66000>;
-	};
-
-	i2c@12CD0000 {
-		status = "okay";
-		samsung,i2c-sda-delay = <100>;
-		samsung,i2c-max-bus-freq = <66000>;
-	};
-
-	i2c@12CE0000 {
-		status = "okay";
-		samsung,i2c-sda-delay = <100>;
-		samsung,i2c-max-bus-freq = <378000>;
-
-		hdmiphy: hdmiphy@38 {
-			compatible = "samsung,exynos4212-hdmiphy";
-			reg = <0x38>;
-		};
-	};
-
-	mmc@12200000 {
-		num-slots = <1>;
-		supports-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>;
-		pinctrl-names = "default";
-		pinctrl-0 = <&sd0_clk &sd0_cmd &sd0_cd &sd0_bus4 &sd0_bus8>;
-
-		slot@0 {
-			reg = <0>;
-			bus-width = <8>;
-		};
-	};
-
-	mmc@12220000 {
-		num-slots = <1>;
-		supports-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>;
-		pinctrl-names = "default";
-		pinctrl-0 = <&sd2_clk &sd2_cmd &sd2_cd &sd2_bus4>;
-
-		slot@0 {
-			reg = <0>;
-			bus-width = <4>;
-			wp-gpios = <&gpc2 1 0>;
-		};
-	};
-
-	mmc@12230000 {
-		num-slots = <1>;
-		supports-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>;
-		/* See board-specific dts files for pin setup */
-
-		slot@0 {
-			reg = <0>;
-			bus-width = <4>;
-		};
-	};
-
-	spi_1: spi@12d30000 {
-		status = "okay";
-		samsung,spi-src-clk = <0>;
-		num-cs = <1>;
-	};
-
-	hdmi {
-		hpd-gpio = <&gpx3 7 0>;
-		pinctrl-names = "default";
-		pinctrl-0 = <&hdmi_hpd_irq>;
-		phy = <&hdmiphy>;
-		ddc = <&i2c_2>;
-	};
-
-	gpio-keys {
-		compatible = "gpio-keys";
-
-		power {
-			label = "Power";
-			gpios = <&gpx1 3 1>;
-			linux,code = <116>; /* KEY_POWER */
-			gpio-key,wakeup;
-		};
-	};
-};
diff --git a/arch/arm/boot/dts/exynos5250-snow.dts b/arch/arm/boot/dts/exynos5250-snow.dts
index eb437f6afec1..1c36cd72905f 100644
--- a/arch/arm/boot/dts/exynos5250-snow.dts
+++ b/arch/arm/boot/dts/exynos5250-snow.dts
@@ -10,7 +10,6 @@
 
 /dts-v1/;
 #include "exynos5250.dtsi"
-#include "exynos5250-cros-common.dtsi"
 
 / {
 	model = "Google Snow";
@@ -20,6 +19,13 @@
 		i2c104 = &i2c_104;
 	};
 
+	memory {
+		reg = <0x40000000 0x80000000>;
+	};
+
+	chosen {
+	};
+
 	rtc@101E0000 {
 		status = "okay";
 	};
@@ -93,6 +99,13 @@
 	gpio-keys {
 		compatible = "gpio-keys";
 
+		power {
+			label = "Power";
+			gpios = <&gpx1 3 1>;
+			linux,code = <116>; /* KEY_POWER */
+			gpio-key,wakeup;
+		};
+
 		lid-switch {
 			label = "Lid";
 			gpios = <&gpx3 5 1>;
@@ -226,24 +239,6 @@
 		};
 	};
 
-	mmc@12200000 {
-		status = "okay";
-	};
-
-	mmc@12220000 {
-		status = "okay";
-	};
-
-	/*
-	 * On Snow we've got SIP WiFi and so can keep drive strengths low to
-	 * reduce EMI.
-	 */
-	mmc@12230000 {
-		status = "okay";
-		pinctrl-names = "default";
-		pinctrl-0 = <&sd3_clk &sd3_cmd &sd3_bus4>;
-	};
-
 	i2c@12CD0000 {
 		max98095: codec@11 {
 			compatible = "maxim,max98095";
@@ -292,6 +287,11 @@
 	};
 
 	hdmi {
+		hpd-gpio = <&gpx3 7 0>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&hdmi_hpd_irq>;
+		phy = <&hdmiphy>;
+		ddc = <&i2c_2>;
 		hdmi-en-supply = <&tps65090_fet7>;
 		vdd-supply = <&ldo8_reg>;
 		vdd_osc-supply = <&ldo10_reg>;
@@ -343,6 +343,10 @@
 };
 
 &i2c_0 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <378000>;
+
 	max77686@09 {
 		compatible = "maxim,max77686";
 		interrupt-parent = <&gpx3>;
@@ -489,6 +493,10 @@
 };
 
 &i2c_1 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <378000>;
+
 	trackpad {
 		reg = <0x67>;
 		compatible = "cypress,cyapa";
@@ -498,6 +506,118 @@
 	};
 };
 
+/*
+ * Disabled pullups since external part has its own pullups and
+ * double-pulling gets us out of spec in some cases.
+ */
+&i2c2_bus {
+	samsung,pin-pud = <0>;
+};
+
+&i2c_2 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+
+	hdmiddc@50 {
+		compatible = "samsung,exynos4210-hdmiddc";
+		reg = <0x50>;
+	};
+};
+
+&i2c_3 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+};
+
+&i2c_4 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+};
+
+&i2c_5 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+};
+
+&i2c_7 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+};
+
+&i2c_8 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <378000>;
+
+	hdmiphy: hdmiphy@38 {
+		compatible = "samsung,exynos4212-hdmiphy";
+		reg = <0x38>;
+	};
+};
+
+&mmc_0 {
+	status = "okay";
+	num-slots = <1>;
+	supports-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>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&sd0_clk &sd0_cmd &sd0_cd &sd0_bus4 &sd0_bus8>;
+
+	slot@0 {
+		reg = <0>;
+		bus-width = <8>;
+	};
+};
+
+&mmc_2 {
+	status = "okay";
+	num-slots = <1>;
+	supports-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>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&sd2_clk &sd2_cmd &sd2_cd &sd2_bus4>;
+
+	slot@0 {
+		reg = <0>;
+		bus-width = <4>;
+		wp-gpios = <&gpc2 1 0>;
+	};
+};
+
+/*
+ * On Snow we've got SIP WiFi and so can keep drive strengths low to
+ * reduce EMI.
+ */
+&mmc_3 {
+	status = "okay";
+	num-slots = <1>;
+	supports-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>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&sd3_clk &sd3_cmd &sd3_bus4>;
+
+	slot@0 {
+		reg = <0>;
+		bus-width = <4>;
+	};
+};
+
 &pinctrl_0 {
 	max77686_irq: max77686-irq {
 		samsung,pins = "gpx3-2";
@@ -507,4 +627,10 @@
 	};
 };
 
+&spi_1 {
+	status = "okay";
+	samsung,spi-src-clk = <0>;
+	num-cs = <1>;
+};
+
 #include "cros-ec-keyboard.dtsi"
-- 
1.9.3


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

* [PATCH v4 2/4] ARM: dts: Fold exynos5250-cros-common into exynos5250-snow
@ 2014-07-31 16:08   ` Andreas Färber
  0 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 16:08 UTC (permalink / raw)
  To: linux-samsung-soc
  Cc: Mark Rutland, devicetree, Kukjin Kim, Vincent Palatin,
	Pawel Moll, Ian Campbell, open list, Kumar Gala,
	Stephan van Schaik, Doug Anderson, Rob Herring, Ben Dooks,
	Andreas Färber, Russell King, Javier Martinez Canillas,
	linux-arm-kernel

The remaining common ChromeOS pieces are fairly minor.

Suggested-by: Doug Anderson <dianders@chromium.org>
Signed-off-by: Andreas Färber <afaerber@suse.de>
---
 v3 -> v4: Unchanged
 
 v2 -> v3:
 * Renamed subject to match Kukjin's style
 * Rebased onto MMC pinctrl bug fix (Doug Anderson)
 
 v2: New (Doug Anderson)

 arch/arm/boot/dts/exynos5250-cros-common.dtsi | 164 --------------------------
 arch/arm/boot/dts/exynos5250-snow.dts         | 164 +++++++++++++++++++++++---
 2 files changed, 145 insertions(+), 183 deletions(-)
 delete mode 100644 arch/arm/boot/dts/exynos5250-cros-common.dtsi

diff --git a/arch/arm/boot/dts/exynos5250-cros-common.dtsi b/arch/arm/boot/dts/exynos5250-cros-common.dtsi
deleted file mode 100644
index e603e9c70142..000000000000
--- a/arch/arm/boot/dts/exynos5250-cros-common.dtsi
+++ /dev/null
@@ -1,164 +0,0 @@
-/*
- * Common device tree include for all Exynos 5250 boards based off of Daisy.
- *
- * Copyright (c) 2012 Google, Inc
- *
- * 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.
-*/
-
-/ {
-	aliases {
-	};
-
-	memory {
-		reg = <0x40000000 0x80000000>;
-	};
-
-	chosen {
-	};
-
-	pinctrl@11400000 {
-		/*
-		 * Disabled pullups since external part has its own pullups and
-		 * double-pulling gets us out of spec in some cases.
-		 */
-		i2c2_bus: i2c2-bus {
-			samsung,pin-pud = <0>;
-		};
-	};
-
-	i2c@12C60000 {
-		status = "okay";
-		samsung,i2c-sda-delay = <100>;
-		samsung,i2c-max-bus-freq = <378000>;
-	};
-
-	i2c@12C70000 {
-		status = "okay";
-		samsung,i2c-sda-delay = <100>;
-		samsung,i2c-max-bus-freq = <378000>;
-	};
-
-	i2c@12C80000 {
-		status = "okay";
-		samsung,i2c-sda-delay = <100>;
-		samsung,i2c-max-bus-freq = <66000>;
-
-		hdmiddc@50 {
-			compatible = "samsung,exynos4210-hdmiddc";
-			reg = <0x50>;
-		};
-	};
-
-	i2c@12C90000 {
-		status = "okay";
-		samsung,i2c-sda-delay = <100>;
-		samsung,i2c-max-bus-freq = <66000>;
-	};
-
-	i2c@12CA0000 {
-		status = "okay";
-		samsung,i2c-sda-delay = <100>;
-		samsung,i2c-max-bus-freq = <66000>;
-	};
-
-	i2c@12CB0000 {
-		status = "okay";
-		samsung,i2c-sda-delay = <100>;
-		samsung,i2c-max-bus-freq = <66000>;
-	};
-
-	i2c@12CD0000 {
-		status = "okay";
-		samsung,i2c-sda-delay = <100>;
-		samsung,i2c-max-bus-freq = <66000>;
-	};
-
-	i2c@12CE0000 {
-		status = "okay";
-		samsung,i2c-sda-delay = <100>;
-		samsung,i2c-max-bus-freq = <378000>;
-
-		hdmiphy: hdmiphy@38 {
-			compatible = "samsung,exynos4212-hdmiphy";
-			reg = <0x38>;
-		};
-	};
-
-	mmc@12200000 {
-		num-slots = <1>;
-		supports-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>;
-		pinctrl-names = "default";
-		pinctrl-0 = <&sd0_clk &sd0_cmd &sd0_cd &sd0_bus4 &sd0_bus8>;
-
-		slot@0 {
-			reg = <0>;
-			bus-width = <8>;
-		};
-	};
-
-	mmc@12220000 {
-		num-slots = <1>;
-		supports-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>;
-		pinctrl-names = "default";
-		pinctrl-0 = <&sd2_clk &sd2_cmd &sd2_cd &sd2_bus4>;
-
-		slot@0 {
-			reg = <0>;
-			bus-width = <4>;
-			wp-gpios = <&gpc2 1 0>;
-		};
-	};
-
-	mmc@12230000 {
-		num-slots = <1>;
-		supports-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>;
-		/* See board-specific dts files for pin setup */
-
-		slot@0 {
-			reg = <0>;
-			bus-width = <4>;
-		};
-	};
-
-	spi_1: spi@12d30000 {
-		status = "okay";
-		samsung,spi-src-clk = <0>;
-		num-cs = <1>;
-	};
-
-	hdmi {
-		hpd-gpio = <&gpx3 7 0>;
-		pinctrl-names = "default";
-		pinctrl-0 = <&hdmi_hpd_irq>;
-		phy = <&hdmiphy>;
-		ddc = <&i2c_2>;
-	};
-
-	gpio-keys {
-		compatible = "gpio-keys";
-
-		power {
-			label = "Power";
-			gpios = <&gpx1 3 1>;
-			linux,code = <116>; /* KEY_POWER */
-			gpio-key,wakeup;
-		};
-	};
-};
diff --git a/arch/arm/boot/dts/exynos5250-snow.dts b/arch/arm/boot/dts/exynos5250-snow.dts
index eb437f6afec1..1c36cd72905f 100644
--- a/arch/arm/boot/dts/exynos5250-snow.dts
+++ b/arch/arm/boot/dts/exynos5250-snow.dts
@@ -10,7 +10,6 @@
 
 /dts-v1/;
 #include "exynos5250.dtsi"
-#include "exynos5250-cros-common.dtsi"
 
 / {
 	model = "Google Snow";
@@ -20,6 +19,13 @@
 		i2c104 = &i2c_104;
 	};
 
+	memory {
+		reg = <0x40000000 0x80000000>;
+	};
+
+	chosen {
+	};
+
 	rtc@101E0000 {
 		status = "okay";
 	};
@@ -93,6 +99,13 @@
 	gpio-keys {
 		compatible = "gpio-keys";
 
+		power {
+			label = "Power";
+			gpios = <&gpx1 3 1>;
+			linux,code = <116>; /* KEY_POWER */
+			gpio-key,wakeup;
+		};
+
 		lid-switch {
 			label = "Lid";
 			gpios = <&gpx3 5 1>;
@@ -226,24 +239,6 @@
 		};
 	};
 
-	mmc@12200000 {
-		status = "okay";
-	};
-
-	mmc@12220000 {
-		status = "okay";
-	};
-
-	/*
-	 * On Snow we've got SIP WiFi and so can keep drive strengths low to
-	 * reduce EMI.
-	 */
-	mmc@12230000 {
-		status = "okay";
-		pinctrl-names = "default";
-		pinctrl-0 = <&sd3_clk &sd3_cmd &sd3_bus4>;
-	};
-
 	i2c@12CD0000 {
 		max98095: codec@11 {
 			compatible = "maxim,max98095";
@@ -292,6 +287,11 @@
 	};
 
 	hdmi {
+		hpd-gpio = <&gpx3 7 0>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&hdmi_hpd_irq>;
+		phy = <&hdmiphy>;
+		ddc = <&i2c_2>;
 		hdmi-en-supply = <&tps65090_fet7>;
 		vdd-supply = <&ldo8_reg>;
 		vdd_osc-supply = <&ldo10_reg>;
@@ -343,6 +343,10 @@
 };
 
 &i2c_0 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <378000>;
+
 	max77686@09 {
 		compatible = "maxim,max77686";
 		interrupt-parent = <&gpx3>;
@@ -489,6 +493,10 @@
 };
 
 &i2c_1 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <378000>;
+
 	trackpad {
 		reg = <0x67>;
 		compatible = "cypress,cyapa";
@@ -498,6 +506,118 @@
 	};
 };
 
+/*
+ * Disabled pullups since external part has its own pullups and
+ * double-pulling gets us out of spec in some cases.
+ */
+&i2c2_bus {
+	samsung,pin-pud = <0>;
+};
+
+&i2c_2 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+
+	hdmiddc@50 {
+		compatible = "samsung,exynos4210-hdmiddc";
+		reg = <0x50>;
+	};
+};
+
+&i2c_3 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+};
+
+&i2c_4 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+};
+
+&i2c_5 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+};
+
+&i2c_7 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+};
+
+&i2c_8 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <378000>;
+
+	hdmiphy: hdmiphy@38 {
+		compatible = "samsung,exynos4212-hdmiphy";
+		reg = <0x38>;
+	};
+};
+
+&mmc_0 {
+	status = "okay";
+	num-slots = <1>;
+	supports-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>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&sd0_clk &sd0_cmd &sd0_cd &sd0_bus4 &sd0_bus8>;
+
+	slot@0 {
+		reg = <0>;
+		bus-width = <8>;
+	};
+};
+
+&mmc_2 {
+	status = "okay";
+	num-slots = <1>;
+	supports-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>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&sd2_clk &sd2_cmd &sd2_cd &sd2_bus4>;
+
+	slot@0 {
+		reg = <0>;
+		bus-width = <4>;
+		wp-gpios = <&gpc2 1 0>;
+	};
+};
+
+/*
+ * On Snow we've got SIP WiFi and so can keep drive strengths low to
+ * reduce EMI.
+ */
+&mmc_3 {
+	status = "okay";
+	num-slots = <1>;
+	supports-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>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&sd3_clk &sd3_cmd &sd3_bus4>;
+
+	slot@0 {
+		reg = <0>;
+		bus-width = <4>;
+	};
+};
+
 &pinctrl_0 {
 	max77686_irq: max77686-irq {
 		samsung,pins = "gpx3-2";
@@ -507,4 +627,10 @@
 	};
 };
 
+&spi_1 {
+	status = "okay";
+	samsung,spi-src-clk = <0>;
+	num-cs = <1>;
+};
+
 #include "cros-ec-keyboard.dtsi"
-- 
1.9.3


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* [PATCH v4 2/4] ARM: dts: Fold exynos5250-cros-common into exynos5250-snow
@ 2014-07-31 16:08   ` Andreas Färber
  0 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 16:08 UTC (permalink / raw)
  To: linux-arm-kernel

The remaining common ChromeOS pieces are fairly minor.

Suggested-by: Doug Anderson <dianders@chromium.org>
Signed-off-by: Andreas F?rber <afaerber@suse.de>
---
 v3 -> v4: Unchanged
 
 v2 -> v3:
 * Renamed subject to match Kukjin's style
 * Rebased onto MMC pinctrl bug fix (Doug Anderson)
 
 v2: New (Doug Anderson)

 arch/arm/boot/dts/exynos5250-cros-common.dtsi | 164 --------------------------
 arch/arm/boot/dts/exynos5250-snow.dts         | 164 +++++++++++++++++++++++---
 2 files changed, 145 insertions(+), 183 deletions(-)
 delete mode 100644 arch/arm/boot/dts/exynos5250-cros-common.dtsi

diff --git a/arch/arm/boot/dts/exynos5250-cros-common.dtsi b/arch/arm/boot/dts/exynos5250-cros-common.dtsi
deleted file mode 100644
index e603e9c70142..000000000000
--- a/arch/arm/boot/dts/exynos5250-cros-common.dtsi
+++ /dev/null
@@ -1,164 +0,0 @@
-/*
- * Common device tree include for all Exynos 5250 boards based off of Daisy.
- *
- * Copyright (c) 2012 Google, Inc
- *
- * 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.
-*/
-
-/ {
-	aliases {
-	};
-
-	memory {
-		reg = <0x40000000 0x80000000>;
-	};
-
-	chosen {
-	};
-
-	pinctrl at 11400000 {
-		/*
-		 * Disabled pullups since external part has its own pullups and
-		 * double-pulling gets us out of spec in some cases.
-		 */
-		i2c2_bus: i2c2-bus {
-			samsung,pin-pud = <0>;
-		};
-	};
-
-	i2c at 12C60000 {
-		status = "okay";
-		samsung,i2c-sda-delay = <100>;
-		samsung,i2c-max-bus-freq = <378000>;
-	};
-
-	i2c at 12C70000 {
-		status = "okay";
-		samsung,i2c-sda-delay = <100>;
-		samsung,i2c-max-bus-freq = <378000>;
-	};
-
-	i2c at 12C80000 {
-		status = "okay";
-		samsung,i2c-sda-delay = <100>;
-		samsung,i2c-max-bus-freq = <66000>;
-
-		hdmiddc at 50 {
-			compatible = "samsung,exynos4210-hdmiddc";
-			reg = <0x50>;
-		};
-	};
-
-	i2c at 12C90000 {
-		status = "okay";
-		samsung,i2c-sda-delay = <100>;
-		samsung,i2c-max-bus-freq = <66000>;
-	};
-
-	i2c at 12CA0000 {
-		status = "okay";
-		samsung,i2c-sda-delay = <100>;
-		samsung,i2c-max-bus-freq = <66000>;
-	};
-
-	i2c at 12CB0000 {
-		status = "okay";
-		samsung,i2c-sda-delay = <100>;
-		samsung,i2c-max-bus-freq = <66000>;
-	};
-
-	i2c at 12CD0000 {
-		status = "okay";
-		samsung,i2c-sda-delay = <100>;
-		samsung,i2c-max-bus-freq = <66000>;
-	};
-
-	i2c at 12CE0000 {
-		status = "okay";
-		samsung,i2c-sda-delay = <100>;
-		samsung,i2c-max-bus-freq = <378000>;
-
-		hdmiphy: hdmiphy at 38 {
-			compatible = "samsung,exynos4212-hdmiphy";
-			reg = <0x38>;
-		};
-	};
-
-	mmc at 12200000 {
-		num-slots = <1>;
-		supports-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>;
-		pinctrl-names = "default";
-		pinctrl-0 = <&sd0_clk &sd0_cmd &sd0_cd &sd0_bus4 &sd0_bus8>;
-
-		slot at 0 {
-			reg = <0>;
-			bus-width = <8>;
-		};
-	};
-
-	mmc at 12220000 {
-		num-slots = <1>;
-		supports-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>;
-		pinctrl-names = "default";
-		pinctrl-0 = <&sd2_clk &sd2_cmd &sd2_cd &sd2_bus4>;
-
-		slot at 0 {
-			reg = <0>;
-			bus-width = <4>;
-			wp-gpios = <&gpc2 1 0>;
-		};
-	};
-
-	mmc at 12230000 {
-		num-slots = <1>;
-		supports-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>;
-		/* See board-specific dts files for pin setup */
-
-		slot at 0 {
-			reg = <0>;
-			bus-width = <4>;
-		};
-	};
-
-	spi_1: spi at 12d30000 {
-		status = "okay";
-		samsung,spi-src-clk = <0>;
-		num-cs = <1>;
-	};
-
-	hdmi {
-		hpd-gpio = <&gpx3 7 0>;
-		pinctrl-names = "default";
-		pinctrl-0 = <&hdmi_hpd_irq>;
-		phy = <&hdmiphy>;
-		ddc = <&i2c_2>;
-	};
-
-	gpio-keys {
-		compatible = "gpio-keys";
-
-		power {
-			label = "Power";
-			gpios = <&gpx1 3 1>;
-			linux,code = <116>; /* KEY_POWER */
-			gpio-key,wakeup;
-		};
-	};
-};
diff --git a/arch/arm/boot/dts/exynos5250-snow.dts b/arch/arm/boot/dts/exynos5250-snow.dts
index eb437f6afec1..1c36cd72905f 100644
--- a/arch/arm/boot/dts/exynos5250-snow.dts
+++ b/arch/arm/boot/dts/exynos5250-snow.dts
@@ -10,7 +10,6 @@
 
 /dts-v1/;
 #include "exynos5250.dtsi"
-#include "exynos5250-cros-common.dtsi"
 
 / {
 	model = "Google Snow";
@@ -20,6 +19,13 @@
 		i2c104 = &i2c_104;
 	};
 
+	memory {
+		reg = <0x40000000 0x80000000>;
+	};
+
+	chosen {
+	};
+
 	rtc at 101E0000 {
 		status = "okay";
 	};
@@ -93,6 +99,13 @@
 	gpio-keys {
 		compatible = "gpio-keys";
 
+		power {
+			label = "Power";
+			gpios = <&gpx1 3 1>;
+			linux,code = <116>; /* KEY_POWER */
+			gpio-key,wakeup;
+		};
+
 		lid-switch {
 			label = "Lid";
 			gpios = <&gpx3 5 1>;
@@ -226,24 +239,6 @@
 		};
 	};
 
-	mmc at 12200000 {
-		status = "okay";
-	};
-
-	mmc at 12220000 {
-		status = "okay";
-	};
-
-	/*
-	 * On Snow we've got SIP WiFi and so can keep drive strengths low to
-	 * reduce EMI.
-	 */
-	mmc at 12230000 {
-		status = "okay";
-		pinctrl-names = "default";
-		pinctrl-0 = <&sd3_clk &sd3_cmd &sd3_bus4>;
-	};
-
 	i2c at 12CD0000 {
 		max98095: codec at 11 {
 			compatible = "maxim,max98095";
@@ -292,6 +287,11 @@
 	};
 
 	hdmi {
+		hpd-gpio = <&gpx3 7 0>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&hdmi_hpd_irq>;
+		phy = <&hdmiphy>;
+		ddc = <&i2c_2>;
 		hdmi-en-supply = <&tps65090_fet7>;
 		vdd-supply = <&ldo8_reg>;
 		vdd_osc-supply = <&ldo10_reg>;
@@ -343,6 +343,10 @@
 };
 
 &i2c_0 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <378000>;
+
 	max77686 at 09 {
 		compatible = "maxim,max77686";
 		interrupt-parent = <&gpx3>;
@@ -489,6 +493,10 @@
 };
 
 &i2c_1 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <378000>;
+
 	trackpad {
 		reg = <0x67>;
 		compatible = "cypress,cyapa";
@@ -498,6 +506,118 @@
 	};
 };
 
+/*
+ * Disabled pullups since external part has its own pullups and
+ * double-pulling gets us out of spec in some cases.
+ */
+&i2c2_bus {
+	samsung,pin-pud = <0>;
+};
+
+&i2c_2 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+
+	hdmiddc at 50 {
+		compatible = "samsung,exynos4210-hdmiddc";
+		reg = <0x50>;
+	};
+};
+
+&i2c_3 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+};
+
+&i2c_4 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+};
+
+&i2c_5 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+};
+
+&i2c_7 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+};
+
+&i2c_8 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <378000>;
+
+	hdmiphy: hdmiphy at 38 {
+		compatible = "samsung,exynos4212-hdmiphy";
+		reg = <0x38>;
+	};
+};
+
+&mmc_0 {
+	status = "okay";
+	num-slots = <1>;
+	supports-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>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&sd0_clk &sd0_cmd &sd0_cd &sd0_bus4 &sd0_bus8>;
+
+	slot at 0 {
+		reg = <0>;
+		bus-width = <8>;
+	};
+};
+
+&mmc_2 {
+	status = "okay";
+	num-slots = <1>;
+	supports-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>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&sd2_clk &sd2_cmd &sd2_cd &sd2_bus4>;
+
+	slot at 0 {
+		reg = <0>;
+		bus-width = <4>;
+		wp-gpios = <&gpc2 1 0>;
+	};
+};
+
+/*
+ * On Snow we've got SIP WiFi and so can keep drive strengths low to
+ * reduce EMI.
+ */
+&mmc_3 {
+	status = "okay";
+	num-slots = <1>;
+	supports-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>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&sd3_clk &sd3_cmd &sd3_bus4>;
+
+	slot at 0 {
+		reg = <0>;
+		bus-width = <4>;
+	};
+};
+
 &pinctrl_0 {
 	max77686_irq: max77686-irq {
 		samsung,pins = "gpx3-2";
@@ -507,4 +627,10 @@
 	};
 };
 
+&spi_1 {
+	status = "okay";
+	samsung,spi-src-clk = <0>;
+	num-cs = <1>;
+};
+
 #include "cros-ec-keyboard.dtsi"
-- 
1.9.3

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

* [PATCH v4 3/4] ARM: dts: Clean up exynos5250-snow
  2014-07-31 16:08 ` Andreas Färber
  (?)
@ 2014-07-31 16:08   ` Andreas Färber
  -1 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 16:08 UTC (permalink / raw)
  To: linux-samsung-soc
  Cc: linux-arm-kernel, devicetree, Stephan van Schaik,
	Vincent Palatin, Doug Anderson, Javier Martinez Canillas,
	Andreas Färber, Ben Dooks, Kukjin Kim, Rob Herring,
	Pawel Moll, Mark Rutland, Ian Campbell, Kumar Gala, Russell King,
	open list

Use the new style of referencing inherited nodes and use symbolic names.

Suggested-by: Doug Anderson <dianders@chromium.org>
Signed-off-by: Andreas Färber <afaerber@suse.de>
---
 v3 -> v4: Unchanged
 
 v3: New (Doug Anderson)

 arch/arm/boot/dts/exynos5250-snow.dts | 182 +++++++++++++++++-----------------
 1 file changed, 90 insertions(+), 92 deletions(-)

diff --git a/arch/arm/boot/dts/exynos5250-snow.dts b/arch/arm/boot/dts/exynos5250-snow.dts
index 1c36cd72905f..2ed6cb04a2db 100644
--- a/arch/arm/boot/dts/exynos5250-snow.dts
+++ b/arch/arm/boot/dts/exynos5250-snow.dts
@@ -9,6 +9,8 @@
 */
 
 /dts-v1/;
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
 #include "exynos5250.dtsi"
 
 / {
@@ -30,85 +32,19 @@
 		status = "okay";
 	};
 
-	pinctrl@11400000 {
-		ec_irq: ec-irq {
-			samsung,pins = "gpx1-6";
-			samsung,pin-function = <0>;
-			samsung,pin-pud = <0>;
-			samsung,pin-drv = <0>;
-		};
-
-		sd3_clk: sd3-clk {
-			samsung,pin-drv = <0>;
-		};
-
-		sd3_cmd: sd3-cmd {
-			samsung,pin-pud = <3>;
-			samsung,pin-drv = <0>;
-		};
-
-		sd3_bus4: sd3-bus-width4 {
-			samsung,pin-drv = <0>;
-		};
-
-		max98095_en: max98095-en {
-			samsung,pins = "gpx1-7";
-			samsung,pin-function = <0>;
-			samsung,pin-pud = <3>;
-			samsung,pin-drv = <0>;
-		};
-
-		tps65090_irq: tps65090-irq {
-			samsung,pins = "gpx2-6";
-			samsung,pin-function = <0>;
-			samsung,pin-pud = <0>;
-			samsung,pin-drv = <0>;
-		};
-
-		usb3_vbus_en: usb3-vbus-en {
-			samsung,pins = "gpx2-7";
-			samsung,pin-function = <1>;
-			samsung,pin-pud = <0>;
-			samsung,pin-drv = <0>;
-		};
-
-		hdmi_hpd_irq: hdmi-hpd-irq {
-			samsung,pins = "gpx3-7";
-			samsung,pin-function = <0>;
-			samsung,pin-pud = <1>;
-			samsung,pin-drv = <0>;
-		};
-	};
-
-	pinctrl@13400000 {
-		arb_their_claim: arb-their-claim {
-			samsung,pins = "gpe0-4";
-			samsung,pin-function = <0>;
-			samsung,pin-pud = <3>;
-			samsung,pin-drv = <0>;
-		};
-
-		arb_our_claim: arb-our-claim {
-			samsung,pins = "gpf0-3";
-			samsung,pin-function = <1>;
-			samsung,pin-pud = <0>;
-			samsung,pin-drv = <0>;
-		};
-	};
-
 	gpio-keys {
 		compatible = "gpio-keys";
 
 		power {
 			label = "Power";
-			gpios = <&gpx1 3 1>;
-			linux,code = <116>; /* KEY_POWER */
+			gpios = <&gpx1 3 GPIO_ACTIVE_LOW>;
+			linux,code = <KEY_POWER>;
 			gpio-key,wakeup;
 		};
 
 		lid-switch {
 			label = "Lid";
-			gpios = <&gpx3 5 1>;
+			gpios = <&gpx3 5 GPIO_ACTIVE_LOW>;
 			linux,input-type = <5>; /* EV_SW */
 			linux,code = <0>; /* SW_LID */
 			debounce-interval = <1>;
@@ -129,8 +65,8 @@
 
 		i2c-parent = <&{/i2c@12CA0000}>;
 
-		our-claim-gpio = <&gpf0 3 1>;
-		their-claim-gpios = <&gpe0 4 1>;
+		our-claim-gpio = <&gpf0 3 GPIO_ACTIVE_LOW>;
+		their-claim-gpios = <&gpe0 4 GPIO_ACTIVE_LOW>;
 		slew-delay-us = <10>;
 		wait-retry-us = <3000>;
 		wait-free-us = <50000>;
@@ -239,19 +175,6 @@
 		};
 	};
 
-	i2c@12CD0000 {
-		max98095: codec@11 {
-			compatible = "maxim,max98095";
-			reg = <0x11>;
-			pinctrl-0 = <&max98095_en>;
-			pinctrl-names = "default";
-		};
-	};
-
-	i2s0: i2s@03830000 {
-		status = "okay";
-	};
-
 	sound {
 		compatible = "google,snow-audio-max98095";
 
@@ -265,18 +188,14 @@
 		regulator-name = "P5.0V_USB3CON";
 		regulator-min-microvolt = <5000000>;
 		regulator-max-microvolt = <5000000>;
-		gpio = <&gpx2 7 0>;
+		gpio = <&gpx2 7 GPIO_ACTIVE_HIGH>;
 		pinctrl-names = "default";
 		pinctrl-0 = <&usb3_vbus_en>;
 		enable-active-high;
 	};
 
-	phy@12100000 {
-		vbus-supply = <&usb3_vbus_reg>;
-	};
-
 	usb@12110000 {
-		samsung,vbus-gpio = <&gpx1 1 0>;
+		samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
 	};
 
 	fixed-rate-clocks {
@@ -287,7 +206,7 @@
 	};
 
 	hdmi {
-		hpd-gpio = <&gpx3 7 0>;
+		hpd-gpio = <&gpx3 7 GPIO_ACTIVE_HIGH>;
 		pinctrl-names = "default";
 		pinctrl-0 = <&hdmi_hpd_irq>;
 		phy = <&hdmiphy>;
@@ -322,7 +241,7 @@
 		samsung,color-depth = <1>;
 		samsung,link-rate = <0x0a>;
 		samsung,lane-count = <2>;
-		samsung,hpd-gpio = <&gpx0 7 0>;
+		samsung,hpd-gpio = <&gpx0 7 GPIO_ACTIVE_HIGH>;
 
 		display-timings {
 			native-mode = <&timing1>;
@@ -547,6 +466,13 @@
 	status = "okay";
 	samsung,i2c-sda-delay = <100>;
 	samsung,i2c-max-bus-freq = <66000>;
+
+	max98095: codec@11 {
+		compatible = "maxim,max98095";
+		reg = <0x11>;
+		pinctrl-0 = <&max98095_en>;
+		pinctrl-names = "default";
+	};
 };
 
 &i2c_8 {
@@ -560,6 +486,10 @@
 	};
 };
 
+&i2s0 {
+	status = "okay";
+};
+
 &mmc_0 {
 	status = "okay";
 	num-slots = <1>;
@@ -625,6 +555,70 @@
 		samsung,pin-pud = <0>;
 		samsung,pin-drv = <0>;
 	};
+
+	ec_irq: ec-irq {
+		samsung,pins = "gpx1-6";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	max98095_en: max98095-en {
+		samsung,pins = "gpx1-7";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <3>;
+		samsung,pin-drv = <0>;
+	};
+
+	tps65090_irq: tps65090-irq {
+		samsung,pins = "gpx2-6";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	usb3_vbus_en: usb3-vbus-en {
+		samsung,pins = "gpx2-7";
+		samsung,pin-function = <1>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	hdmi_hpd_irq: hdmi-hpd-irq {
+		samsung,pins = "gpx3-7";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <1>;
+		samsung,pin-drv = <0>;
+	};
+};
+
+&pinctrl_1 {
+	arb_their_claim: arb-their-claim {
+		samsung,pins = "gpe0-4";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <3>;
+		samsung,pin-drv = <0>;
+	};
+
+	arb_our_claim: arb-our-claim {
+		samsung,pins = "gpf0-3";
+		samsung,pin-function = <1>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+};
+
+&sd3_clk {
+	samsung,pin-drv = <0>;
+};
+
+&sd3_cmd {
+	samsung,pin-pud = <3>;
+	samsung,pin-drv = <0>;
+};
+
+&sd3_bus4 {
+	samsung,pin-drv = <0>;
 };
 
 &spi_1 {
@@ -633,4 +627,8 @@
 	num-cs = <1>;
 };
 
+&usbdrd_phy {
+	vbus-supply = <&usb3_vbus_reg>;
+};
+
 #include "cros-ec-keyboard.dtsi"
-- 
1.9.3


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

* [PATCH v4 3/4] ARM: dts: Clean up exynos5250-snow
@ 2014-07-31 16:08   ` Andreas Färber
  0 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 16:08 UTC (permalink / raw)
  To: linux-samsung-soc
  Cc: Mark Rutland, devicetree, Kukjin Kim, Vincent Palatin,
	Pawel Moll, Ian Campbell, open list, Kumar Gala,
	Stephan van Schaik, Doug Anderson, Rob Herring, Ben Dooks,
	Andreas Färber, Russell King, Javier Martinez Canillas,
	linux-arm-kernel

Use the new style of referencing inherited nodes and use symbolic names.

Suggested-by: Doug Anderson <dianders@chromium.org>
Signed-off-by: Andreas Färber <afaerber@suse.de>
---
 v3 -> v4: Unchanged
 
 v3: New (Doug Anderson)

 arch/arm/boot/dts/exynos5250-snow.dts | 182 +++++++++++++++++-----------------
 1 file changed, 90 insertions(+), 92 deletions(-)

diff --git a/arch/arm/boot/dts/exynos5250-snow.dts b/arch/arm/boot/dts/exynos5250-snow.dts
index 1c36cd72905f..2ed6cb04a2db 100644
--- a/arch/arm/boot/dts/exynos5250-snow.dts
+++ b/arch/arm/boot/dts/exynos5250-snow.dts
@@ -9,6 +9,8 @@
 */
 
 /dts-v1/;
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
 #include "exynos5250.dtsi"
 
 / {
@@ -30,85 +32,19 @@
 		status = "okay";
 	};
 
-	pinctrl@11400000 {
-		ec_irq: ec-irq {
-			samsung,pins = "gpx1-6";
-			samsung,pin-function = <0>;
-			samsung,pin-pud = <0>;
-			samsung,pin-drv = <0>;
-		};
-
-		sd3_clk: sd3-clk {
-			samsung,pin-drv = <0>;
-		};
-
-		sd3_cmd: sd3-cmd {
-			samsung,pin-pud = <3>;
-			samsung,pin-drv = <0>;
-		};
-
-		sd3_bus4: sd3-bus-width4 {
-			samsung,pin-drv = <0>;
-		};
-
-		max98095_en: max98095-en {
-			samsung,pins = "gpx1-7";
-			samsung,pin-function = <0>;
-			samsung,pin-pud = <3>;
-			samsung,pin-drv = <0>;
-		};
-
-		tps65090_irq: tps65090-irq {
-			samsung,pins = "gpx2-6";
-			samsung,pin-function = <0>;
-			samsung,pin-pud = <0>;
-			samsung,pin-drv = <0>;
-		};
-
-		usb3_vbus_en: usb3-vbus-en {
-			samsung,pins = "gpx2-7";
-			samsung,pin-function = <1>;
-			samsung,pin-pud = <0>;
-			samsung,pin-drv = <0>;
-		};
-
-		hdmi_hpd_irq: hdmi-hpd-irq {
-			samsung,pins = "gpx3-7";
-			samsung,pin-function = <0>;
-			samsung,pin-pud = <1>;
-			samsung,pin-drv = <0>;
-		};
-	};
-
-	pinctrl@13400000 {
-		arb_their_claim: arb-their-claim {
-			samsung,pins = "gpe0-4";
-			samsung,pin-function = <0>;
-			samsung,pin-pud = <3>;
-			samsung,pin-drv = <0>;
-		};
-
-		arb_our_claim: arb-our-claim {
-			samsung,pins = "gpf0-3";
-			samsung,pin-function = <1>;
-			samsung,pin-pud = <0>;
-			samsung,pin-drv = <0>;
-		};
-	};
-
 	gpio-keys {
 		compatible = "gpio-keys";
 
 		power {
 			label = "Power";
-			gpios = <&gpx1 3 1>;
-			linux,code = <116>; /* KEY_POWER */
+			gpios = <&gpx1 3 GPIO_ACTIVE_LOW>;
+			linux,code = <KEY_POWER>;
 			gpio-key,wakeup;
 		};
 
 		lid-switch {
 			label = "Lid";
-			gpios = <&gpx3 5 1>;
+			gpios = <&gpx3 5 GPIO_ACTIVE_LOW>;
 			linux,input-type = <5>; /* EV_SW */
 			linux,code = <0>; /* SW_LID */
 			debounce-interval = <1>;
@@ -129,8 +65,8 @@
 
 		i2c-parent = <&{/i2c@12CA0000}>;
 
-		our-claim-gpio = <&gpf0 3 1>;
-		their-claim-gpios = <&gpe0 4 1>;
+		our-claim-gpio = <&gpf0 3 GPIO_ACTIVE_LOW>;
+		their-claim-gpios = <&gpe0 4 GPIO_ACTIVE_LOW>;
 		slew-delay-us = <10>;
 		wait-retry-us = <3000>;
 		wait-free-us = <50000>;
@@ -239,19 +175,6 @@
 		};
 	};
 
-	i2c@12CD0000 {
-		max98095: codec@11 {
-			compatible = "maxim,max98095";
-			reg = <0x11>;
-			pinctrl-0 = <&max98095_en>;
-			pinctrl-names = "default";
-		};
-	};
-
-	i2s0: i2s@03830000 {
-		status = "okay";
-	};
-
 	sound {
 		compatible = "google,snow-audio-max98095";
 
@@ -265,18 +188,14 @@
 		regulator-name = "P5.0V_USB3CON";
 		regulator-min-microvolt = <5000000>;
 		regulator-max-microvolt = <5000000>;
-		gpio = <&gpx2 7 0>;
+		gpio = <&gpx2 7 GPIO_ACTIVE_HIGH>;
 		pinctrl-names = "default";
 		pinctrl-0 = <&usb3_vbus_en>;
 		enable-active-high;
 	};
 
-	phy@12100000 {
-		vbus-supply = <&usb3_vbus_reg>;
-	};
-
 	usb@12110000 {
-		samsung,vbus-gpio = <&gpx1 1 0>;
+		samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
 	};
 
 	fixed-rate-clocks {
@@ -287,7 +206,7 @@
 	};
 
 	hdmi {
-		hpd-gpio = <&gpx3 7 0>;
+		hpd-gpio = <&gpx3 7 GPIO_ACTIVE_HIGH>;
 		pinctrl-names = "default";
 		pinctrl-0 = <&hdmi_hpd_irq>;
 		phy = <&hdmiphy>;
@@ -322,7 +241,7 @@
 		samsung,color-depth = <1>;
 		samsung,link-rate = <0x0a>;
 		samsung,lane-count = <2>;
-		samsung,hpd-gpio = <&gpx0 7 0>;
+		samsung,hpd-gpio = <&gpx0 7 GPIO_ACTIVE_HIGH>;
 
 		display-timings {
 			native-mode = <&timing1>;
@@ -547,6 +466,13 @@
 	status = "okay";
 	samsung,i2c-sda-delay = <100>;
 	samsung,i2c-max-bus-freq = <66000>;
+
+	max98095: codec@11 {
+		compatible = "maxim,max98095";
+		reg = <0x11>;
+		pinctrl-0 = <&max98095_en>;
+		pinctrl-names = "default";
+	};
 };
 
 &i2c_8 {
@@ -560,6 +486,10 @@
 	};
 };
 
+&i2s0 {
+	status = "okay";
+};
+
 &mmc_0 {
 	status = "okay";
 	num-slots = <1>;
@@ -625,6 +555,70 @@
 		samsung,pin-pud = <0>;
 		samsung,pin-drv = <0>;
 	};
+
+	ec_irq: ec-irq {
+		samsung,pins = "gpx1-6";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	max98095_en: max98095-en {
+		samsung,pins = "gpx1-7";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <3>;
+		samsung,pin-drv = <0>;
+	};
+
+	tps65090_irq: tps65090-irq {
+		samsung,pins = "gpx2-6";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	usb3_vbus_en: usb3-vbus-en {
+		samsung,pins = "gpx2-7";
+		samsung,pin-function = <1>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	hdmi_hpd_irq: hdmi-hpd-irq {
+		samsung,pins = "gpx3-7";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <1>;
+		samsung,pin-drv = <0>;
+	};
+};
+
+&pinctrl_1 {
+	arb_their_claim: arb-their-claim {
+		samsung,pins = "gpe0-4";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <3>;
+		samsung,pin-drv = <0>;
+	};
+
+	arb_our_claim: arb-our-claim {
+		samsung,pins = "gpf0-3";
+		samsung,pin-function = <1>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+};
+
+&sd3_clk {
+	samsung,pin-drv = <0>;
+};
+
+&sd3_cmd {
+	samsung,pin-pud = <3>;
+	samsung,pin-drv = <0>;
+};
+
+&sd3_bus4 {
+	samsung,pin-drv = <0>;
 };
 
 &spi_1 {
@@ -633,4 +627,8 @@
 	num-cs = <1>;
 };
 
+&usbdrd_phy {
+	vbus-supply = <&usb3_vbus_reg>;
+};
+
 #include "cros-ec-keyboard.dtsi"
-- 
1.9.3


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* [PATCH v4 3/4] ARM: dts: Clean up exynos5250-snow
@ 2014-07-31 16:08   ` Andreas Färber
  0 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 16:08 UTC (permalink / raw)
  To: linux-arm-kernel

Use the new style of referencing inherited nodes and use symbolic names.

Suggested-by: Doug Anderson <dianders@chromium.org>
Signed-off-by: Andreas F?rber <afaerber@suse.de>
---
 v3 -> v4: Unchanged
 
 v3: New (Doug Anderson)

 arch/arm/boot/dts/exynos5250-snow.dts | 182 +++++++++++++++++-----------------
 1 file changed, 90 insertions(+), 92 deletions(-)

diff --git a/arch/arm/boot/dts/exynos5250-snow.dts b/arch/arm/boot/dts/exynos5250-snow.dts
index 1c36cd72905f..2ed6cb04a2db 100644
--- a/arch/arm/boot/dts/exynos5250-snow.dts
+++ b/arch/arm/boot/dts/exynos5250-snow.dts
@@ -9,6 +9,8 @@
 */
 
 /dts-v1/;
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
 #include "exynos5250.dtsi"
 
 / {
@@ -30,85 +32,19 @@
 		status = "okay";
 	};
 
-	pinctrl at 11400000 {
-		ec_irq: ec-irq {
-			samsung,pins = "gpx1-6";
-			samsung,pin-function = <0>;
-			samsung,pin-pud = <0>;
-			samsung,pin-drv = <0>;
-		};
-
-		sd3_clk: sd3-clk {
-			samsung,pin-drv = <0>;
-		};
-
-		sd3_cmd: sd3-cmd {
-			samsung,pin-pud = <3>;
-			samsung,pin-drv = <0>;
-		};
-
-		sd3_bus4: sd3-bus-width4 {
-			samsung,pin-drv = <0>;
-		};
-
-		max98095_en: max98095-en {
-			samsung,pins = "gpx1-7";
-			samsung,pin-function = <0>;
-			samsung,pin-pud = <3>;
-			samsung,pin-drv = <0>;
-		};
-
-		tps65090_irq: tps65090-irq {
-			samsung,pins = "gpx2-6";
-			samsung,pin-function = <0>;
-			samsung,pin-pud = <0>;
-			samsung,pin-drv = <0>;
-		};
-
-		usb3_vbus_en: usb3-vbus-en {
-			samsung,pins = "gpx2-7";
-			samsung,pin-function = <1>;
-			samsung,pin-pud = <0>;
-			samsung,pin-drv = <0>;
-		};
-
-		hdmi_hpd_irq: hdmi-hpd-irq {
-			samsung,pins = "gpx3-7";
-			samsung,pin-function = <0>;
-			samsung,pin-pud = <1>;
-			samsung,pin-drv = <0>;
-		};
-	};
-
-	pinctrl at 13400000 {
-		arb_their_claim: arb-their-claim {
-			samsung,pins = "gpe0-4";
-			samsung,pin-function = <0>;
-			samsung,pin-pud = <3>;
-			samsung,pin-drv = <0>;
-		};
-
-		arb_our_claim: arb-our-claim {
-			samsung,pins = "gpf0-3";
-			samsung,pin-function = <1>;
-			samsung,pin-pud = <0>;
-			samsung,pin-drv = <0>;
-		};
-	};
-
 	gpio-keys {
 		compatible = "gpio-keys";
 
 		power {
 			label = "Power";
-			gpios = <&gpx1 3 1>;
-			linux,code = <116>; /* KEY_POWER */
+			gpios = <&gpx1 3 GPIO_ACTIVE_LOW>;
+			linux,code = <KEY_POWER>;
 			gpio-key,wakeup;
 		};
 
 		lid-switch {
 			label = "Lid";
-			gpios = <&gpx3 5 1>;
+			gpios = <&gpx3 5 GPIO_ACTIVE_LOW>;
 			linux,input-type = <5>; /* EV_SW */
 			linux,code = <0>; /* SW_LID */
 			debounce-interval = <1>;
@@ -129,8 +65,8 @@
 
 		i2c-parent = <&{/i2c@12CA0000}>;
 
-		our-claim-gpio = <&gpf0 3 1>;
-		their-claim-gpios = <&gpe0 4 1>;
+		our-claim-gpio = <&gpf0 3 GPIO_ACTIVE_LOW>;
+		their-claim-gpios = <&gpe0 4 GPIO_ACTIVE_LOW>;
 		slew-delay-us = <10>;
 		wait-retry-us = <3000>;
 		wait-free-us = <50000>;
@@ -239,19 +175,6 @@
 		};
 	};
 
-	i2c at 12CD0000 {
-		max98095: codec at 11 {
-			compatible = "maxim,max98095";
-			reg = <0x11>;
-			pinctrl-0 = <&max98095_en>;
-			pinctrl-names = "default";
-		};
-	};
-
-	i2s0: i2s at 03830000 {
-		status = "okay";
-	};
-
 	sound {
 		compatible = "google,snow-audio-max98095";
 
@@ -265,18 +188,14 @@
 		regulator-name = "P5.0V_USB3CON";
 		regulator-min-microvolt = <5000000>;
 		regulator-max-microvolt = <5000000>;
-		gpio = <&gpx2 7 0>;
+		gpio = <&gpx2 7 GPIO_ACTIVE_HIGH>;
 		pinctrl-names = "default";
 		pinctrl-0 = <&usb3_vbus_en>;
 		enable-active-high;
 	};
 
-	phy at 12100000 {
-		vbus-supply = <&usb3_vbus_reg>;
-	};
-
 	usb at 12110000 {
-		samsung,vbus-gpio = <&gpx1 1 0>;
+		samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
 	};
 
 	fixed-rate-clocks {
@@ -287,7 +206,7 @@
 	};
 
 	hdmi {
-		hpd-gpio = <&gpx3 7 0>;
+		hpd-gpio = <&gpx3 7 GPIO_ACTIVE_HIGH>;
 		pinctrl-names = "default";
 		pinctrl-0 = <&hdmi_hpd_irq>;
 		phy = <&hdmiphy>;
@@ -322,7 +241,7 @@
 		samsung,color-depth = <1>;
 		samsung,link-rate = <0x0a>;
 		samsung,lane-count = <2>;
-		samsung,hpd-gpio = <&gpx0 7 0>;
+		samsung,hpd-gpio = <&gpx0 7 GPIO_ACTIVE_HIGH>;
 
 		display-timings {
 			native-mode = <&timing1>;
@@ -547,6 +466,13 @@
 	status = "okay";
 	samsung,i2c-sda-delay = <100>;
 	samsung,i2c-max-bus-freq = <66000>;
+
+	max98095: codec at 11 {
+		compatible = "maxim,max98095";
+		reg = <0x11>;
+		pinctrl-0 = <&max98095_en>;
+		pinctrl-names = "default";
+	};
 };
 
 &i2c_8 {
@@ -560,6 +486,10 @@
 	};
 };
 
+&i2s0 {
+	status = "okay";
+};
+
 &mmc_0 {
 	status = "okay";
 	num-slots = <1>;
@@ -625,6 +555,70 @@
 		samsung,pin-pud = <0>;
 		samsung,pin-drv = <0>;
 	};
+
+	ec_irq: ec-irq {
+		samsung,pins = "gpx1-6";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	max98095_en: max98095-en {
+		samsung,pins = "gpx1-7";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <3>;
+		samsung,pin-drv = <0>;
+	};
+
+	tps65090_irq: tps65090-irq {
+		samsung,pins = "gpx2-6";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	usb3_vbus_en: usb3-vbus-en {
+		samsung,pins = "gpx2-7";
+		samsung,pin-function = <1>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	hdmi_hpd_irq: hdmi-hpd-irq {
+		samsung,pins = "gpx3-7";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <1>;
+		samsung,pin-drv = <0>;
+	};
+};
+
+&pinctrl_1 {
+	arb_their_claim: arb-their-claim {
+		samsung,pins = "gpe0-4";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <3>;
+		samsung,pin-drv = <0>;
+	};
+
+	arb_our_claim: arb-our-claim {
+		samsung,pins = "gpf0-3";
+		samsung,pin-function = <1>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+};
+
+&sd3_clk {
+	samsung,pin-drv = <0>;
+};
+
+&sd3_cmd {
+	samsung,pin-pud = <3>;
+	samsung,pin-drv = <0>;
+};
+
+&sd3_bus4 {
+	samsung,pin-drv = <0>;
 };
 
 &spi_1 {
@@ -633,4 +627,8 @@
 	num-cs = <1>;
 };
 
+&usbdrd_phy {
+	vbus-supply = <&usb3_vbus_reg>;
+};
+
 #include "cros-ec-keyboard.dtsi"
-- 
1.9.3

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

* [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
  2014-07-31 16:08 ` Andreas Färber
  (?)
@ 2014-07-31 16:08   ` Andreas Färber
  -1 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 16:08 UTC (permalink / raw)
  To: linux-samsung-soc
  Cc: linux-arm-kernel, devicetree, Stephan van Schaik,
	Vincent Palatin, Doug Anderson, Javier Martinez Canillas,
	Andreas Färber, Rob Herring, Pawel Moll, Mark Rutland,
	Ian Campbell, Kumar Gala, Russell King, Ben Dooks, Kukjin Kim,
	open list

Adds initial support for the HP Chromebook 11.

Cc: Vincent Palatin <vpalatin@chromium.org>
Cc: Doug Anderson <dianders@chromium.org>
Cc: Stephan van Schaik <stephan@synkhronix.com>
Signed-off-by: Andreas Färber <afaerber@suse.de>
---
 v3 -> v4:
 * Fixed samsung,pin-function 1 -> 0 for dp-hpd-gpio
 * Replaced dp-hpd-gpio with existing dp_hpd, overriding it
 
 v2 -> v3:
 * Use GPIO_ACTIVE_{LOW,HIGH} (Doug Anderson)
 * Use symbolic KEY_POWER instead of comment
 * Moved hsic_reset to new USB3503 node's reset-gpios (Vincent Palatin)
 * Use dp_hpd_gpio for dp-controller (Doug Anderson, Ajay Kumar)
 * Override sd1_{clk,cmd,cd,bus4} pinctrl similar to Snow (Doug Anderson)
 * Added ec_irq pinctrl for cros_ec (Doug Anderson)
 * Reordered nodes to minimize diff against Snow (Doug Anderson)
 * Dropped obsolete mmc_2 override (Doug Anderson)
 * Added lid-switch node (Doug Anderson)
 * Added gpio-keys pinctrl (Doug Anderson)
 * Added bootargs to avoid empty /chosen node and to document console setting
 * Renamed s5m8767_pmic node to avoid underscore
 * Use new style for overriding inherited pinctrl nodes, too
 * Enable i2s0 node
 
 v1 -> v2:
 * Use label-based overriding/extension of nodes. (Doug Anderson)
 * Dropped tps65090 for now, until we know where to place it.
 * Dropped non-Spring nodes from -cros-common.dtsi rather than disabling them.
 * Enabled a missing MMC node for access to internal storage.
 * Dropped display-timings from dp-controller node. (Ajay Kumar)

 arch/arm/boot/dts/Makefile              |   1 +
 arch/arm/boot/dts/exynos5250-spring.dts | 539 ++++++++++++++++++++++++++++++++
 2 files changed, 540 insertions(+)
 create mode 100644 arch/arm/boot/dts/exynos5250-spring.dts

diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
index 80a781f76e88..dec4c292f63d 100644
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
@@ -76,6 +76,7 @@ dtb-$(CONFIG_ARCH_EXYNOS) += exynos4210-origen.dtb \
 	exynos5250-arndale.dtb \
 	exynos5250-smdk5250.dtb \
 	exynos5250-snow.dtb \
+	exynos5250-spring.dtb \
 	exynos5260-xyref5260.dtb \
 	exynos5410-smdk5410.dtb \
 	exynos5420-arndale-octa.dtb \
diff --git a/arch/arm/boot/dts/exynos5250-spring.dts b/arch/arm/boot/dts/exynos5250-spring.dts
new file mode 100644
index 000000000000..1fdfa04182fc
--- /dev/null
+++ b/arch/arm/boot/dts/exynos5250-spring.dts
@@ -0,0 +1,539 @@
+/*
+ * Google Spring board device tree source
+ *
+ * Copyright (c) 2013 Google, Inc
+ * Copyright (c) 2014 SUSE LINUX Products GmbH
+ *
+ * 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 <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+#include "exynos5250.dtsi"
+
+/ {
+	model = "Google Spring";
+	compatible = "google,spring", "samsung,exynos5250", "samsung,exynos5";
+
+	memory {
+		reg = <0x40000000 0x80000000>;
+	};
+
+	chosen {
+		bootargs = "console=tty1";
+	};
+
+	gpio-keys {
+		compatible = "gpio-keys";
+		pinctrl-names = "default";
+		pinctrl-0 = <&power_key_irq>, <&lid_irq>;
+
+		power {
+			label = "Power";
+			gpios = <&gpx1 3 GPIO_ACTIVE_LOW>;
+			linux,code = <KEY_POWER>;
+			gpio-key,wakeup;
+		};
+
+		lid-switch {
+			label = "Lid";
+			gpios = <&gpx3 5 GPIO_ACTIVE_LOW>;
+			linux,input-type = <5>; /* EV_SW */
+			linux,code = <0>; /* SW_LID */
+			debounce-interval = <1>;
+			gpio-key,wakeup;
+		};
+	};
+
+	usb3_vbus_reg: regulator-usb3 {
+		compatible = "regulator-fixed";
+		regulator-name = "P5.0V_USB3CON";
+		regulator-min-microvolt = <5000000>;
+		regulator-max-microvolt = <5000000>;
+		gpio = <&gpe1 0 GPIO_ACTIVE_LOW>;
+		enable-active-high;
+	};
+
+	usb@12110000 {
+		samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
+	};
+
+	usb-hub {
+		compatible = "smsc,usb3503a";
+		reset-gpios = <&hsic_reset>;
+	};
+
+	fixed-rate-clocks {
+		xxti {
+			compatible = "samsung,clock-xxti";
+			clock-frequency = <24000000>;
+		};
+	};
+
+	hdmi {
+		hpd-gpio = <&gpx3 7 GPIO_ACTIVE_HIGH>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&hdmi_hpd_irq>;
+		phy = <&hdmiphy>;
+		ddc = <&i2c_2>;
+		hdmi-en-supply = <&s5m_ldo8_reg>;
+		vdd-supply = <&s5m_ldo8_reg>;
+		vdd_osc-supply = <&s5m_ldo10_reg>;
+		vdd_pll-supply = <&s5m_ldo8_reg>;
+	};
+
+	fimd@14400000 {
+		status = "okay";
+		samsung,invert-vclk;
+	};
+
+	dp-controller@145B0000 {
+		status = "okay";
+		pinctrl-names = "default";
+		pinctrl-0 = <&dp_hpd>;
+		samsung,color-space = <0>;
+		samsung,dynamic-range = <0>;
+		samsung,ycbcr-coeff = <0>;
+		samsung,color-depth = <1>;
+		samsung,link-rate = <0x0a>;
+		samsung,lane-count = <1>;
+		samsung,hpd-gpio = <&gpc3 0 GPIO_ACTIVE_HIGH>;
+	};
+};
+
+&dp_hpd {
+	samsung,pins = "gpc3-0";
+	samsung,pin-function = <0>;
+	samsung,pin-pud = <3>;
+	samsung,pin-drv = <0>;
+};
+
+&i2c_0 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <378000>;
+
+	s5m8767-pmic@66 {
+		compatible = "samsung,s5m8767-pmic";
+		reg = <0x66>;
+		interrupt-parent = <&gpx3>;
+		interrupts = <2 0>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&s5m8767_irq &s5m8767_dvs &s5m8767_ds>;
+		wakeup-source;
+
+		s5m8767,pmic-buck-dvs-gpios = <&gpd1 0 GPIO_ACTIVE_LOW>, /* DVS1 */
+		                              <&gpd1 1 GPIO_ACTIVE_LOW>, /* DVS2 */
+		                              <&gpd1 2 GPIO_ACTIVE_LOW>; /* DVS3 */
+
+		s5m8767,pmic-buck-ds-gpios = <&gpx2 3 GPIO_ACTIVE_LOW>, /* SET1 */
+		                             <&gpx2 4 GPIO_ACTIVE_LOW>, /* SET2 */
+		                             <&gpx2 5 GPIO_ACTIVE_LOW>; /* SET3 */
+
+		/*
+		 * The following arrays of DVS voltages are not used, since we are
+		 * not using GPIOs to control PMIC bucks, but they must be defined
+		 * to please the driver.
+		 */
+		s5m8767,pmic-buck2-dvs-voltage = <1350000>, <1300000>,
+		                                 <1250000>, <1200000>,
+		                                 <1150000>, <1100000>,
+		                                 <1000000>, <950000>;
+
+		s5m8767,pmic-buck3-dvs-voltage = <1100000>, <1100000>,
+		                                 <1100000>, <1100000>,
+		                                 <1000000>, <1000000>,
+		                                 <1000000>, <1000000>;
+
+		s5m8767,pmic-buck4-dvs-voltage = <1200000>, <1200000>,
+		                                 <1200000>, <1200000>,
+		                                 <1200000>, <1200000>,
+		                                 <1200000>, <1200000>;
+
+		clocks {
+			compatible = "samsung,s5m8767-clk";
+			#clock-cells = <1>;
+			clock-output-names = "en32khz_ap",
+			                     "en32khz_cp",
+			                     "en32khz_bt";
+		};
+
+		regulators {
+			s5m_ldo4_reg: LDO4 {
+				regulator-name = "P1.0V_LDO_OUT4";
+				regulator-min-microvolt = <1000000>;
+				regulator-max-microvolt = <1000000>;
+				regulator-always-on;
+				op_mode = <0>;
+			};
+
+			s5m_ldo5_reg: LDO5 {
+				regulator-name = "P1.0V_LDO_OUT5";
+				regulator-min-microvolt = <1000000>;
+				regulator-max-microvolt = <1000000>;
+				regulator-always-on;
+				op_mode = <0>;
+			};
+
+			s5m_ldo6_reg: LDO6 {
+				regulator-name = "vdd_mydp";
+				regulator-min-microvolt = <1000000>;
+				regulator-max-microvolt = <1000000>;
+				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo7_reg: LDO7 {
+				regulator-name = "P1.1V_LDO_OUT7";
+				regulator-min-microvolt = <1100000>;
+				regulator-max-microvolt = <1100000>;
+				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo8_reg: LDO8 {
+				regulator-name = "P1.0V_LDO_OUT8";
+				regulator-min-microvolt = <1000000>;
+				regulator-max-microvolt = <1000000>;
+				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo10_reg: LDO10 {
+				regulator-name = "P1.8V_LDO_OUT10";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo11_reg: LDO11 {
+				regulator-name = "P1.8V_LDO_OUT11";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+				op_mode = <0>;
+			};
+
+			s5m_ldo12_reg: LDO12 {
+				regulator-name = "P3.0V_LDO_OUT12";
+				regulator-min-microvolt = <3000000>;
+				regulator-max-microvolt = <3000000>;
+				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo13_reg: LDO13 {
+				regulator-name = "P1.8V_LDO_OUT13";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+				op_mode = <0>;
+			};
+
+			s5m_ldo14_reg: LDO14 {
+				regulator-name = "P1.8V_LDO_OUT14";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo15_reg: LDO15 {
+				regulator-name = "P1.0V_LDO_OUT15";
+				regulator-min-microvolt = <1000000>;
+				regulator-max-microvolt = <1000000>;
+				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo16_reg: LDO16 {
+				regulator-name = "P1.8V_LDO_OUT16";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo17_reg: LDO17 {
+				regulator-name = "P2.8V_LDO_OUT17";
+				regulator-min-microvolt = <2800000>;
+				regulator-max-microvolt = <2800000>;
+				regulator-always-on;
+				op_mode = <0>;
+			};
+
+			s5m_ldo25_reg: LDO25 {
+				regulator-name = "vdd_bridge";
+				regulator-min-microvolt = <1200000>;
+				regulator-max-microvolt = <1200000>;
+				regulator-always-on;
+				op_mode = <1>;
+			};
+
+			BUCK1 {
+				regulator-name = "vdd_mif";
+				regulator-min-microvolt = <950000>;
+				regulator-max-microvolt = <1300000>;
+				regulator-always-on;
+				regulator-boot-on;
+				op_mode = <3>;
+			};
+
+			BUCK2 {
+				regulator-name = "vdd_arm";
+				regulator-min-microvolt = <850000>;
+				regulator-max-microvolt = <1350000>;
+				regulator-always-on;
+				regulator-boot-on;
+				op_mode = <3>;
+			};
+
+			BUCK3 {
+				regulator-name = "vdd_int";
+				regulator-min-microvolt = <900000>;
+				regulator-max-microvolt = <1200000>;
+				regulator-always-on;
+				regulator-boot-on;
+				op_mode = <3>;
+			};
+
+			BUCK4 {
+				regulator-name = "vdd_g3d";
+				regulator-min-microvolt = <850000>;
+				regulator-max-microvolt = <1300000>;
+				regulator-boot-on;
+				op_mode = <3>;
+			};
+
+			BUCK5 {
+				regulator-name = "P1.8V_BUCK_OUT5";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+				regulator-boot-on;
+				op_mode = <1>;
+			};
+
+			BUCK6 {
+				regulator-name = "P1.2V_BUCK_OUT6";
+				regulator-min-microvolt = <1200000>;
+				regulator-max-microvolt = <1200000>;
+				regulator-always-on;
+				regulator-boot-on;
+				op_mode = <0>;
+			};
+
+			BUCK9 {
+				regulator-name = "vdd_ummc";
+				regulator-min-microvolt = <950000>;
+				regulator-max-microvolt = <3000000>;
+				regulator-always-on;
+				regulator-boot-on;
+				op_mode = <3>;
+			};
+		};
+	};
+};
+
+&i2c_1 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <378000>;
+};
+
+/*
+ * Disabled pullups since external part has its own pullups and
+ * double-pulling gets us out of spec in some cases.
+ */
+&i2c2_bus {
+	samsung,pin-pud = <0>;
+};
+
+&i2c_2 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+
+	hdmiddc@50 {
+		compatible = "samsung,exynos4210-hdmiddc";
+		reg = <0x50>;
+	};
+};
+
+&i2c_3 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+};
+
+&i2c_4 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+
+	cros_ec: embedded-controller {
+		compatible = "google,cros-ec-i2c";
+		reg = <0x1e>;
+		interrupts = <6 0>;
+		interrupt-parent = <&gpx1>;
+		wakeup-source;
+		pinctrl-names = "default";
+		pinctrl-0 = <&ec_irq>;
+	};
+};
+
+&i2c_5 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+};
+
+&i2c_7 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+};
+
+&i2c_8 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <378000>;
+
+	hdmiphy: hdmiphy@38 {
+		compatible = "samsung,exynos4212-hdmiphy";
+		reg = <0x38>;
+	};
+};
+
+&i2s0 {
+	status = "okay";
+};
+
+&mmc_0 {
+	status = "okay";
+	num-slots = <1>;
+	supports-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>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&sd0_clk &sd0_cmd &sd0_cd &sd0_bus4 &sd0_bus8>;
+
+	slot@0 {
+		reg = <0>;
+		bus-width = <8>;
+	};
+};
+
+&mmc_1 {
+	status = "okay";
+	num-slots = <1>;
+	supports-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>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&sd1_clk &sd1_cmd &sd1_cd &sd1_bus4>;
+
+	slot@0 {
+		reg = <0>;
+		bus-width = <4>;
+	};
+};
+
+&pinctrl_0 {
+	s5m8767_dvs: s5m8767-dvs {
+		samsung,pins = "gpd1-0", "gpd1-1", "gpd1-2";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <1>;
+		samsung,pin-drv = <0>;
+	};
+
+	power_key_irq: power-key-irq {
+		samsung,pins = "gpx1-3";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	ec_irq: ec-irq {
+		samsung,pins = "gpx1-6";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	s5m8767_ds: s5m8767-ds {
+		samsung,pins = "gpx2-3", "gpx2-4", "gpx2-5";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <1>;
+		samsung,pin-drv = <0>;
+	};
+
+	s5m8767_irq: s5m8767-irq {
+		samsung,pins = "gpx3-2";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	lid_irq: lid-irq {
+		samsung,pins = "gpx3-5";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	hdmi_hpd_irq: hdmi-hpd-irq {
+		samsung,pins = "gpx3-7";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <1>;
+		samsung,pin-drv = <0>;
+	};
+};
+
+&pinctrl_1 {
+	hsic_reset: hsic-reset {
+		samsung,pins = "gpe1-0";
+		samsung,pin-function = <1>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+};
+
+&sd1_clk {
+	samsung,pin-drv = <0>;
+};
+
+&sd1_cmd {
+	samsung,pin-pud = <3>;
+	samsung,pin-drv = <0>;
+};
+
+&sd1_cd {
+	samsung,pin-drv = <0>;
+};
+
+&sd1_bus4 {
+	samsung,pin-drv = <0>;
+};
+
+&spi_1 {
+	status = "okay";
+	samsung,spi-src-clk = <0>;
+	num-cs = <1>;
+};
+
+&usbdrd_phy {
+	vbus-supply = <&usb3_vbus_reg>;
+};
+
+#include "cros-ec-keyboard.dtsi"
-- 
1.9.3


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

* [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
@ 2014-07-31 16:08   ` Andreas Färber
  0 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 16:08 UTC (permalink / raw)
  To: linux-samsung-soc
  Cc: linux-arm-kernel, devicetree, Stephan van Schaik,
	Vincent Palatin, Doug Anderson, Javier Martinez Canillas,
	Andreas Färber, Rob Herring, Pawel Moll, Mark Rutland,
	Ian Campbell, Kumar Gala, Russell King, Ben Dooks, Kukjin Kim,
	open list

Adds initial support for the HP Chromebook 11.

Cc: Vincent Palatin <vpalatin@chromium.org>
Cc: Doug Anderson <dianders@chromium.org>
Cc: Stephan van Schaik <stephan@synkhronix.com>
Signed-off-by: Andreas Färber <afaerber@suse.de>
---
 v3 -> v4:
 * Fixed samsung,pin-function 1 -> 0 for dp-hpd-gpio
 * Replaced dp-hpd-gpio with existing dp_hpd, overriding it
 
 v2 -> v3:
 * Use GPIO_ACTIVE_{LOW,HIGH} (Doug Anderson)
 * Use symbolic KEY_POWER instead of comment
 * Moved hsic_reset to new USB3503 node's reset-gpios (Vincent Palatin)
 * Use dp_hpd_gpio for dp-controller (Doug Anderson, Ajay Kumar)
 * Override sd1_{clk,cmd,cd,bus4} pinctrl similar to Snow (Doug Anderson)
 * Added ec_irq pinctrl for cros_ec (Doug Anderson)
 * Reordered nodes to minimize diff against Snow (Doug Anderson)
 * Dropped obsolete mmc_2 override (Doug Anderson)
 * Added lid-switch node (Doug Anderson)
 * Added gpio-keys pinctrl (Doug Anderson)
 * Added bootargs to avoid empty /chosen node and to document console setting
 * Renamed s5m8767_pmic node to avoid underscore
 * Use new style for overriding inherited pinctrl nodes, too
 * Enable i2s0 node
 
 v1 -> v2:
 * Use label-based overriding/extension of nodes. (Doug Anderson)
 * Dropped tps65090 for now, until we know where to place it.
 * Dropped non-Spring nodes from -cros-common.dtsi rather than disabling them.
 * Enabled a missing MMC node for access to internal storage.
 * Dropped display-timings from dp-controller node. (Ajay Kumar)

 arch/arm/boot/dts/Makefile              |   1 +
 arch/arm/boot/dts/exynos5250-spring.dts | 539 ++++++++++++++++++++++++++++++++
 2 files changed, 540 insertions(+)
 create mode 100644 arch/arm/boot/dts/exynos5250-spring.dts

diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
index 80a781f76e88..dec4c292f63d 100644
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
@@ -76,6 +76,7 @@ dtb-$(CONFIG_ARCH_EXYNOS) += exynos4210-origen.dtb \
 	exynos5250-arndale.dtb \
 	exynos5250-smdk5250.dtb \
 	exynos5250-snow.dtb \
+	exynos5250-spring.dtb \
 	exynos5260-xyref5260.dtb \
 	exynos5410-smdk5410.dtb \
 	exynos5420-arndale-octa.dtb \
diff --git a/arch/arm/boot/dts/exynos5250-spring.dts b/arch/arm/boot/dts/exynos5250-spring.dts
new file mode 100644
index 000000000000..1fdfa04182fc
--- /dev/null
+++ b/arch/arm/boot/dts/exynos5250-spring.dts
@@ -0,0 +1,539 @@
+/*
+ * Google Spring board device tree source
+ *
+ * Copyright (c) 2013 Google, Inc
+ * Copyright (c) 2014 SUSE LINUX Products GmbH
+ *
+ * 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 <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+#include "exynos5250.dtsi"
+
+/ {
+	model = "Google Spring";
+	compatible = "google,spring", "samsung,exynos5250", "samsung,exynos5";
+
+	memory {
+		reg = <0x40000000 0x80000000>;
+	};
+
+	chosen {
+		bootargs = "console=tty1";
+	};
+
+	gpio-keys {
+		compatible = "gpio-keys";
+		pinctrl-names = "default";
+		pinctrl-0 = <&power_key_irq>, <&lid_irq>;
+
+		power {
+			label = "Power";
+			gpios = <&gpx1 3 GPIO_ACTIVE_LOW>;
+			linux,code = <KEY_POWER>;
+			gpio-key,wakeup;
+		};
+
+		lid-switch {
+			label = "Lid";
+			gpios = <&gpx3 5 GPIO_ACTIVE_LOW>;
+			linux,input-type = <5>; /* EV_SW */
+			linux,code = <0>; /* SW_LID */
+			debounce-interval = <1>;
+			gpio-key,wakeup;
+		};
+	};
+
+	usb3_vbus_reg: regulator-usb3 {
+		compatible = "regulator-fixed";
+		regulator-name = "P5.0V_USB3CON";
+		regulator-min-microvolt = <5000000>;
+		regulator-max-microvolt = <5000000>;
+		gpio = <&gpe1 0 GPIO_ACTIVE_LOW>;
+		enable-active-high;
+	};
+
+	usb@12110000 {
+		samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
+	};
+
+	usb-hub {
+		compatible = "smsc,usb3503a";
+		reset-gpios = <&hsic_reset>;
+	};
+
+	fixed-rate-clocks {
+		xxti {
+			compatible = "samsung,clock-xxti";
+			clock-frequency = <24000000>;
+		};
+	};
+
+	hdmi {
+		hpd-gpio = <&gpx3 7 GPIO_ACTIVE_HIGH>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&hdmi_hpd_irq>;
+		phy = <&hdmiphy>;
+		ddc = <&i2c_2>;
+		hdmi-en-supply = <&s5m_ldo8_reg>;
+		vdd-supply = <&s5m_ldo8_reg>;
+		vdd_osc-supply = <&s5m_ldo10_reg>;
+		vdd_pll-supply = <&s5m_ldo8_reg>;
+	};
+
+	fimd@14400000 {
+		status = "okay";
+		samsung,invert-vclk;
+	};
+
+	dp-controller@145B0000 {
+		status = "okay";
+		pinctrl-names = "default";
+		pinctrl-0 = <&dp_hpd>;
+		samsung,color-space = <0>;
+		samsung,dynamic-range = <0>;
+		samsung,ycbcr-coeff = <0>;
+		samsung,color-depth = <1>;
+		samsung,link-rate = <0x0a>;
+		samsung,lane-count = <1>;
+		samsung,hpd-gpio = <&gpc3 0 GPIO_ACTIVE_HIGH>;
+	};
+};
+
+&dp_hpd {
+	samsung,pins = "gpc3-0";
+	samsung,pin-function = <0>;
+	samsung,pin-pud = <3>;
+	samsung,pin-drv = <0>;
+};
+
+&i2c_0 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <378000>;
+
+	s5m8767-pmic@66 {
+		compatible = "samsung,s5m8767-pmic";
+		reg = <0x66>;
+		interrupt-parent = <&gpx3>;
+		interrupts = <2 0>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&s5m8767_irq &s5m8767_dvs &s5m8767_ds>;
+		wakeup-source;
+
+		s5m8767,pmic-buck-dvs-gpios = <&gpd1 0 GPIO_ACTIVE_LOW>, /* DVS1 */
+		                              <&gpd1 1 GPIO_ACTIVE_LOW>, /* DVS2 */
+		                              <&gpd1 2 GPIO_ACTIVE_LOW>; /* DVS3 */
+
+		s5m8767,pmic-buck-ds-gpios = <&gpx2 3 GPIO_ACTIVE_LOW>, /* SET1 */
+		                             <&gpx2 4 GPIO_ACTIVE_LOW>, /* SET2 */
+		                             <&gpx2 5 GPIO_ACTIVE_LOW>; /* SET3 */
+
+		/*
+		 * The following arrays of DVS voltages are not used, since we are
+		 * not using GPIOs to control PMIC bucks, but they must be defined
+		 * to please the driver.
+		 */
+		s5m8767,pmic-buck2-dvs-voltage = <1350000>, <1300000>,
+		                                 <1250000>, <1200000>,
+		                                 <1150000>, <1100000>,
+		                                 <1000000>, <950000>;
+
+		s5m8767,pmic-buck3-dvs-voltage = <1100000>, <1100000>,
+		                                 <1100000>, <1100000>,
+		                                 <1000000>, <1000000>,
+		                                 <1000000>, <1000000>;
+
+		s5m8767,pmic-buck4-dvs-voltage = <1200000>, <1200000>,
+		                                 <1200000>, <1200000>,
+		                                 <1200000>, <1200000>,
+		                                 <1200000>, <1200000>;
+
+		clocks {
+			compatible = "samsung,s5m8767-clk";
+			#clock-cells = <1>;
+			clock-output-names = "en32khz_ap",
+			                     "en32khz_cp",
+			                     "en32khz_bt";
+		};
+
+		regulators {
+			s5m_ldo4_reg: LDO4 {
+				regulator-name = "P1.0V_LDO_OUT4";
+				regulator-min-microvolt = <1000000>;
+				regulator-max-microvolt = <1000000>;
+				regulator-always-on;
+				op_mode = <0>;
+			};
+
+			s5m_ldo5_reg: LDO5 {
+				regulator-name = "P1.0V_LDO_OUT5";
+				regulator-min-microvolt = <1000000>;
+				regulator-max-microvolt = <1000000>;
+				regulator-always-on;
+				op_mode = <0>;
+			};
+
+			s5m_ldo6_reg: LDO6 {
+				regulator-name = "vdd_mydp";
+				regulator-min-microvolt = <1000000>;
+				regulator-max-microvolt = <1000000>;
+				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo7_reg: LDO7 {
+				regulator-name = "P1.1V_LDO_OUT7";
+				regulator-min-microvolt = <1100000>;
+				regulator-max-microvolt = <1100000>;
+				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo8_reg: LDO8 {
+				regulator-name = "P1.0V_LDO_OUT8";
+				regulator-min-microvolt = <1000000>;
+				regulator-max-microvolt = <1000000>;
+				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo10_reg: LDO10 {
+				regulator-name = "P1.8V_LDO_OUT10";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo11_reg: LDO11 {
+				regulator-name = "P1.8V_LDO_OUT11";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+				op_mode = <0>;
+			};
+
+			s5m_ldo12_reg: LDO12 {
+				regulator-name = "P3.0V_LDO_OUT12";
+				regulator-min-microvolt = <3000000>;
+				regulator-max-microvolt = <3000000>;
+				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo13_reg: LDO13 {
+				regulator-name = "P1.8V_LDO_OUT13";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+				op_mode = <0>;
+			};
+
+			s5m_ldo14_reg: LDO14 {
+				regulator-name = "P1.8V_LDO_OUT14";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo15_reg: LDO15 {
+				regulator-name = "P1.0V_LDO_OUT15";
+				regulator-min-microvolt = <1000000>;
+				regulator-max-microvolt = <1000000>;
+				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo16_reg: LDO16 {
+				regulator-name = "P1.8V_LDO_OUT16";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo17_reg: LDO17 {
+				regulator-name = "P2.8V_LDO_OUT17";
+				regulator-min-microvolt = <2800000>;
+				regulator-max-microvolt = <2800000>;
+				regulator-always-on;
+				op_mode = <0>;
+			};
+
+			s5m_ldo25_reg: LDO25 {
+				regulator-name = "vdd_bridge";
+				regulator-min-microvolt = <1200000>;
+				regulator-max-microvolt = <1200000>;
+				regulator-always-on;
+				op_mode = <1>;
+			};
+
+			BUCK1 {
+				regulator-name = "vdd_mif";
+				regulator-min-microvolt = <950000>;
+				regulator-max-microvolt = <1300000>;
+				regulator-always-on;
+				regulator-boot-on;
+				op_mode = <3>;
+			};
+
+			BUCK2 {
+				regulator-name = "vdd_arm";
+				regulator-min-microvolt = <850000>;
+				regulator-max-microvolt = <1350000>;
+				regulator-always-on;
+				regulator-boot-on;
+				op_mode = <3>;
+			};
+
+			BUCK3 {
+				regulator-name = "vdd_int";
+				regulator-min-microvolt = <900000>;
+				regulator-max-microvolt = <1200000>;
+				regulator-always-on;
+				regulator-boot-on;
+				op_mode = <3>;
+			};
+
+			BUCK4 {
+				regulator-name = "vdd_g3d";
+				regulator-min-microvolt = <850000>;
+				regulator-max-microvolt = <1300000>;
+				regulator-boot-on;
+				op_mode = <3>;
+			};
+
+			BUCK5 {
+				regulator-name = "P1.8V_BUCK_OUT5";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+				regulator-boot-on;
+				op_mode = <1>;
+			};
+
+			BUCK6 {
+				regulator-name = "P1.2V_BUCK_OUT6";
+				regulator-min-microvolt = <1200000>;
+				regulator-max-microvolt = <1200000>;
+				regulator-always-on;
+				regulator-boot-on;
+				op_mode = <0>;
+			};
+
+			BUCK9 {
+				regulator-name = "vdd_ummc";
+				regulator-min-microvolt = <950000>;
+				regulator-max-microvolt = <3000000>;
+				regulator-always-on;
+				regulator-boot-on;
+				op_mode = <3>;
+			};
+		};
+	};
+};
+
+&i2c_1 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <378000>;
+};
+
+/*
+ * Disabled pullups since external part has its own pullups and
+ * double-pulling gets us out of spec in some cases.
+ */
+&i2c2_bus {
+	samsung,pin-pud = <0>;
+};
+
+&i2c_2 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+
+	hdmiddc@50 {
+		compatible = "samsung,exynos4210-hdmiddc";
+		reg = <0x50>;
+	};
+};
+
+&i2c_3 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+};
+
+&i2c_4 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+
+	cros_ec: embedded-controller {
+		compatible = "google,cros-ec-i2c";
+		reg = <0x1e>;
+		interrupts = <6 0>;
+		interrupt-parent = <&gpx1>;
+		wakeup-source;
+		pinctrl-names = "default";
+		pinctrl-0 = <&ec_irq>;
+	};
+};
+
+&i2c_5 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+};
+
+&i2c_7 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+};
+
+&i2c_8 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <378000>;
+
+	hdmiphy: hdmiphy@38 {
+		compatible = "samsung,exynos4212-hdmiphy";
+		reg = <0x38>;
+	};
+};
+
+&i2s0 {
+	status = "okay";
+};
+
+&mmc_0 {
+	status = "okay";
+	num-slots = <1>;
+	supports-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>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&sd0_clk &sd0_cmd &sd0_cd &sd0_bus4 &sd0_bus8>;
+
+	slot@0 {
+		reg = <0>;
+		bus-width = <8>;
+	};
+};
+
+&mmc_1 {
+	status = "okay";
+	num-slots = <1>;
+	supports-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>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&sd1_clk &sd1_cmd &sd1_cd &sd1_bus4>;
+
+	slot@0 {
+		reg = <0>;
+		bus-width = <4>;
+	};
+};
+
+&pinctrl_0 {
+	s5m8767_dvs: s5m8767-dvs {
+		samsung,pins = "gpd1-0", "gpd1-1", "gpd1-2";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <1>;
+		samsung,pin-drv = <0>;
+	};
+
+	power_key_irq: power-key-irq {
+		samsung,pins = "gpx1-3";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	ec_irq: ec-irq {
+		samsung,pins = "gpx1-6";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	s5m8767_ds: s5m8767-ds {
+		samsung,pins = "gpx2-3", "gpx2-4", "gpx2-5";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <1>;
+		samsung,pin-drv = <0>;
+	};
+
+	s5m8767_irq: s5m8767-irq {
+		samsung,pins = "gpx3-2";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	lid_irq: lid-irq {
+		samsung,pins = "gpx3-5";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	hdmi_hpd_irq: hdmi-hpd-irq {
+		samsung,pins = "gpx3-7";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <1>;
+		samsung,pin-drv = <0>;
+	};
+};
+
+&pinctrl_1 {
+	hsic_reset: hsic-reset {
+		samsung,pins = "gpe1-0";
+		samsung,pin-function = <1>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+};
+
+&sd1_clk {
+	samsung,pin-drv = <0>;
+};
+
+&sd1_cmd {
+	samsung,pin-pud = <3>;
+	samsung,pin-drv = <0>;
+};
+
+&sd1_cd {
+	samsung,pin-drv = <0>;
+};
+
+&sd1_bus4 {
+	samsung,pin-drv = <0>;
+};
+
+&spi_1 {
+	status = "okay";
+	samsung,spi-src-clk = <0>;
+	num-cs = <1>;
+};
+
+&usbdrd_phy {
+	vbus-supply = <&usb3_vbus_reg>;
+};
+
+#include "cros-ec-keyboard.dtsi"
-- 
1.9.3

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

* [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
@ 2014-07-31 16:08   ` Andreas Färber
  0 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 16:08 UTC (permalink / raw)
  To: linux-arm-kernel

Adds initial support for the HP Chromebook 11.

Cc: Vincent Palatin <vpalatin@chromium.org>
Cc: Doug Anderson <dianders@chromium.org>
Cc: Stephan van Schaik <stephan@synkhronix.com>
Signed-off-by: Andreas F?rber <afaerber@suse.de>
---
 v3 -> v4:
 * Fixed samsung,pin-function 1 -> 0 for dp-hpd-gpio
 * Replaced dp-hpd-gpio with existing dp_hpd, overriding it
 
 v2 -> v3:
 * Use GPIO_ACTIVE_{LOW,HIGH} (Doug Anderson)
 * Use symbolic KEY_POWER instead of comment
 * Moved hsic_reset to new USB3503 node's reset-gpios (Vincent Palatin)
 * Use dp_hpd_gpio for dp-controller (Doug Anderson, Ajay Kumar)
 * Override sd1_{clk,cmd,cd,bus4} pinctrl similar to Snow (Doug Anderson)
 * Added ec_irq pinctrl for cros_ec (Doug Anderson)
 * Reordered nodes to minimize diff against Snow (Doug Anderson)
 * Dropped obsolete mmc_2 override (Doug Anderson)
 * Added lid-switch node (Doug Anderson)
 * Added gpio-keys pinctrl (Doug Anderson)
 * Added bootargs to avoid empty /chosen node and to document console setting
 * Renamed s5m8767_pmic node to avoid underscore
 * Use new style for overriding inherited pinctrl nodes, too
 * Enable i2s0 node
 
 v1 -> v2:
 * Use label-based overriding/extension of nodes. (Doug Anderson)
 * Dropped tps65090 for now, until we know where to place it.
 * Dropped non-Spring nodes from -cros-common.dtsi rather than disabling them.
 * Enabled a missing MMC node for access to internal storage.
 * Dropped display-timings from dp-controller node. (Ajay Kumar)

 arch/arm/boot/dts/Makefile              |   1 +
 arch/arm/boot/dts/exynos5250-spring.dts | 539 ++++++++++++++++++++++++++++++++
 2 files changed, 540 insertions(+)
 create mode 100644 arch/arm/boot/dts/exynos5250-spring.dts

diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
index 80a781f76e88..dec4c292f63d 100644
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
@@ -76,6 +76,7 @@ dtb-$(CONFIG_ARCH_EXYNOS) += exynos4210-origen.dtb \
 	exynos5250-arndale.dtb \
 	exynos5250-smdk5250.dtb \
 	exynos5250-snow.dtb \
+	exynos5250-spring.dtb \
 	exynos5260-xyref5260.dtb \
 	exynos5410-smdk5410.dtb \
 	exynos5420-arndale-octa.dtb \
diff --git a/arch/arm/boot/dts/exynos5250-spring.dts b/arch/arm/boot/dts/exynos5250-spring.dts
new file mode 100644
index 000000000000..1fdfa04182fc
--- /dev/null
+++ b/arch/arm/boot/dts/exynos5250-spring.dts
@@ -0,0 +1,539 @@
+/*
+ * Google Spring board device tree source
+ *
+ * Copyright (c) 2013 Google, Inc
+ * Copyright (c) 2014 SUSE LINUX Products GmbH
+ *
+ * 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 <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+#include "exynos5250.dtsi"
+
+/ {
+	model = "Google Spring";
+	compatible = "google,spring", "samsung,exynos5250", "samsung,exynos5";
+
+	memory {
+		reg = <0x40000000 0x80000000>;
+	};
+
+	chosen {
+		bootargs = "console=tty1";
+	};
+
+	gpio-keys {
+		compatible = "gpio-keys";
+		pinctrl-names = "default";
+		pinctrl-0 = <&power_key_irq>, <&lid_irq>;
+
+		power {
+			label = "Power";
+			gpios = <&gpx1 3 GPIO_ACTIVE_LOW>;
+			linux,code = <KEY_POWER>;
+			gpio-key,wakeup;
+		};
+
+		lid-switch {
+			label = "Lid";
+			gpios = <&gpx3 5 GPIO_ACTIVE_LOW>;
+			linux,input-type = <5>; /* EV_SW */
+			linux,code = <0>; /* SW_LID */
+			debounce-interval = <1>;
+			gpio-key,wakeup;
+		};
+	};
+
+	usb3_vbus_reg: regulator-usb3 {
+		compatible = "regulator-fixed";
+		regulator-name = "P5.0V_USB3CON";
+		regulator-min-microvolt = <5000000>;
+		regulator-max-microvolt = <5000000>;
+		gpio = <&gpe1 0 GPIO_ACTIVE_LOW>;
+		enable-active-high;
+	};
+
+	usb at 12110000 {
+		samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
+	};
+
+	usb-hub {
+		compatible = "smsc,usb3503a";
+		reset-gpios = <&hsic_reset>;
+	};
+
+	fixed-rate-clocks {
+		xxti {
+			compatible = "samsung,clock-xxti";
+			clock-frequency = <24000000>;
+		};
+	};
+
+	hdmi {
+		hpd-gpio = <&gpx3 7 GPIO_ACTIVE_HIGH>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&hdmi_hpd_irq>;
+		phy = <&hdmiphy>;
+		ddc = <&i2c_2>;
+		hdmi-en-supply = <&s5m_ldo8_reg>;
+		vdd-supply = <&s5m_ldo8_reg>;
+		vdd_osc-supply = <&s5m_ldo10_reg>;
+		vdd_pll-supply = <&s5m_ldo8_reg>;
+	};
+
+	fimd at 14400000 {
+		status = "okay";
+		samsung,invert-vclk;
+	};
+
+	dp-controller at 145B0000 {
+		status = "okay";
+		pinctrl-names = "default";
+		pinctrl-0 = <&dp_hpd>;
+		samsung,color-space = <0>;
+		samsung,dynamic-range = <0>;
+		samsung,ycbcr-coeff = <0>;
+		samsung,color-depth = <1>;
+		samsung,link-rate = <0x0a>;
+		samsung,lane-count = <1>;
+		samsung,hpd-gpio = <&gpc3 0 GPIO_ACTIVE_HIGH>;
+	};
+};
+
+&dp_hpd {
+	samsung,pins = "gpc3-0";
+	samsung,pin-function = <0>;
+	samsung,pin-pud = <3>;
+	samsung,pin-drv = <0>;
+};
+
+&i2c_0 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <378000>;
+
+	s5m8767-pmic at 66 {
+		compatible = "samsung,s5m8767-pmic";
+		reg = <0x66>;
+		interrupt-parent = <&gpx3>;
+		interrupts = <2 0>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&s5m8767_irq &s5m8767_dvs &s5m8767_ds>;
+		wakeup-source;
+
+		s5m8767,pmic-buck-dvs-gpios = <&gpd1 0 GPIO_ACTIVE_LOW>, /* DVS1 */
+		                              <&gpd1 1 GPIO_ACTIVE_LOW>, /* DVS2 */
+		                              <&gpd1 2 GPIO_ACTIVE_LOW>; /* DVS3 */
+
+		s5m8767,pmic-buck-ds-gpios = <&gpx2 3 GPIO_ACTIVE_LOW>, /* SET1 */
+		                             <&gpx2 4 GPIO_ACTIVE_LOW>, /* SET2 */
+		                             <&gpx2 5 GPIO_ACTIVE_LOW>; /* SET3 */
+
+		/*
+		 * The following arrays of DVS voltages are not used, since we are
+		 * not using GPIOs to control PMIC bucks, but they must be defined
+		 * to please the driver.
+		 */
+		s5m8767,pmic-buck2-dvs-voltage = <1350000>, <1300000>,
+		                                 <1250000>, <1200000>,
+		                                 <1150000>, <1100000>,
+		                                 <1000000>, <950000>;
+
+		s5m8767,pmic-buck3-dvs-voltage = <1100000>, <1100000>,
+		                                 <1100000>, <1100000>,
+		                                 <1000000>, <1000000>,
+		                                 <1000000>, <1000000>;
+
+		s5m8767,pmic-buck4-dvs-voltage = <1200000>, <1200000>,
+		                                 <1200000>, <1200000>,
+		                                 <1200000>, <1200000>,
+		                                 <1200000>, <1200000>;
+
+		clocks {
+			compatible = "samsung,s5m8767-clk";
+			#clock-cells = <1>;
+			clock-output-names = "en32khz_ap",
+			                     "en32khz_cp",
+			                     "en32khz_bt";
+		};
+
+		regulators {
+			s5m_ldo4_reg: LDO4 {
+				regulator-name = "P1.0V_LDO_OUT4";
+				regulator-min-microvolt = <1000000>;
+				regulator-max-microvolt = <1000000>;
+				regulator-always-on;
+				op_mode = <0>;
+			};
+
+			s5m_ldo5_reg: LDO5 {
+				regulator-name = "P1.0V_LDO_OUT5";
+				regulator-min-microvolt = <1000000>;
+				regulator-max-microvolt = <1000000>;
+				regulator-always-on;
+				op_mode = <0>;
+			};
+
+			s5m_ldo6_reg: LDO6 {
+				regulator-name = "vdd_mydp";
+				regulator-min-microvolt = <1000000>;
+				regulator-max-microvolt = <1000000>;
+				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo7_reg: LDO7 {
+				regulator-name = "P1.1V_LDO_OUT7";
+				regulator-min-microvolt = <1100000>;
+				regulator-max-microvolt = <1100000>;
+				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo8_reg: LDO8 {
+				regulator-name = "P1.0V_LDO_OUT8";
+				regulator-min-microvolt = <1000000>;
+				regulator-max-microvolt = <1000000>;
+				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo10_reg: LDO10 {
+				regulator-name = "P1.8V_LDO_OUT10";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo11_reg: LDO11 {
+				regulator-name = "P1.8V_LDO_OUT11";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+				op_mode = <0>;
+			};
+
+			s5m_ldo12_reg: LDO12 {
+				regulator-name = "P3.0V_LDO_OUT12";
+				regulator-min-microvolt = <3000000>;
+				regulator-max-microvolt = <3000000>;
+				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo13_reg: LDO13 {
+				regulator-name = "P1.8V_LDO_OUT13";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+				op_mode = <0>;
+			};
+
+			s5m_ldo14_reg: LDO14 {
+				regulator-name = "P1.8V_LDO_OUT14";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo15_reg: LDO15 {
+				regulator-name = "P1.0V_LDO_OUT15";
+				regulator-min-microvolt = <1000000>;
+				regulator-max-microvolt = <1000000>;
+				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo16_reg: LDO16 {
+				regulator-name = "P1.8V_LDO_OUT16";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo17_reg: LDO17 {
+				regulator-name = "P2.8V_LDO_OUT17";
+				regulator-min-microvolt = <2800000>;
+				regulator-max-microvolt = <2800000>;
+				regulator-always-on;
+				op_mode = <0>;
+			};
+
+			s5m_ldo25_reg: LDO25 {
+				regulator-name = "vdd_bridge";
+				regulator-min-microvolt = <1200000>;
+				regulator-max-microvolt = <1200000>;
+				regulator-always-on;
+				op_mode = <1>;
+			};
+
+			BUCK1 {
+				regulator-name = "vdd_mif";
+				regulator-min-microvolt = <950000>;
+				regulator-max-microvolt = <1300000>;
+				regulator-always-on;
+				regulator-boot-on;
+				op_mode = <3>;
+			};
+
+			BUCK2 {
+				regulator-name = "vdd_arm";
+				regulator-min-microvolt = <850000>;
+				regulator-max-microvolt = <1350000>;
+				regulator-always-on;
+				regulator-boot-on;
+				op_mode = <3>;
+			};
+
+			BUCK3 {
+				regulator-name = "vdd_int";
+				regulator-min-microvolt = <900000>;
+				regulator-max-microvolt = <1200000>;
+				regulator-always-on;
+				regulator-boot-on;
+				op_mode = <3>;
+			};
+
+			BUCK4 {
+				regulator-name = "vdd_g3d";
+				regulator-min-microvolt = <850000>;
+				regulator-max-microvolt = <1300000>;
+				regulator-boot-on;
+				op_mode = <3>;
+			};
+
+			BUCK5 {
+				regulator-name = "P1.8V_BUCK_OUT5";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+				regulator-boot-on;
+				op_mode = <1>;
+			};
+
+			BUCK6 {
+				regulator-name = "P1.2V_BUCK_OUT6";
+				regulator-min-microvolt = <1200000>;
+				regulator-max-microvolt = <1200000>;
+				regulator-always-on;
+				regulator-boot-on;
+				op_mode = <0>;
+			};
+
+			BUCK9 {
+				regulator-name = "vdd_ummc";
+				regulator-min-microvolt = <950000>;
+				regulator-max-microvolt = <3000000>;
+				regulator-always-on;
+				regulator-boot-on;
+				op_mode = <3>;
+			};
+		};
+	};
+};
+
+&i2c_1 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <378000>;
+};
+
+/*
+ * Disabled pullups since external part has its own pullups and
+ * double-pulling gets us out of spec in some cases.
+ */
+&i2c2_bus {
+	samsung,pin-pud = <0>;
+};
+
+&i2c_2 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+
+	hdmiddc at 50 {
+		compatible = "samsung,exynos4210-hdmiddc";
+		reg = <0x50>;
+	};
+};
+
+&i2c_3 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+};
+
+&i2c_4 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+
+	cros_ec: embedded-controller {
+		compatible = "google,cros-ec-i2c";
+		reg = <0x1e>;
+		interrupts = <6 0>;
+		interrupt-parent = <&gpx1>;
+		wakeup-source;
+		pinctrl-names = "default";
+		pinctrl-0 = <&ec_irq>;
+	};
+};
+
+&i2c_5 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+};
+
+&i2c_7 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <66000>;
+};
+
+&i2c_8 {
+	status = "okay";
+	samsung,i2c-sda-delay = <100>;
+	samsung,i2c-max-bus-freq = <378000>;
+
+	hdmiphy: hdmiphy at 38 {
+		compatible = "samsung,exynos4212-hdmiphy";
+		reg = <0x38>;
+	};
+};
+
+&i2s0 {
+	status = "okay";
+};
+
+&mmc_0 {
+	status = "okay";
+	num-slots = <1>;
+	supports-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>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&sd0_clk &sd0_cmd &sd0_cd &sd0_bus4 &sd0_bus8>;
+
+	slot at 0 {
+		reg = <0>;
+		bus-width = <8>;
+	};
+};
+
+&mmc_1 {
+	status = "okay";
+	num-slots = <1>;
+	supports-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>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&sd1_clk &sd1_cmd &sd1_cd &sd1_bus4>;
+
+	slot at 0 {
+		reg = <0>;
+		bus-width = <4>;
+	};
+};
+
+&pinctrl_0 {
+	s5m8767_dvs: s5m8767-dvs {
+		samsung,pins = "gpd1-0", "gpd1-1", "gpd1-2";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <1>;
+		samsung,pin-drv = <0>;
+	};
+
+	power_key_irq: power-key-irq {
+		samsung,pins = "gpx1-3";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	ec_irq: ec-irq {
+		samsung,pins = "gpx1-6";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	s5m8767_ds: s5m8767-ds {
+		samsung,pins = "gpx2-3", "gpx2-4", "gpx2-5";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <1>;
+		samsung,pin-drv = <0>;
+	};
+
+	s5m8767_irq: s5m8767-irq {
+		samsung,pins = "gpx3-2";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	lid_irq: lid-irq {
+		samsung,pins = "gpx3-5";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+
+	hdmi_hpd_irq: hdmi-hpd-irq {
+		samsung,pins = "gpx3-7";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <1>;
+		samsung,pin-drv = <0>;
+	};
+};
+
+&pinctrl_1 {
+	hsic_reset: hsic-reset {
+		samsung,pins = "gpe1-0";
+		samsung,pin-function = <1>;
+		samsung,pin-pud = <0>;
+		samsung,pin-drv = <0>;
+	};
+};
+
+&sd1_clk {
+	samsung,pin-drv = <0>;
+};
+
+&sd1_cmd {
+	samsung,pin-pud = <3>;
+	samsung,pin-drv = <0>;
+};
+
+&sd1_cd {
+	samsung,pin-drv = <0>;
+};
+
+&sd1_bus4 {
+	samsung,pin-drv = <0>;
+};
+
+&spi_1 {
+	status = "okay";
+	samsung,spi-src-clk = <0>;
+	num-cs = <1>;
+};
+
+&usbdrd_phy {
+	vbus-supply = <&usb3_vbus_reg>;
+};
+
+#include "cros-ec-keyboard.dtsi"
-- 
1.9.3

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

* Re: [PATCH v4 0/4] ARM: dts: exynos: Prepare Spring
  2014-07-31 16:08 ` Andreas Färber
@ 2014-07-31 16:21   ` Andreas Färber
  -1 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 16:21 UTC (permalink / raw)
  To: linux-samsung-soc
  Cc: linux-arm-kernel, devicetree, Stephan van Schaik,
	Vincent Palatin, Doug Anderson, Javier Martinez Canillas

[-- Attachment #1: Type: text/plain, Size: 515 bytes --]

Am 31.07.2014 18:08, schrieb Andreas Färber:
> Hello,
> 
> Based on the preinstalled 3.8 based ChromeOS kernel and previous 3.15 
> based attempts by Stephan and me that broke for 3.16, I've prepared a 
> device tree for the HP Chromebook 11 aka Google Spring.
> 
> v4 fixes a pinctrl bug.

Once again, resulting Snow vs. Spring diff attached for convenience.

Andreas

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg

[-- Attachment #2: spring-snow.v4.diff --]
[-- Type: text/x-patch, Size: 17117 bytes --]

--- arch/arm/boot/dts/exynos5250-snow.dts	2014-07-31 18:10:49.680004102 +0200
+++ arch/arm/boot/dts/exynos5250-spring.dts	2014-07-31 18:10:51.100004102 +0200
@@ -1,12 +1,13 @@
 /*
- * Google Snow board device tree source
+ * Google Spring board device tree source
  *
- * Copyright (c) 2012 Google, Inc
+ * Copyright (c) 2013 Google, Inc
+ * Copyright (c) 2014 SUSE LINUX Products GmbH
  *
  * 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 <dt-bindings/gpio/gpio.h>
@@ -14,26 +15,21 @@
 #include "exynos5250.dtsi"
 
 / {
-	model = "Google Snow";
-	compatible = "google,snow", "samsung,exynos5250", "samsung,exynos5";
-
-	aliases {
-		i2c104 = &i2c_104;
-	};
+	model = "Google Spring";
+	compatible = "google,spring", "samsung,exynos5250", "samsung,exynos5";
 
 	memory {
 		reg = <0x40000000 0x80000000>;
 	};
 
 	chosen {
-	};
-
-	rtc@101E0000 {
-		status = "okay";
+		bootargs = "console=tty1";
 	};
 
 	gpio-keys {
 		compatible = "gpio-keys";
+		pinctrl-names = "default";
+		pinctrl-0 = <&power_key_irq>, <&lid_irq>;
 
 		power {
 			label = "Power";
@@ -52,145 +48,12 @@
 		};
 	};
 
-	vbat: vbat-fixed-regulator {
-		compatible = "regulator-fixed";
-		regulator-name = "vbat-supply";
-		regulator-boot-on;
-	};
-
-	i2c-arbitrator {
-		compatible = "i2c-arb-gpio-challenge";
-		#address-cells = <1>;
-		#size-cells = <0>;
-
-		i2c-parent = <&{/i2c@12CA0000}>;
-
-		our-claim-gpio = <&gpf0 3 GPIO_ACTIVE_LOW>;
-		their-claim-gpios = <&gpe0 4 GPIO_ACTIVE_LOW>;
-		slew-delay-us = <10>;
-		wait-retry-us = <3000>;
-		wait-free-us = <50000>;
-
-		pinctrl-names = "default";
-		pinctrl-0 = <&arb_our_claim &arb_their_claim>;
-
-		/* Use ID 104 as a hint that we're on physical bus 4 */
-		i2c_104: i2c@0 {
-			reg = <0>;
-			#address-cells = <1>;
-			#size-cells = <0>;
-
-			battery: sbs-battery@b {
-				compatible = "sbs,sbs-battery";
-				reg = <0xb>;
-				sbs,poll-retry-count = <1>;
-			};
-
-			cros_ec: embedded-controller {
-				compatible = "google,cros-ec-i2c";
-				reg = <0x1e>;
-				interrupts = <6 0>;
-				interrupt-parent = <&gpx1>;
-				pinctrl-names = "default";
-				pinctrl-0 = <&ec_irq>;
-				wakeup-source;
-			};
-
-			power-regulator {
-				compatible = "ti,tps65090";
-				reg = <0x48>;
-
-				/*
-				 * Config irq to disable internal pulls
-				 * even though we run in polling mode.
-				 */
-				pinctrl-names = "default";
-				pinctrl-0 = <&tps65090_irq>;
-
-				vsys1-supply = <&vbat>;
-				vsys2-supply = <&vbat>;
-				vsys3-supply = <&vbat>;
-				infet1-supply = <&vbat>;
-				infet2-supply = <&vbat>;
-				infet3-supply = <&vbat>;
-				infet4-supply = <&vbat>;
-				infet5-supply = <&vbat>;
-				infet6-supply = <&vbat>;
-				infet7-supply = <&vbat>;
-				vsys-l1-supply = <&vbat>;
-				vsys-l2-supply = <&vbat>;
-
-				regulators {
-					dcdc1 {
-						ti,enable-ext-control;
-					};
-					dcdc2 {
-						ti,enable-ext-control;
-					};
-					dcdc3 {
-						ti,enable-ext-control;
-					};
-					fet1 {
-						regulator-name = "vcd_led";
-						ti,overcurrent-wait = <3>;
-					};
-					tps65090_fet2: fet2 {
-						regulator-name = "video_mid";
-						regulator-always-on;
-						ti,overcurrent-wait = <3>;
-					};
-					fet3 {
-						regulator-name = "wwan_r";
-						regulator-always-on;
-						ti,overcurrent-wait = <3>;
-					};
-					fet4 {
-						regulator-name = "sdcard";
-						ti,overcurrent-wait = <3>;
-					};
-					fet5 {
-						regulator-name = "camout";
-						regulator-always-on;
-						ti,overcurrent-wait = <3>;
-					};
-					fet6 {
-						regulator-name = "lcd_vdd";
-						ti,overcurrent-wait = <3>;
-					};
-					tps65090_fet7: fet7 {
-						regulator-name = "video_mid_1a";
-						regulator-always-on;
-						ti,overcurrent-wait = <3>;
-					};
-					ldo1 {
-					};
-					ldo2 {
-					};
-				};
-
-				charger {
-					compatible = "ti,tps65090-charger";
-				};
-			};
-		};
-	};
-
-	sound {
-		compatible = "google,snow-audio-max98095";
-
-		samsung,model = "Snow-I2S-MAX98095";
-		samsung,i2s-controller = <&i2s0>;
-		samsung,audio-codec = <&max98095>;
-	};
-
 	usb3_vbus_reg: regulator-usb3 {
 		compatible = "regulator-fixed";
 		regulator-name = "P5.0V_USB3CON";
 		regulator-min-microvolt = <5000000>;
 		regulator-max-microvolt = <5000000>;
-		gpio = <&gpx2 7 GPIO_ACTIVE_HIGH>;
-		pinctrl-names = "default";
-		pinctrl-0 = <&usb3_vbus_en>;
+		gpio = <&gpe1 0 GPIO_ACTIVE_LOW>;
 		enable-active-high;
 	};
 
@@ -198,6 +61,11 @@
 		samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
 	};
 
+	usb-hub {
+		compatible = "smsc,usb3503a";
+		reset-gpios = <&hsic_reset>;
+	};
+
 	fixed-rate-clocks {
 		xxti {
 			compatible = "samsung,clock-xxti";
@@ -211,19 +79,10 @@
 		pinctrl-0 = <&hdmi_hpd_irq>;
 		phy = <&hdmiphy>;
 		ddc = <&i2c_2>;
-		hdmi-en-supply = <&tps65090_fet7>;
-		vdd-supply = <&ldo8_reg>;
-		vdd_osc-supply = <&ldo10_reg>;
-		vdd_pll-supply = <&ldo8_reg>;
-	};
-
-	backlight {
-		compatible = "pwm-backlight";
-		pwms = <&pwm 0 1000000 0>;
-		brightness-levels = <0 100 500 1000 1500 2000 2500 2800>;
-		default-brightness-level = <7>;
-		pinctrl-0 = <&pwm0_out>;
-		pinctrl-names = "default";
+		hdmi-en-supply = <&s5m_ldo8_reg>;
+		vdd-supply = <&s5m_ldo8_reg>;
+		vdd_osc-supply = <&s5m_ldo10_reg>;
+		vdd_pll-supply = <&s5m_ldo8_reg>;
 	};
 
 	fimd@14400000 {
@@ -240,172 +99,241 @@
 		samsung,ycbcr-coeff = <0>;
 		samsung,color-depth = <1>;
 		samsung,link-rate = <0x0a>;
-		samsung,lane-count = <2>;
-		samsung,hpd-gpio = <&gpx0 7 GPIO_ACTIVE_HIGH>;
-
-		display-timings {
-			native-mode = <&timing1>;
-
-			timing1: timing@1 {
-				clock-frequency = <70589280>;
-				hactive = <1366>;
-				vactive = <768>;
-				hfront-porch = <40>;
-				hback-porch = <40>;
-				hsync-len = <32>;
-				vback-porch = <10>;
-				vfront-porch = <12>;
-				vsync-len = <6>;
-			};
-		};
+		samsung,lane-count = <1>;
+		samsung,hpd-gpio = <&gpc3 0 GPIO_ACTIVE_HIGH>;
 	};
 };
 
+&dp_hpd {
+	samsung,pins = "gpc3-0";
+	samsung,pin-function = <0>;
+	samsung,pin-pud = <3>;
+	samsung,pin-drv = <0>;
+};
+
 &i2c_0 {
 	status = "okay";
 	samsung,i2c-sda-delay = <100>;
 	samsung,i2c-max-bus-freq = <378000>;
 
-	max77686@09 {
-		compatible = "maxim,max77686";
+	s5m8767-pmic@66 {
+		compatible = "samsung,s5m8767-pmic";
+		reg = <0x66>;
 		interrupt-parent = <&gpx3>;
 		interrupts = <2 0>;
 		pinctrl-names = "default";
-		pinctrl-0 = <&max77686_irq>;
+		pinctrl-0 = <&s5m8767_irq &s5m8767_dvs &s5m8767_ds>;
 		wakeup-source;
-		reg = <0x09>;
-		#clock-cells = <1>;
 
-		voltage-regulators {
-			ldo1_reg: LDO1 {
-				regulator-name = "P1.0V_LDO_OUT1";
+		s5m8767,pmic-buck-dvs-gpios = <&gpd1 0 GPIO_ACTIVE_LOW>, /* DVS1 */
+		                              <&gpd1 1 GPIO_ACTIVE_LOW>, /* DVS2 */
+		                              <&gpd1 2 GPIO_ACTIVE_LOW>; /* DVS3 */
+
+		s5m8767,pmic-buck-ds-gpios = <&gpx2 3 GPIO_ACTIVE_LOW>, /* SET1 */
+		                             <&gpx2 4 GPIO_ACTIVE_LOW>, /* SET2 */
+		                             <&gpx2 5 GPIO_ACTIVE_LOW>; /* SET3 */
+
+		/*
+		 * The following arrays of DVS voltages are not used, since we are
+		 * not using GPIOs to control PMIC bucks, but they must be defined
+		 * to please the driver.
+		 */
+		s5m8767,pmic-buck2-dvs-voltage = <1350000>, <1300000>,
+		                                 <1250000>, <1200000>,
+		                                 <1150000>, <1100000>,
+		                                 <1000000>, <950000>;
+
+		s5m8767,pmic-buck3-dvs-voltage = <1100000>, <1100000>,
+		                                 <1100000>, <1100000>,
+		                                 <1000000>, <1000000>,
+		                                 <1000000>, <1000000>;
+
+		s5m8767,pmic-buck4-dvs-voltage = <1200000>, <1200000>,
+		                                 <1200000>, <1200000>,
+		                                 <1200000>, <1200000>,
+		                                 <1200000>, <1200000>;
+
+		clocks {
+			compatible = "samsung,s5m8767-clk";
+			#clock-cells = <1>;
+			clock-output-names = "en32khz_ap",
+			                     "en32khz_cp",
+			                     "en32khz_bt";
+		};
+
+		regulators {
+			s5m_ldo4_reg: LDO4 {
+				regulator-name = "P1.0V_LDO_OUT4";
 				regulator-min-microvolt = <1000000>;
 				regulator-max-microvolt = <1000000>;
 				regulator-always-on;
+				op_mode = <0>;
 			};
 
-			ldo2_reg: LDO2 {
-				regulator-name = "P1.8V_LDO_OUT2";
-				regulator-min-microvolt = <1800000>;
-				regulator-max-microvolt = <1800000>;
+			s5m_ldo5_reg: LDO5 {
+				regulator-name = "P1.0V_LDO_OUT5";
+				regulator-min-microvolt = <1000000>;
+				regulator-max-microvolt = <1000000>;
 				regulator-always-on;
+				op_mode = <0>;
 			};
 
-			ldo3_reg: LDO3 {
-				regulator-name = "P1.8V_LDO_OUT3";
-				regulator-min-microvolt = <1800000>;
-				regulator-max-microvolt = <1800000>;
+			s5m_ldo6_reg: LDO6 {
+				regulator-name = "vdd_mydp";
+				regulator-min-microvolt = <1000000>;
+				regulator-max-microvolt = <1000000>;
 				regulator-always-on;
+				op_mode = <3>;
 			};
 
-			ldo7_reg: LDO7 {
+			s5m_ldo7_reg: LDO7 {
 				regulator-name = "P1.1V_LDO_OUT7";
 				regulator-min-microvolt = <1100000>;
 				regulator-max-microvolt = <1100000>;
 				regulator-always-on;
+				op_mode = <3>;
 			};
 
-			ldo8_reg: LDO8 {
+			s5m_ldo8_reg: LDO8 {
 				regulator-name = "P1.0V_LDO_OUT8";
 				regulator-min-microvolt = <1000000>;
 				regulator-max-microvolt = <1000000>;
 				regulator-always-on;
+				op_mode = <3>;
 			};
 
-			ldo10_reg: LDO10 {
+			s5m_ldo10_reg: LDO10 {
 				regulator-name = "P1.8V_LDO_OUT10";
 				regulator-min-microvolt = <1800000>;
 				regulator-max-microvolt = <1800000>;
 				regulator-always-on;
+				op_mode = <3>;
 			};
 
-			ldo12_reg: LDO12 {
+			s5m_ldo11_reg: LDO11 {
+				regulator-name = "P1.8V_LDO_OUT11";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+				op_mode = <0>;
+			};
+
+			s5m_ldo12_reg: LDO12 {
 				regulator-name = "P3.0V_LDO_OUT12";
 				regulator-min-microvolt = <3000000>;
 				regulator-max-microvolt = <3000000>;
 				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo13_reg: LDO13 {
+				regulator-name = "P1.8V_LDO_OUT13";
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <1800000>;
+				regulator-always-on;
+				op_mode = <0>;
 			};
 
-			ldo14_reg: LDO14 {
+			s5m_ldo14_reg: LDO14 {
 				regulator-name = "P1.8V_LDO_OUT14";
 				regulator-min-microvolt = <1800000>;
 				regulator-max-microvolt = <1800000>;
 				regulator-always-on;
+				op_mode = <3>;
 			};
 
-			ldo15_reg: LDO15 {
+			s5m_ldo15_reg: LDO15 {
 				regulator-name = "P1.0V_LDO_OUT15";
 				regulator-min-microvolt = <1000000>;
 				regulator-max-microvolt = <1000000>;
 				regulator-always-on;
+				op_mode = <3>;
 			};
 
-			ldo16_reg: LDO16 {
+			s5m_ldo16_reg: LDO16 {
 				regulator-name = "P1.8V_LDO_OUT16";
 				regulator-min-microvolt = <1800000>;
 				regulator-max-microvolt = <1800000>;
 				regulator-always-on;
+				op_mode = <3>;
+			};
+
+			s5m_ldo17_reg: LDO17 {
+				regulator-name = "P2.8V_LDO_OUT17";
+				regulator-min-microvolt = <2800000>;
+				regulator-max-microvolt = <2800000>;
+				regulator-always-on;
+				op_mode = <0>;
+			};
+
+			s5m_ldo25_reg: LDO25 {
+				regulator-name = "vdd_bridge";
+				regulator-min-microvolt = <1200000>;
+				regulator-max-microvolt = <1200000>;
+				regulator-always-on;
+				op_mode = <1>;
 			};
 
-			buck1_reg: BUCK1 {
+			BUCK1 {
 				regulator-name = "vdd_mif";
 				regulator-min-microvolt = <950000>;
 				regulator-max-microvolt = <1300000>;
 				regulator-always-on;
 				regulator-boot-on;
+				op_mode = <3>;
 			};
 
-			buck2_reg: BUCK2 {
+			BUCK2 {
 				regulator-name = "vdd_arm";
 				regulator-min-microvolt = <850000>;
 				regulator-max-microvolt = <1350000>;
 				regulator-always-on;
 				regulator-boot-on;
+				op_mode = <3>;
 			};
 
-			buck3_reg: BUCK3 {
+			BUCK3 {
 				regulator-name = "vdd_int";
 				regulator-min-microvolt = <900000>;
 				regulator-max-microvolt = <1200000>;
 				regulator-always-on;
 				regulator-boot-on;
+				op_mode = <3>;
 			};
 
-			buck4_reg: BUCK4 {
+			BUCK4 {
 				regulator-name = "vdd_g3d";
 				regulator-min-microvolt = <850000>;
 				regulator-max-microvolt = <1300000>;
-				regulator-always-on;
 				regulator-boot-on;
+				op_mode = <3>;
 			};
 
-			buck5_reg: BUCK5 {
+			BUCK5 {
 				regulator-name = "P1.8V_BUCK_OUT5";
 				regulator-min-microvolt = <1800000>;
 				regulator-max-microvolt = <1800000>;
 				regulator-always-on;
 				regulator-boot-on;
+				op_mode = <1>;
 			};
 
-			buck6_reg: BUCK6 {
-				regulator-name = "P1.35V_BUCK_OUT6";
-				regulator-min-microvolt = <1350000>;
-				regulator-max-microvolt = <1350000>;
-				regulator-always-on;
-			};
-
-			buck7_reg: BUCK7 {
-				regulator-name = "P2.0V_BUCK_OUT7";
-				regulator-min-microvolt = <2000000>;
-				regulator-max-microvolt = <2000000>;
+			BUCK6 {
+				regulator-name = "P1.2V_BUCK_OUT6";
+				regulator-min-microvolt = <1200000>;
+				regulator-max-microvolt = <1200000>;
 				regulator-always-on;
+				regulator-boot-on;
+				op_mode = <0>;
 			};
 
-			buck8_reg: BUCK8 {
-				regulator-name = "P2.85V_BUCK_OUT8";
-				regulator-min-microvolt = <2850000>;
-				regulator-max-microvolt = <2850000>;
+			BUCK9 {
+				regulator-name = "vdd_ummc";
+				regulator-min-microvolt = <950000>;
+				regulator-max-microvolt = <3000000>;
 				regulator-always-on;
+				regulator-boot-on;
+				op_mode = <3>;
 			};
 		};
 	};
@@ -415,14 +343,6 @@
 	status = "okay";
 	samsung,i2c-sda-delay = <100>;
 	samsung,i2c-max-bus-freq = <378000>;
-
-	trackpad {
-		reg = <0x67>;
-		compatible = "cypress,cyapa";
-		interrupts = <2 0>;
-		interrupt-parent = <&gpx1>;
-		wakeup-source;
-	};
 };
 
 /*
@@ -454,6 +374,16 @@
 	status = "okay";
 	samsung,i2c-sda-delay = <100>;
 	samsung,i2c-max-bus-freq = <66000>;
+
+	cros_ec: embedded-controller {
+		compatible = "google,cros-ec-i2c";
+		reg = <0x1e>;
+		interrupts = <6 0>;
+		interrupt-parent = <&gpx1>;
+		wakeup-source;
+		pinctrl-names = "default";
+		pinctrl-0 = <&ec_irq>;
+	};
 };
 
 &i2c_5 {
@@ -466,13 +396,6 @@
 	status = "okay";
 	samsung,i2c-sda-delay = <100>;
 	samsung,i2c-max-bus-freq = <66000>;
-
-	max98095: codec@11 {
-		compatible = "maxim,max98095";
-		reg = <0x11>;
-		pinctrl-0 = <&max98095_en>;
-		pinctrl-names = "default";
-	};
 };
 
 &i2c_8 {
@@ -508,29 +431,7 @@
 	};
 };
 
-&mmc_2 {
-	status = "okay";
-	num-slots = <1>;
-	supports-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>;
-	pinctrl-names = "default";
-	pinctrl-0 = <&sd2_clk &sd2_cmd &sd2_cd &sd2_bus4>;
-
-	slot@0 {
-		reg = <0>;
-		bus-width = <4>;
-		wp-gpios = <&gpc2 1 0>;
-	};
-};
-
-/*
- * On Snow we've got SIP WiFi and so can keep drive strengths low to
- * reduce EMI.
- */
-&mmc_3 {
+&mmc_1 {
 	status = "okay";
 	num-slots = <1>;
 	supports-highspeed;
@@ -540,7 +441,7 @@
 	samsung,dw-mshc-sdr-timing = <2 3>;
 	samsung,dw-mshc-ddr-timing = <1 2>;
 	pinctrl-names = "default";
-	pinctrl-0 = <&sd3_clk &sd3_cmd &sd3_bus4>;
+	pinctrl-0 = <&sd1_clk &sd1_cmd &sd1_cd &sd1_bus4>;
 
 	slot@0 {
 		reg = <0>;
@@ -549,8 +450,15 @@
 };
 
 &pinctrl_0 {
-	max77686_irq: max77686-irq {
-		samsung,pins = "gpx3-2";
+	s5m8767_dvs: s5m8767-dvs {
+		samsung,pins = "gpd1-0", "gpd1-1", "gpd1-2";
+		samsung,pin-function = <0>;
+		samsung,pin-pud = <1>;
+		samsung,pin-drv = <0>;
+	};
+
+	power_key_irq: power-key-irq {
+		samsung,pins = "gpx1-3";
 		samsung,pin-function = <0>;
 		samsung,pin-pud = <0>;
 		samsung,pin-drv = <0>;
@@ -563,23 +471,23 @@
 		samsung,pin-drv = <0>;
 	};
 
-	max98095_en: max98095-en {
-		samsung,pins = "gpx1-7";
+	s5m8767_ds: s5m8767-ds {
+		samsung,pins = "gpx2-3", "gpx2-4", "gpx2-5";
 		samsung,pin-function = <0>;
-		samsung,pin-pud = <3>;
+		samsung,pin-pud = <1>;
 		samsung,pin-drv = <0>;
 	};
 
-	tps65090_irq: tps65090-irq {
-		samsung,pins = "gpx2-6";
+	s5m8767_irq: s5m8767-irq {
+		samsung,pins = "gpx3-2";
 		samsung,pin-function = <0>;
 		samsung,pin-pud = <0>;
 		samsung,pin-drv = <0>;
 	};
 
-	usb3_vbus_en: usb3-vbus-en {
-		samsung,pins = "gpx2-7";
-		samsung,pin-function = <1>;
+	lid_irq: lid-irq {
+		samsung,pins = "gpx3-5";
+		samsung,pin-function = <0>;
 		samsung,pin-pud = <0>;
 		samsung,pin-drv = <0>;
 	};
@@ -593,31 +501,28 @@
 };
 
 &pinctrl_1 {
-	arb_their_claim: arb-their-claim {
-		samsung,pins = "gpe0-4";
-		samsung,pin-function = <0>;
-		samsung,pin-pud = <3>;
-		samsung,pin-drv = <0>;
-	};
-
-	arb_our_claim: arb-our-claim {
-		samsung,pins = "gpf0-3";
+	hsic_reset: hsic-reset {
+		samsung,pins = "gpe1-0";
 		samsung,pin-function = <1>;
 		samsung,pin-pud = <0>;
 		samsung,pin-drv = <0>;
 	};
 };
 
-&sd3_clk {
+&sd1_clk {
 	samsung,pin-drv = <0>;
 };
 
-&sd3_cmd {
+&sd1_cmd {
 	samsung,pin-pud = <3>;
 	samsung,pin-drv = <0>;
 };
 
-&sd3_bus4 {
+&sd1_cd {
+	samsung,pin-drv = <0>;
+};
+
+&sd1_bus4 {
 	samsung,pin-drv = <0>;
 };
 

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

* [PATCH v4 0/4] ARM: dts: exynos: Prepare Spring
@ 2014-07-31 16:21   ` Andreas Färber
  0 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 16:21 UTC (permalink / raw)
  To: linux-arm-kernel

Am 31.07.2014 18:08, schrieb Andreas F?rber:
> Hello,
> 
> Based on the preinstalled 3.8 based ChromeOS kernel and previous 3.15 
> based attempts by Stephan and me that broke for 3.16, I've prepared a 
> device tree for the HP Chromebook 11 aka Google Spring.
> 
> v4 fixes a pinctrl bug.

Once again, resulting Snow vs. Spring diff attached for convenience.

Andreas

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 N?rnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imend?rffer; HRB 16746 AG N?rnberg
-------------- next part --------------
A non-text attachment was scrubbed...
Name: spring-snow.v4.diff
Type: text/x-patch
Size: 17117 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20140731/5522a095/attachment.bin>

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

* Re: [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
  2014-07-31 16:08   ` Andreas Färber
@ 2014-07-31 17:00     ` Vincent Palatin
  -1 siblings, 0 replies; 61+ messages in thread
From: Vincent Palatin @ 2014-07-31 17:00 UTC (permalink / raw)
  To: Andreas Färber
  Cc: linux-samsung-soc, ARM PORT, OPEN FIRMWARE AND...,
	Stephan van Schaik, Doug Anderson, Javier Martinez Canillas,
	Rob Herring, Pawel Moll, Mark Rutland, Ian Campbell, Kumar Gala,
	Russell King, Ben Dooks, Kukjin Kim, open list

Always a bit late to the game.
One small comment inline.

Reviewed-by: Vincent Palatin <vpalatin@chromium.org>

On Thu, Jul 31, 2014 at 9:08 AM, Andreas Färber <afaerber@suse.de> wrote:
> Adds initial support for the HP Chromebook 11.
>
> Cc: Vincent Palatin <vpalatin@chromium.org>
> Cc: Doug Anderson <dianders@chromium.org>
> Cc: Stephan van Schaik <stephan@synkhronix.com>
> Signed-off-by: Andreas Färber <afaerber@suse.de>
> ---
>  v3 -> v4:
>  * Fixed samsung,pin-function 1 -> 0 for dp-hpd-gpio
>  * Replaced dp-hpd-gpio with existing dp_hpd, overriding it
>
>  v2 -> v3:
>  * Use GPIO_ACTIVE_{LOW,HIGH} (Doug Anderson)
>  * Use symbolic KEY_POWER instead of comment
>  * Moved hsic_reset to new USB3503 node's reset-gpios (Vincent Palatin)
>  * Use dp_hpd_gpio for dp-controller (Doug Anderson, Ajay Kumar)
>  * Override sd1_{clk,cmd,cd,bus4} pinctrl similar to Snow (Doug Anderson)
>  * Added ec_irq pinctrl for cros_ec (Doug Anderson)
>  * Reordered nodes to minimize diff against Snow (Doug Anderson)
>  * Dropped obsolete mmc_2 override (Doug Anderson)
>  * Added lid-switch node (Doug Anderson)
>  * Added gpio-keys pinctrl (Doug Anderson)
>  * Added bootargs to avoid empty /chosen node and to document console setting
>  * Renamed s5m8767_pmic node to avoid underscore
>  * Use new style for overriding inherited pinctrl nodes, too
>  * Enable i2s0 node
>
>  v1 -> v2:
>  * Use label-based overriding/extension of nodes. (Doug Anderson)
>  * Dropped tps65090 for now, until we know where to place it.
>  * Dropped non-Spring nodes from -cros-common.dtsi rather than disabling them.
>  * Enabled a missing MMC node for access to internal storage.
>  * Dropped display-timings from dp-controller node. (Ajay Kumar)
>
>  arch/arm/boot/dts/Makefile              |   1 +
>  arch/arm/boot/dts/exynos5250-spring.dts | 539 ++++++++++++++++++++++++++++++++
>  2 files changed, 540 insertions(+)
>  create mode 100644 arch/arm/boot/dts/exynos5250-spring.dts
>
> diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
> index 80a781f76e88..dec4c292f63d 100644
> --- a/arch/arm/boot/dts/Makefile
> +++ b/arch/arm/boot/dts/Makefile
> @@ -76,6 +76,7 @@ dtb-$(CONFIG_ARCH_EXYNOS) += exynos4210-origen.dtb \
>         exynos5250-arndale.dtb \
>         exynos5250-smdk5250.dtb \
>         exynos5250-snow.dtb \
> +       exynos5250-spring.dtb \
>         exynos5260-xyref5260.dtb \
>         exynos5410-smdk5410.dtb \
>         exynos5420-arndale-octa.dtb \
> diff --git a/arch/arm/boot/dts/exynos5250-spring.dts b/arch/arm/boot/dts/exynos5250-spring.dts
> new file mode 100644
> index 000000000000..1fdfa04182fc
> --- /dev/null
> +++ b/arch/arm/boot/dts/exynos5250-spring.dts
> @@ -0,0 +1,539 @@
> +/*
> + * Google Spring board device tree source
> + *
> + * Copyright (c) 2013 Google, Inc
> + * Copyright (c) 2014 SUSE LINUX Products GmbH
> + *
> + * 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 <dt-bindings/gpio/gpio.h>
> +#include <dt-bindings/input/input.h>
> +#include "exynos5250.dtsi"
> +
> +/ {
> +       model = "Google Spring";
> +       compatible = "google,spring", "samsung,exynos5250", "samsung,exynos5";
> +
> +       memory {
> +               reg = <0x40000000 0x80000000>;
> +       };
> +
> +       chosen {
> +               bootargs = "console=tty1";
> +       };
> +
> +       gpio-keys {
> +               compatible = "gpio-keys";
> +               pinctrl-names = "default";
> +               pinctrl-0 = <&power_key_irq>, <&lid_irq>;
> +
> +               power {
> +                       label = "Power";
> +                       gpios = <&gpx1 3 GPIO_ACTIVE_LOW>;
> +                       linux,code = <KEY_POWER>;
> +                       gpio-key,wakeup;
> +               };
> +
> +               lid-switch {
> +                       label = "Lid";
> +                       gpios = <&gpx3 5 GPIO_ACTIVE_LOW>;
> +                       linux,input-type = <5>; /* EV_SW */
> +                       linux,code = <0>; /* SW_LID */
> +                       debounce-interval = <1>;
> +                       gpio-key,wakeup;
> +               };
> +       };
> +
> +       usb3_vbus_reg: regulator-usb3 {
> +               compatible = "regulator-fixed";
> +               regulator-name = "P5.0V_USB3CON";
> +               regulator-min-microvolt = <5000000>;
> +               regulator-max-microvolt = <5000000>;
> +               gpio = <&gpe1 0 GPIO_ACTIVE_LOW>;
> +               enable-active-high;
> +       };

GPE1_0 GPIO is the HSIC hub (SMSC 3503) reset# line (already defined
below afaik).
On this design there is no external USB3 port, so no VBUS reg/load
switch for USB3.



> +
> +       usb@12110000 {
> +               samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
> +       };
> +
> +       usb-hub {
> +               compatible = "smsc,usb3503a";
> +               reset-gpios = <&hsic_reset>;
> +       };
> +
> +       fixed-rate-clocks {
> +               xxti {
> +                       compatible = "samsung,clock-xxti";
> +                       clock-frequency = <24000000>;
> +               };
> +       };
> +
> +       hdmi {
> +               hpd-gpio = <&gpx3 7 GPIO_ACTIVE_HIGH>;
> +               pinctrl-names = "default";
> +               pinctrl-0 = <&hdmi_hpd_irq>;
> +               phy = <&hdmiphy>;
> +               ddc = <&i2c_2>;
> +               hdmi-en-supply = <&s5m_ldo8_reg>;
> +               vdd-supply = <&s5m_ldo8_reg>;
> +               vdd_osc-supply = <&s5m_ldo10_reg>;
> +               vdd_pll-supply = <&s5m_ldo8_reg>;
> +       };
> +
> +       fimd@14400000 {
> +               status = "okay";
> +               samsung,invert-vclk;
> +       };
> +
> +       dp-controller@145B0000 {
> +               status = "okay";
> +               pinctrl-names = "default";
> +               pinctrl-0 = <&dp_hpd>;
> +               samsung,color-space = <0>;
> +               samsung,dynamic-range = <0>;
> +               samsung,ycbcr-coeff = <0>;
> +               samsung,color-depth = <1>;
> +               samsung,link-rate = <0x0a>;
> +               samsung,lane-count = <1>;
> +               samsung,hpd-gpio = <&gpc3 0 GPIO_ACTIVE_HIGH>;
> +       };
> +};
> +
> +&dp_hpd {
> +       samsung,pins = "gpc3-0";
> +       samsung,pin-function = <0>;
> +       samsung,pin-pud = <3>;
> +       samsung,pin-drv = <0>;
> +};
> +
> +&i2c_0 {
> +       status = "okay";
> +       samsung,i2c-sda-delay = <100>;
> +       samsung,i2c-max-bus-freq = <378000>;
> +
> +       s5m8767-pmic@66 {
> +               compatible = "samsung,s5m8767-pmic";
> +               reg = <0x66>;
> +               interrupt-parent = <&gpx3>;
> +               interrupts = <2 0>;
> +               pinctrl-names = "default";
> +               pinctrl-0 = <&s5m8767_irq &s5m8767_dvs &s5m8767_ds>;
> +               wakeup-source;
> +
> +               s5m8767,pmic-buck-dvs-gpios = <&gpd1 0 GPIO_ACTIVE_LOW>, /* DVS1 */
> +                                             <&gpd1 1 GPIO_ACTIVE_LOW>, /* DVS2 */
> +                                             <&gpd1 2 GPIO_ACTIVE_LOW>; /* DVS3 */
> +
> +               s5m8767,pmic-buck-ds-gpios = <&gpx2 3 GPIO_ACTIVE_LOW>, /* SET1 */
> +                                            <&gpx2 4 GPIO_ACTIVE_LOW>, /* SET2 */
> +                                            <&gpx2 5 GPIO_ACTIVE_LOW>; /* SET3 */
> +
> +               /*
> +                * The following arrays of DVS voltages are not used, since we are
> +                * not using GPIOs to control PMIC bucks, but they must be defined
> +                * to please the driver.
> +                */
> +               s5m8767,pmic-buck2-dvs-voltage = <1350000>, <1300000>,
> +                                                <1250000>, <1200000>,
> +                                                <1150000>, <1100000>,
> +                                                <1000000>, <950000>;
> +
> +               s5m8767,pmic-buck3-dvs-voltage = <1100000>, <1100000>,
> +                                                <1100000>, <1100000>,
> +                                                <1000000>, <1000000>,
> +                                                <1000000>, <1000000>;
> +
> +               s5m8767,pmic-buck4-dvs-voltage = <1200000>, <1200000>,
> +                                                <1200000>, <1200000>,
> +                                                <1200000>, <1200000>,
> +                                                <1200000>, <1200000>;
> +
> +               clocks {
> +                       compatible = "samsung,s5m8767-clk";
> +                       #clock-cells = <1>;
> +                       clock-output-names = "en32khz_ap",
> +                                            "en32khz_cp",
> +                                            "en32khz_bt";
> +               };
> +
> +               regulators {
> +                       s5m_ldo4_reg: LDO4 {
> +                               regulator-name = "P1.0V_LDO_OUT4";
> +                               regulator-min-microvolt = <1000000>;
> +                               regulator-max-microvolt = <1000000>;
> +                               regulator-always-on;
> +                               op_mode = <0>;
> +                       };
> +
> +                       s5m_ldo5_reg: LDO5 {
> +                               regulator-name = "P1.0V_LDO_OUT5";
> +                               regulator-min-microvolt = <1000000>;
> +                               regulator-max-microvolt = <1000000>;
> +                               regulator-always-on;
> +                               op_mode = <0>;
> +                       };
> +
> +                       s5m_ldo6_reg: LDO6 {
> +                               regulator-name = "vdd_mydp";
> +                               regulator-min-microvolt = <1000000>;
> +                               regulator-max-microvolt = <1000000>;
> +                               regulator-always-on;
> +                               op_mode = <3>;
> +                       };
> +
> +                       s5m_ldo7_reg: LDO7 {
> +                               regulator-name = "P1.1V_LDO_OUT7";
> +                               regulator-min-microvolt = <1100000>;
> +                               regulator-max-microvolt = <1100000>;
> +                               regulator-always-on;
> +                               op_mode = <3>;
> +                       };
> +
> +                       s5m_ldo8_reg: LDO8 {
> +                               regulator-name = "P1.0V_LDO_OUT8";
> +                               regulator-min-microvolt = <1000000>;
> +                               regulator-max-microvolt = <1000000>;
> +                               regulator-always-on;
> +                               op_mode = <3>;
> +                       };
> +
> +                       s5m_ldo10_reg: LDO10 {
> +                               regulator-name = "P1.8V_LDO_OUT10";
> +                               regulator-min-microvolt = <1800000>;
> +                               regulator-max-microvolt = <1800000>;
> +                               regulator-always-on;
> +                               op_mode = <3>;
> +                       };
> +
> +                       s5m_ldo11_reg: LDO11 {
> +                               regulator-name = "P1.8V_LDO_OUT11";
> +                               regulator-min-microvolt = <1800000>;
> +                               regulator-max-microvolt = <1800000>;
> +                               regulator-always-on;
> +                               op_mode = <0>;
> +                       };
> +
> +                       s5m_ldo12_reg: LDO12 {
> +                               regulator-name = "P3.0V_LDO_OUT12";
> +                               regulator-min-microvolt = <3000000>;
> +                               regulator-max-microvolt = <3000000>;
> +                               regulator-always-on;
> +                               op_mode = <3>;
> +                       };
> +
> +                       s5m_ldo13_reg: LDO13 {
> +                               regulator-name = "P1.8V_LDO_OUT13";
> +                               regulator-min-microvolt = <1800000>;
> +                               regulator-max-microvolt = <1800000>;
> +                               regulator-always-on;
> +                               op_mode = <0>;
> +                       };
> +
> +                       s5m_ldo14_reg: LDO14 {
> +                               regulator-name = "P1.8V_LDO_OUT14";
> +                               regulator-min-microvolt = <1800000>;
> +                               regulator-max-microvolt = <1800000>;
> +                               regulator-always-on;
> +                               op_mode = <3>;
> +                       };
> +
> +                       s5m_ldo15_reg: LDO15 {
> +                               regulator-name = "P1.0V_LDO_OUT15";
> +                               regulator-min-microvolt = <1000000>;
> +                               regulator-max-microvolt = <1000000>;
> +                               regulator-always-on;
> +                               op_mode = <3>;
> +                       };
> +
> +                       s5m_ldo16_reg: LDO16 {
> +                               regulator-name = "P1.8V_LDO_OUT16";
> +                               regulator-min-microvolt = <1800000>;
> +                               regulator-max-microvolt = <1800000>;
> +                               regulator-always-on;
> +                               op_mode = <3>;
> +                       };
> +
> +                       s5m_ldo17_reg: LDO17 {
> +                               regulator-name = "P2.8V_LDO_OUT17";
> +                               regulator-min-microvolt = <2800000>;
> +                               regulator-max-microvolt = <2800000>;
> +                               regulator-always-on;
> +                               op_mode = <0>;
> +                       };
> +
> +                       s5m_ldo25_reg: LDO25 {
> +                               regulator-name = "vdd_bridge";
> +                               regulator-min-microvolt = <1200000>;
> +                               regulator-max-microvolt = <1200000>;
> +                               regulator-always-on;
> +                               op_mode = <1>;
> +                       };
> +
> +                       BUCK1 {
> +                               regulator-name = "vdd_mif";
> +                               regulator-min-microvolt = <950000>;
> +                               regulator-max-microvolt = <1300000>;
> +                               regulator-always-on;
> +                               regulator-boot-on;
> +                               op_mode = <3>;
> +                       };
> +
> +                       BUCK2 {
> +                               regulator-name = "vdd_arm";
> +                               regulator-min-microvolt = <850000>;
> +                               regulator-max-microvolt = <1350000>;
> +                               regulator-always-on;
> +                               regulator-boot-on;
> +                               op_mode = <3>;
> +                       };
> +
> +                       BUCK3 {
> +                               regulator-name = "vdd_int";
> +                               regulator-min-microvolt = <900000>;
> +                               regulator-max-microvolt = <1200000>;
> +                               regulator-always-on;
> +                               regulator-boot-on;
> +                               op_mode = <3>;
> +                       };
> +
> +                       BUCK4 {
> +                               regulator-name = "vdd_g3d";
> +                               regulator-min-microvolt = <850000>;
> +                               regulator-max-microvolt = <1300000>;
> +                               regulator-boot-on;
> +                               op_mode = <3>;
> +                       };
> +
> +                       BUCK5 {
> +                               regulator-name = "P1.8V_BUCK_OUT5";
> +                               regulator-min-microvolt = <1800000>;
> +                               regulator-max-microvolt = <1800000>;
> +                               regulator-always-on;
> +                               regulator-boot-on;
> +                               op_mode = <1>;
> +                       };
> +
> +                       BUCK6 {
> +                               regulator-name = "P1.2V_BUCK_OUT6";
> +                               regulator-min-microvolt = <1200000>;
> +                               regulator-max-microvolt = <1200000>;
> +                               regulator-always-on;
> +                               regulator-boot-on;
> +                               op_mode = <0>;
> +                       };
> +
> +                       BUCK9 {
> +                               regulator-name = "vdd_ummc";
> +                               regulator-min-microvolt = <950000>;
> +                               regulator-max-microvolt = <3000000>;
> +                               regulator-always-on;
> +                               regulator-boot-on;
> +                               op_mode = <3>;
> +                       };
> +               };
> +       };
> +};
> +
> +&i2c_1 {
> +       status = "okay";
> +       samsung,i2c-sda-delay = <100>;
> +       samsung,i2c-max-bus-freq = <378000>;
> +};
> +
> +/*
> + * Disabled pullups since external part has its own pullups and
> + * double-pulling gets us out of spec in some cases.
> + */
> +&i2c2_bus {
> +       samsung,pin-pud = <0>;
> +};
> +
> +&i2c_2 {
> +       status = "okay";
> +       samsung,i2c-sda-delay = <100>;
> +       samsung,i2c-max-bus-freq = <66000>;
> +
> +       hdmiddc@50 {
> +               compatible = "samsung,exynos4210-hdmiddc";
> +               reg = <0x50>;
> +       };
> +};
> +
> +&i2c_3 {
> +       status = "okay";
> +       samsung,i2c-sda-delay = <100>;
> +       samsung,i2c-max-bus-freq = <66000>;
> +};
> +
> +&i2c_4 {
> +       status = "okay";
> +       samsung,i2c-sda-delay = <100>;
> +       samsung,i2c-max-bus-freq = <66000>;
> +
> +       cros_ec: embedded-controller {
> +               compatible = "google,cros-ec-i2c";
> +               reg = <0x1e>;
> +               interrupts = <6 0>;
> +               interrupt-parent = <&gpx1>;
> +               wakeup-source;
> +               pinctrl-names = "default";
> +               pinctrl-0 = <&ec_irq>;
> +       };
> +};
> +
> +&i2c_5 {
> +       status = "okay";
> +       samsung,i2c-sda-delay = <100>;
> +       samsung,i2c-max-bus-freq = <66000>;
> +};
> +
> +&i2c_7 {
> +       status = "okay";
> +       samsung,i2c-sda-delay = <100>;
> +       samsung,i2c-max-bus-freq = <66000>;
> +};
> +
> +&i2c_8 {
> +       status = "okay";
> +       samsung,i2c-sda-delay = <100>;
> +       samsung,i2c-max-bus-freq = <378000>;
> +
> +       hdmiphy: hdmiphy@38 {
> +               compatible = "samsung,exynos4212-hdmiphy";
> +               reg = <0x38>;
> +       };
> +};
> +
> +&i2s0 {
> +       status = "okay";
> +};
> +
> +&mmc_0 {
> +       status = "okay";
> +       num-slots = <1>;
> +       supports-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>;
> +       pinctrl-names = "default";
> +       pinctrl-0 = <&sd0_clk &sd0_cmd &sd0_cd &sd0_bus4 &sd0_bus8>;
> +
> +       slot@0 {
> +               reg = <0>;
> +               bus-width = <8>;
> +       };
> +};
> +
> +&mmc_1 {
> +       status = "okay";
> +       num-slots = <1>;
> +       supports-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>;
> +       pinctrl-names = "default";
> +       pinctrl-0 = <&sd1_clk &sd1_cmd &sd1_cd &sd1_bus4>;
> +
> +       slot@0 {
> +               reg = <0>;
> +               bus-width = <4>;
> +       };
> +};
> +
> +&pinctrl_0 {
> +       s5m8767_dvs: s5m8767-dvs {
> +               samsung,pins = "gpd1-0", "gpd1-1", "gpd1-2";
> +               samsung,pin-function = <0>;
> +               samsung,pin-pud = <1>;
> +               samsung,pin-drv = <0>;
> +       };
> +
> +       power_key_irq: power-key-irq {
> +               samsung,pins = "gpx1-3";
> +               samsung,pin-function = <0>;
> +               samsung,pin-pud = <0>;
> +               samsung,pin-drv = <0>;
> +       };
> +
> +       ec_irq: ec-irq {
> +               samsung,pins = "gpx1-6";
> +               samsung,pin-function = <0>;
> +               samsung,pin-pud = <0>;
> +               samsung,pin-drv = <0>;
> +       };
> +
> +       s5m8767_ds: s5m8767-ds {
> +               samsung,pins = "gpx2-3", "gpx2-4", "gpx2-5";
> +               samsung,pin-function = <0>;
> +               samsung,pin-pud = <1>;
> +               samsung,pin-drv = <0>;
> +       };
> +
> +       s5m8767_irq: s5m8767-irq {
> +               samsung,pins = "gpx3-2";
> +               samsung,pin-function = <0>;
> +               samsung,pin-pud = <0>;
> +               samsung,pin-drv = <0>;
> +       };
> +
> +       lid_irq: lid-irq {
> +               samsung,pins = "gpx3-5";
> +               samsung,pin-function = <0>;
> +               samsung,pin-pud = <0>;
> +               samsung,pin-drv = <0>;
> +       };
> +
> +       hdmi_hpd_irq: hdmi-hpd-irq {
> +               samsung,pins = "gpx3-7";
> +               samsung,pin-function = <0>;
> +               samsung,pin-pud = <1>;
> +               samsung,pin-drv = <0>;
> +       };
> +};
> +
> +&pinctrl_1 {
> +       hsic_reset: hsic-reset {
> +               samsung,pins = "gpe1-0";
> +               samsung,pin-function = <1>;
> +               samsung,pin-pud = <0>;
> +               samsung,pin-drv = <0>;
> +       };
> +};
> +
> +&sd1_clk {
> +       samsung,pin-drv = <0>;
> +};
> +
> +&sd1_cmd {
> +       samsung,pin-pud = <3>;
> +       samsung,pin-drv = <0>;
> +};
> +
> +&sd1_cd {
> +       samsung,pin-drv = <0>;
> +};
> +
> +&sd1_bus4 {
> +       samsung,pin-drv = <0>;
> +};
> +
> +&spi_1 {
> +       status = "okay";
> +       samsung,spi-src-clk = <0>;
> +       num-cs = <1>;
> +};
> +
> +&usbdrd_phy {
> +       vbus-supply = <&usb3_vbus_reg>;
> +};
> +
> +#include "cros-ec-keyboard.dtsi"
> --
> 1.9.3
>

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

* [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
@ 2014-07-31 17:00     ` Vincent Palatin
  0 siblings, 0 replies; 61+ messages in thread
From: Vincent Palatin @ 2014-07-31 17:00 UTC (permalink / raw)
  To: linux-arm-kernel

Always a bit late to the game.
One small comment inline.

Reviewed-by: Vincent Palatin <vpalatin@chromium.org>

On Thu, Jul 31, 2014 at 9:08 AM, Andreas F?rber <afaerber@suse.de> wrote:
> Adds initial support for the HP Chromebook 11.
>
> Cc: Vincent Palatin <vpalatin@chromium.org>
> Cc: Doug Anderson <dianders@chromium.org>
> Cc: Stephan van Schaik <stephan@synkhronix.com>
> Signed-off-by: Andreas F?rber <afaerber@suse.de>
> ---
>  v3 -> v4:
>  * Fixed samsung,pin-function 1 -> 0 for dp-hpd-gpio
>  * Replaced dp-hpd-gpio with existing dp_hpd, overriding it
>
>  v2 -> v3:
>  * Use GPIO_ACTIVE_{LOW,HIGH} (Doug Anderson)
>  * Use symbolic KEY_POWER instead of comment
>  * Moved hsic_reset to new USB3503 node's reset-gpios (Vincent Palatin)
>  * Use dp_hpd_gpio for dp-controller (Doug Anderson, Ajay Kumar)
>  * Override sd1_{clk,cmd,cd,bus4} pinctrl similar to Snow (Doug Anderson)
>  * Added ec_irq pinctrl for cros_ec (Doug Anderson)
>  * Reordered nodes to minimize diff against Snow (Doug Anderson)
>  * Dropped obsolete mmc_2 override (Doug Anderson)
>  * Added lid-switch node (Doug Anderson)
>  * Added gpio-keys pinctrl (Doug Anderson)
>  * Added bootargs to avoid empty /chosen node and to document console setting
>  * Renamed s5m8767_pmic node to avoid underscore
>  * Use new style for overriding inherited pinctrl nodes, too
>  * Enable i2s0 node
>
>  v1 -> v2:
>  * Use label-based overriding/extension of nodes. (Doug Anderson)
>  * Dropped tps65090 for now, until we know where to place it.
>  * Dropped non-Spring nodes from -cros-common.dtsi rather than disabling them.
>  * Enabled a missing MMC node for access to internal storage.
>  * Dropped display-timings from dp-controller node. (Ajay Kumar)
>
>  arch/arm/boot/dts/Makefile              |   1 +
>  arch/arm/boot/dts/exynos5250-spring.dts | 539 ++++++++++++++++++++++++++++++++
>  2 files changed, 540 insertions(+)
>  create mode 100644 arch/arm/boot/dts/exynos5250-spring.dts
>
> diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
> index 80a781f76e88..dec4c292f63d 100644
> --- a/arch/arm/boot/dts/Makefile
> +++ b/arch/arm/boot/dts/Makefile
> @@ -76,6 +76,7 @@ dtb-$(CONFIG_ARCH_EXYNOS) += exynos4210-origen.dtb \
>         exynos5250-arndale.dtb \
>         exynos5250-smdk5250.dtb \
>         exynos5250-snow.dtb \
> +       exynos5250-spring.dtb \
>         exynos5260-xyref5260.dtb \
>         exynos5410-smdk5410.dtb \
>         exynos5420-arndale-octa.dtb \
> diff --git a/arch/arm/boot/dts/exynos5250-spring.dts b/arch/arm/boot/dts/exynos5250-spring.dts
> new file mode 100644
> index 000000000000..1fdfa04182fc
> --- /dev/null
> +++ b/arch/arm/boot/dts/exynos5250-spring.dts
> @@ -0,0 +1,539 @@
> +/*
> + * Google Spring board device tree source
> + *
> + * Copyright (c) 2013 Google, Inc
> + * Copyright (c) 2014 SUSE LINUX Products GmbH
> + *
> + * 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 <dt-bindings/gpio/gpio.h>
> +#include <dt-bindings/input/input.h>
> +#include "exynos5250.dtsi"
> +
> +/ {
> +       model = "Google Spring";
> +       compatible = "google,spring", "samsung,exynos5250", "samsung,exynos5";
> +
> +       memory {
> +               reg = <0x40000000 0x80000000>;
> +       };
> +
> +       chosen {
> +               bootargs = "console=tty1";
> +       };
> +
> +       gpio-keys {
> +               compatible = "gpio-keys";
> +               pinctrl-names = "default";
> +               pinctrl-0 = <&power_key_irq>, <&lid_irq>;
> +
> +               power {
> +                       label = "Power";
> +                       gpios = <&gpx1 3 GPIO_ACTIVE_LOW>;
> +                       linux,code = <KEY_POWER>;
> +                       gpio-key,wakeup;
> +               };
> +
> +               lid-switch {
> +                       label = "Lid";
> +                       gpios = <&gpx3 5 GPIO_ACTIVE_LOW>;
> +                       linux,input-type = <5>; /* EV_SW */
> +                       linux,code = <0>; /* SW_LID */
> +                       debounce-interval = <1>;
> +                       gpio-key,wakeup;
> +               };
> +       };
> +
> +       usb3_vbus_reg: regulator-usb3 {
> +               compatible = "regulator-fixed";
> +               regulator-name = "P5.0V_USB3CON";
> +               regulator-min-microvolt = <5000000>;
> +               regulator-max-microvolt = <5000000>;
> +               gpio = <&gpe1 0 GPIO_ACTIVE_LOW>;
> +               enable-active-high;
> +       };

GPE1_0 GPIO is the HSIC hub (SMSC 3503) reset# line (already defined
below afaik).
On this design there is no external USB3 port, so no VBUS reg/load
switch for USB3.



> +
> +       usb at 12110000 {
> +               samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
> +       };
> +
> +       usb-hub {
> +               compatible = "smsc,usb3503a";
> +               reset-gpios = <&hsic_reset>;
> +       };
> +
> +       fixed-rate-clocks {
> +               xxti {
> +                       compatible = "samsung,clock-xxti";
> +                       clock-frequency = <24000000>;
> +               };
> +       };
> +
> +       hdmi {
> +               hpd-gpio = <&gpx3 7 GPIO_ACTIVE_HIGH>;
> +               pinctrl-names = "default";
> +               pinctrl-0 = <&hdmi_hpd_irq>;
> +               phy = <&hdmiphy>;
> +               ddc = <&i2c_2>;
> +               hdmi-en-supply = <&s5m_ldo8_reg>;
> +               vdd-supply = <&s5m_ldo8_reg>;
> +               vdd_osc-supply = <&s5m_ldo10_reg>;
> +               vdd_pll-supply = <&s5m_ldo8_reg>;
> +       };
> +
> +       fimd at 14400000 {
> +               status = "okay";
> +               samsung,invert-vclk;
> +       };
> +
> +       dp-controller at 145B0000 {
> +               status = "okay";
> +               pinctrl-names = "default";
> +               pinctrl-0 = <&dp_hpd>;
> +               samsung,color-space = <0>;
> +               samsung,dynamic-range = <0>;
> +               samsung,ycbcr-coeff = <0>;
> +               samsung,color-depth = <1>;
> +               samsung,link-rate = <0x0a>;
> +               samsung,lane-count = <1>;
> +               samsung,hpd-gpio = <&gpc3 0 GPIO_ACTIVE_HIGH>;
> +       };
> +};
> +
> +&dp_hpd {
> +       samsung,pins = "gpc3-0";
> +       samsung,pin-function = <0>;
> +       samsung,pin-pud = <3>;
> +       samsung,pin-drv = <0>;
> +};
> +
> +&i2c_0 {
> +       status = "okay";
> +       samsung,i2c-sda-delay = <100>;
> +       samsung,i2c-max-bus-freq = <378000>;
> +
> +       s5m8767-pmic at 66 {
> +               compatible = "samsung,s5m8767-pmic";
> +               reg = <0x66>;
> +               interrupt-parent = <&gpx3>;
> +               interrupts = <2 0>;
> +               pinctrl-names = "default";
> +               pinctrl-0 = <&s5m8767_irq &s5m8767_dvs &s5m8767_ds>;
> +               wakeup-source;
> +
> +               s5m8767,pmic-buck-dvs-gpios = <&gpd1 0 GPIO_ACTIVE_LOW>, /* DVS1 */
> +                                             <&gpd1 1 GPIO_ACTIVE_LOW>, /* DVS2 */
> +                                             <&gpd1 2 GPIO_ACTIVE_LOW>; /* DVS3 */
> +
> +               s5m8767,pmic-buck-ds-gpios = <&gpx2 3 GPIO_ACTIVE_LOW>, /* SET1 */
> +                                            <&gpx2 4 GPIO_ACTIVE_LOW>, /* SET2 */
> +                                            <&gpx2 5 GPIO_ACTIVE_LOW>; /* SET3 */
> +
> +               /*
> +                * The following arrays of DVS voltages are not used, since we are
> +                * not using GPIOs to control PMIC bucks, but they must be defined
> +                * to please the driver.
> +                */
> +               s5m8767,pmic-buck2-dvs-voltage = <1350000>, <1300000>,
> +                                                <1250000>, <1200000>,
> +                                                <1150000>, <1100000>,
> +                                                <1000000>, <950000>;
> +
> +               s5m8767,pmic-buck3-dvs-voltage = <1100000>, <1100000>,
> +                                                <1100000>, <1100000>,
> +                                                <1000000>, <1000000>,
> +                                                <1000000>, <1000000>;
> +
> +               s5m8767,pmic-buck4-dvs-voltage = <1200000>, <1200000>,
> +                                                <1200000>, <1200000>,
> +                                                <1200000>, <1200000>,
> +                                                <1200000>, <1200000>;
> +
> +               clocks {
> +                       compatible = "samsung,s5m8767-clk";
> +                       #clock-cells = <1>;
> +                       clock-output-names = "en32khz_ap",
> +                                            "en32khz_cp",
> +                                            "en32khz_bt";
> +               };
> +
> +               regulators {
> +                       s5m_ldo4_reg: LDO4 {
> +                               regulator-name = "P1.0V_LDO_OUT4";
> +                               regulator-min-microvolt = <1000000>;
> +                               regulator-max-microvolt = <1000000>;
> +                               regulator-always-on;
> +                               op_mode = <0>;
> +                       };
> +
> +                       s5m_ldo5_reg: LDO5 {
> +                               regulator-name = "P1.0V_LDO_OUT5";
> +                               regulator-min-microvolt = <1000000>;
> +                               regulator-max-microvolt = <1000000>;
> +                               regulator-always-on;
> +                               op_mode = <0>;
> +                       };
> +
> +                       s5m_ldo6_reg: LDO6 {
> +                               regulator-name = "vdd_mydp";
> +                               regulator-min-microvolt = <1000000>;
> +                               regulator-max-microvolt = <1000000>;
> +                               regulator-always-on;
> +                               op_mode = <3>;
> +                       };
> +
> +                       s5m_ldo7_reg: LDO7 {
> +                               regulator-name = "P1.1V_LDO_OUT7";
> +                               regulator-min-microvolt = <1100000>;
> +                               regulator-max-microvolt = <1100000>;
> +                               regulator-always-on;
> +                               op_mode = <3>;
> +                       };
> +
> +                       s5m_ldo8_reg: LDO8 {
> +                               regulator-name = "P1.0V_LDO_OUT8";
> +                               regulator-min-microvolt = <1000000>;
> +                               regulator-max-microvolt = <1000000>;
> +                               regulator-always-on;
> +                               op_mode = <3>;
> +                       };
> +
> +                       s5m_ldo10_reg: LDO10 {
> +                               regulator-name = "P1.8V_LDO_OUT10";
> +                               regulator-min-microvolt = <1800000>;
> +                               regulator-max-microvolt = <1800000>;
> +                               regulator-always-on;
> +                               op_mode = <3>;
> +                       };
> +
> +                       s5m_ldo11_reg: LDO11 {
> +                               regulator-name = "P1.8V_LDO_OUT11";
> +                               regulator-min-microvolt = <1800000>;
> +                               regulator-max-microvolt = <1800000>;
> +                               regulator-always-on;
> +                               op_mode = <0>;
> +                       };
> +
> +                       s5m_ldo12_reg: LDO12 {
> +                               regulator-name = "P3.0V_LDO_OUT12";
> +                               regulator-min-microvolt = <3000000>;
> +                               regulator-max-microvolt = <3000000>;
> +                               regulator-always-on;
> +                               op_mode = <3>;
> +                       };
> +
> +                       s5m_ldo13_reg: LDO13 {
> +                               regulator-name = "P1.8V_LDO_OUT13";
> +                               regulator-min-microvolt = <1800000>;
> +                               regulator-max-microvolt = <1800000>;
> +                               regulator-always-on;
> +                               op_mode = <0>;
> +                       };
> +
> +                       s5m_ldo14_reg: LDO14 {
> +                               regulator-name = "P1.8V_LDO_OUT14";
> +                               regulator-min-microvolt = <1800000>;
> +                               regulator-max-microvolt = <1800000>;
> +                               regulator-always-on;
> +                               op_mode = <3>;
> +                       };
> +
> +                       s5m_ldo15_reg: LDO15 {
> +                               regulator-name = "P1.0V_LDO_OUT15";
> +                               regulator-min-microvolt = <1000000>;
> +                               regulator-max-microvolt = <1000000>;
> +                               regulator-always-on;
> +                               op_mode = <3>;
> +                       };
> +
> +                       s5m_ldo16_reg: LDO16 {
> +                               regulator-name = "P1.8V_LDO_OUT16";
> +                               regulator-min-microvolt = <1800000>;
> +                               regulator-max-microvolt = <1800000>;
> +                               regulator-always-on;
> +                               op_mode = <3>;
> +                       };
> +
> +                       s5m_ldo17_reg: LDO17 {
> +                               regulator-name = "P2.8V_LDO_OUT17";
> +                               regulator-min-microvolt = <2800000>;
> +                               regulator-max-microvolt = <2800000>;
> +                               regulator-always-on;
> +                               op_mode = <0>;
> +                       };
> +
> +                       s5m_ldo25_reg: LDO25 {
> +                               regulator-name = "vdd_bridge";
> +                               regulator-min-microvolt = <1200000>;
> +                               regulator-max-microvolt = <1200000>;
> +                               regulator-always-on;
> +                               op_mode = <1>;
> +                       };
> +
> +                       BUCK1 {
> +                               regulator-name = "vdd_mif";
> +                               regulator-min-microvolt = <950000>;
> +                               regulator-max-microvolt = <1300000>;
> +                               regulator-always-on;
> +                               regulator-boot-on;
> +                               op_mode = <3>;
> +                       };
> +
> +                       BUCK2 {
> +                               regulator-name = "vdd_arm";
> +                               regulator-min-microvolt = <850000>;
> +                               regulator-max-microvolt = <1350000>;
> +                               regulator-always-on;
> +                               regulator-boot-on;
> +                               op_mode = <3>;
> +                       };
> +
> +                       BUCK3 {
> +                               regulator-name = "vdd_int";
> +                               regulator-min-microvolt = <900000>;
> +                               regulator-max-microvolt = <1200000>;
> +                               regulator-always-on;
> +                               regulator-boot-on;
> +                               op_mode = <3>;
> +                       };
> +
> +                       BUCK4 {
> +                               regulator-name = "vdd_g3d";
> +                               regulator-min-microvolt = <850000>;
> +                               regulator-max-microvolt = <1300000>;
> +                               regulator-boot-on;
> +                               op_mode = <3>;
> +                       };
> +
> +                       BUCK5 {
> +                               regulator-name = "P1.8V_BUCK_OUT5";
> +                               regulator-min-microvolt = <1800000>;
> +                               regulator-max-microvolt = <1800000>;
> +                               regulator-always-on;
> +                               regulator-boot-on;
> +                               op_mode = <1>;
> +                       };
> +
> +                       BUCK6 {
> +                               regulator-name = "P1.2V_BUCK_OUT6";
> +                               regulator-min-microvolt = <1200000>;
> +                               regulator-max-microvolt = <1200000>;
> +                               regulator-always-on;
> +                               regulator-boot-on;
> +                               op_mode = <0>;
> +                       };
> +
> +                       BUCK9 {
> +                               regulator-name = "vdd_ummc";
> +                               regulator-min-microvolt = <950000>;
> +                               regulator-max-microvolt = <3000000>;
> +                               regulator-always-on;
> +                               regulator-boot-on;
> +                               op_mode = <3>;
> +                       };
> +               };
> +       };
> +};
> +
> +&i2c_1 {
> +       status = "okay";
> +       samsung,i2c-sda-delay = <100>;
> +       samsung,i2c-max-bus-freq = <378000>;
> +};
> +
> +/*
> + * Disabled pullups since external part has its own pullups and
> + * double-pulling gets us out of spec in some cases.
> + */
> +&i2c2_bus {
> +       samsung,pin-pud = <0>;
> +};
> +
> +&i2c_2 {
> +       status = "okay";
> +       samsung,i2c-sda-delay = <100>;
> +       samsung,i2c-max-bus-freq = <66000>;
> +
> +       hdmiddc at 50 {
> +               compatible = "samsung,exynos4210-hdmiddc";
> +               reg = <0x50>;
> +       };
> +};
> +
> +&i2c_3 {
> +       status = "okay";
> +       samsung,i2c-sda-delay = <100>;
> +       samsung,i2c-max-bus-freq = <66000>;
> +};
> +
> +&i2c_4 {
> +       status = "okay";
> +       samsung,i2c-sda-delay = <100>;
> +       samsung,i2c-max-bus-freq = <66000>;
> +
> +       cros_ec: embedded-controller {
> +               compatible = "google,cros-ec-i2c";
> +               reg = <0x1e>;
> +               interrupts = <6 0>;
> +               interrupt-parent = <&gpx1>;
> +               wakeup-source;
> +               pinctrl-names = "default";
> +               pinctrl-0 = <&ec_irq>;
> +       };
> +};
> +
> +&i2c_5 {
> +       status = "okay";
> +       samsung,i2c-sda-delay = <100>;
> +       samsung,i2c-max-bus-freq = <66000>;
> +};
> +
> +&i2c_7 {
> +       status = "okay";
> +       samsung,i2c-sda-delay = <100>;
> +       samsung,i2c-max-bus-freq = <66000>;
> +};
> +
> +&i2c_8 {
> +       status = "okay";
> +       samsung,i2c-sda-delay = <100>;
> +       samsung,i2c-max-bus-freq = <378000>;
> +
> +       hdmiphy: hdmiphy at 38 {
> +               compatible = "samsung,exynos4212-hdmiphy";
> +               reg = <0x38>;
> +       };
> +};
> +
> +&i2s0 {
> +       status = "okay";
> +};
> +
> +&mmc_0 {
> +       status = "okay";
> +       num-slots = <1>;
> +       supports-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>;
> +       pinctrl-names = "default";
> +       pinctrl-0 = <&sd0_clk &sd0_cmd &sd0_cd &sd0_bus4 &sd0_bus8>;
> +
> +       slot at 0 {
> +               reg = <0>;
> +               bus-width = <8>;
> +       };
> +};
> +
> +&mmc_1 {
> +       status = "okay";
> +       num-slots = <1>;
> +       supports-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>;
> +       pinctrl-names = "default";
> +       pinctrl-0 = <&sd1_clk &sd1_cmd &sd1_cd &sd1_bus4>;
> +
> +       slot at 0 {
> +               reg = <0>;
> +               bus-width = <4>;
> +       };
> +};
> +
> +&pinctrl_0 {
> +       s5m8767_dvs: s5m8767-dvs {
> +               samsung,pins = "gpd1-0", "gpd1-1", "gpd1-2";
> +               samsung,pin-function = <0>;
> +               samsung,pin-pud = <1>;
> +               samsung,pin-drv = <0>;
> +       };
> +
> +       power_key_irq: power-key-irq {
> +               samsung,pins = "gpx1-3";
> +               samsung,pin-function = <0>;
> +               samsung,pin-pud = <0>;
> +               samsung,pin-drv = <0>;
> +       };
> +
> +       ec_irq: ec-irq {
> +               samsung,pins = "gpx1-6";
> +               samsung,pin-function = <0>;
> +               samsung,pin-pud = <0>;
> +               samsung,pin-drv = <0>;
> +       };
> +
> +       s5m8767_ds: s5m8767-ds {
> +               samsung,pins = "gpx2-3", "gpx2-4", "gpx2-5";
> +               samsung,pin-function = <0>;
> +               samsung,pin-pud = <1>;
> +               samsung,pin-drv = <0>;
> +       };
> +
> +       s5m8767_irq: s5m8767-irq {
> +               samsung,pins = "gpx3-2";
> +               samsung,pin-function = <0>;
> +               samsung,pin-pud = <0>;
> +               samsung,pin-drv = <0>;
> +       };
> +
> +       lid_irq: lid-irq {
> +               samsung,pins = "gpx3-5";
> +               samsung,pin-function = <0>;
> +               samsung,pin-pud = <0>;
> +               samsung,pin-drv = <0>;
> +       };
> +
> +       hdmi_hpd_irq: hdmi-hpd-irq {
> +               samsung,pins = "gpx3-7";
> +               samsung,pin-function = <0>;
> +               samsung,pin-pud = <1>;
> +               samsung,pin-drv = <0>;
> +       };
> +};
> +
> +&pinctrl_1 {
> +       hsic_reset: hsic-reset {
> +               samsung,pins = "gpe1-0";
> +               samsung,pin-function = <1>;
> +               samsung,pin-pud = <0>;
> +               samsung,pin-drv = <0>;
> +       };
> +};
> +
> +&sd1_clk {
> +       samsung,pin-drv = <0>;
> +};
> +
> +&sd1_cmd {
> +       samsung,pin-pud = <3>;
> +       samsung,pin-drv = <0>;
> +};
> +
> +&sd1_cd {
> +       samsung,pin-drv = <0>;
> +};
> +
> +&sd1_bus4 {
> +       samsung,pin-drv = <0>;
> +};
> +
> +&spi_1 {
> +       status = "okay";
> +       samsung,spi-src-clk = <0>;
> +       num-cs = <1>;
> +};
> +
> +&usbdrd_phy {
> +       vbus-supply = <&usb3_vbus_reg>;
> +};
> +
> +#include "cros-ec-keyboard.dtsi"
> --
> 1.9.3
>

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

* Re: [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
  2014-07-31 17:00     ` Vincent Palatin
@ 2014-07-31 17:14       ` Andreas Färber
  -1 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 17:14 UTC (permalink / raw)
  To: Vincent Palatin
  Cc: linux-samsung-soc, ARM PORT, OPEN FIRMWARE AND...,
	Stephan van Schaik, Doug Anderson, Javier Martinez Canillas,
	Rob Herring, Pawel Moll, Mark Rutland, Ian Campbell, Kumar Gala,
	Russell King, Ben Dooks, Kukjin Kim, LKML

Hi,

Am 31.07.2014 19:00, schrieb Vincent Palatin:
> Always a bit late to the game.
> One small comment inline.
> 
> Reviewed-by: Vincent Palatin <vpalatin@chromium.org>

Thanks,

> 
> On Thu, Jul 31, 2014 at 9:08 AM, Andreas Färber <afaerber@suse.de> wrote:
>> +       usb3_vbus_reg: regulator-usb3 {
>> +               compatible = "regulator-fixed";
>> +               regulator-name = "P5.0V_USB3CON";
>> +               regulator-min-microvolt = <5000000>;
>> +               regulator-max-microvolt = <5000000>;
>> +               gpio = <&gpe1 0 GPIO_ACTIVE_LOW>;
>> +               enable-active-high;
>> +       };
> 
> GPE1_0 GPIO is the HSIC hub (SMSC 3503) reset# line (already defined
> below afaik).

Yes, that was a suggestion you made on v1.

> On this design there is no external USB3 port, so no VBUS reg/load
> switch for USB3.

Could you be a little clearer? Are you suggesting to drop the gpio
property? I just re-tested that without the regulator node plus the
vbus-supply below I don't get any USB2 (so maybe rename the regulator?).

Regards,
Andreas

>> +
>> +       usb@12110000 {
>> +               samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
>> +       };
>> +
>> +       usb-hub {
>> +               compatible = "smsc,usb3503a";
>> +               reset-gpios = <&hsic_reset>;
>> +       };
[...]
>> +&usbdrd_phy {
>> +       vbus-supply = <&usb3_vbus_reg>;
>> +};
>> +
>> +#include "cros-ec-keyboard.dtsi"
>> --
>> 1.9.3

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg

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

* [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
@ 2014-07-31 17:14       ` Andreas Färber
  0 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 17:14 UTC (permalink / raw)
  To: linux-arm-kernel

Hi,

Am 31.07.2014 19:00, schrieb Vincent Palatin:
> Always a bit late to the game.
> One small comment inline.
> 
> Reviewed-by: Vincent Palatin <vpalatin@chromium.org>

Thanks,

> 
> On Thu, Jul 31, 2014 at 9:08 AM, Andreas F?rber <afaerber@suse.de> wrote:
>> +       usb3_vbus_reg: regulator-usb3 {
>> +               compatible = "regulator-fixed";
>> +               regulator-name = "P5.0V_USB3CON";
>> +               regulator-min-microvolt = <5000000>;
>> +               regulator-max-microvolt = <5000000>;
>> +               gpio = <&gpe1 0 GPIO_ACTIVE_LOW>;
>> +               enable-active-high;
>> +       };
> 
> GPE1_0 GPIO is the HSIC hub (SMSC 3503) reset# line (already defined
> below afaik).

Yes, that was a suggestion you made on v1.

> On this design there is no external USB3 port, so no VBUS reg/load
> switch for USB3.

Could you be a little clearer? Are you suggesting to drop the gpio
property? I just re-tested that without the regulator node plus the
vbus-supply below I don't get any USB2 (so maybe rename the regulator?).

Regards,
Andreas

>> +
>> +       usb at 12110000 {
>> +               samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
>> +       };
>> +
>> +       usb-hub {
>> +               compatible = "smsc,usb3503a";
>> +               reset-gpios = <&hsic_reset>;
>> +       };
[...]
>> +&usbdrd_phy {
>> +       vbus-supply = <&usb3_vbus_reg>;
>> +};
>> +
>> +#include "cros-ec-keyboard.dtsi"
>> --
>> 1.9.3

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 N?rnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imend?rffer; HRB 16746 AG N?rnberg

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

* Re: [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
  2014-07-31 17:14       ` Andreas Färber
@ 2014-07-31 17:38         ` Andreas Färber
  -1 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 17:38 UTC (permalink / raw)
  To: Vincent Palatin
  Cc: linux-samsung-soc, ARM PORT, OPEN FIRMWARE AND...,
	Stephan van Schaik, Doug Anderson, Javier Martinez Canillas,
	Rob Herring, Pawel Moll, Mark Rutland, Ian Campbell, Kumar Gala,
	Russell King, Ben Dooks, Kukjin Kim, LKML

Am 31.07.2014 19:14, schrieb Andreas Färber:
> Hi,
> 
> Am 31.07.2014 19:00, schrieb Vincent Palatin:
>> Always a bit late to the game.
>> One small comment inline.
>>
>> Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
> 
> Thanks,
> 
>>
>> On Thu, Jul 31, 2014 at 9:08 AM, Andreas Färber <afaerber@suse.de> wrote:
>>> +       usb3_vbus_reg: regulator-usb3 {
>>> +               compatible = "regulator-fixed";
>>> +               regulator-name = "P5.0V_USB3CON";
>>> +               regulator-min-microvolt = <5000000>;
>>> +               regulator-max-microvolt = <5000000>;
>>> +               gpio = <&gpe1 0 GPIO_ACTIVE_LOW>;
>>> +               enable-active-high;
>>> +       };
>>
>> GPE1_0 GPIO is the HSIC hub (SMSC 3503) reset# line (already defined
>> below afaik).
> 
> Yes, that was a suggestion you made on v1.
> 
>> On this design there is no external USB3 port, so no VBUS reg/load
>> switch for USB3.
> 
> Could you be a little clearer? Are you suggesting to drop the gpio
> property?

Nah, doesn't work. Do we need a pinctrl on the usb-hub instead?

Andreas

> I just re-tested that without the regulator node plus the
> vbus-supply below I don't get any USB2 (so maybe rename the regulator?).
> 
> Regards,
> Andreas
> 
>>> +
>>> +       usb@12110000 {
>>> +               samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
>>> +       };
>>> +
>>> +       usb-hub {
>>> +               compatible = "smsc,usb3503a";
>>> +               reset-gpios = <&hsic_reset>;
>>> +       };
> [...]
>>> +&usbdrd_phy {
>>> +       vbus-supply = <&usb3_vbus_reg>;
>>> +};
>>> +
>>> +#include "cros-ec-keyboard.dtsi"
>>> --
>>> 1.9.3
> 


-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg

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

* [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
@ 2014-07-31 17:38         ` Andreas Färber
  0 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 17:38 UTC (permalink / raw)
  To: linux-arm-kernel

Am 31.07.2014 19:14, schrieb Andreas F?rber:
> Hi,
> 
> Am 31.07.2014 19:00, schrieb Vincent Palatin:
>> Always a bit late to the game.
>> One small comment inline.
>>
>> Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
> 
> Thanks,
> 
>>
>> On Thu, Jul 31, 2014 at 9:08 AM, Andreas F?rber <afaerber@suse.de> wrote:
>>> +       usb3_vbus_reg: regulator-usb3 {
>>> +               compatible = "regulator-fixed";
>>> +               regulator-name = "P5.0V_USB3CON";
>>> +               regulator-min-microvolt = <5000000>;
>>> +               regulator-max-microvolt = <5000000>;
>>> +               gpio = <&gpe1 0 GPIO_ACTIVE_LOW>;
>>> +               enable-active-high;
>>> +       };
>>
>> GPE1_0 GPIO is the HSIC hub (SMSC 3503) reset# line (already defined
>> below afaik).
> 
> Yes, that was a suggestion you made on v1.
> 
>> On this design there is no external USB3 port, so no VBUS reg/load
>> switch for USB3.
> 
> Could you be a little clearer? Are you suggesting to drop the gpio
> property?

Nah, doesn't work. Do we need a pinctrl on the usb-hub instead?

Andreas

> I just re-tested that without the regulator node plus the
> vbus-supply below I don't get any USB2 (so maybe rename the regulator?).
> 
> Regards,
> Andreas
> 
>>> +
>>> +       usb at 12110000 {
>>> +               samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
>>> +       };
>>> +
>>> +       usb-hub {
>>> +               compatible = "smsc,usb3503a";
>>> +               reset-gpios = <&hsic_reset>;
>>> +       };
> [...]
>>> +&usbdrd_phy {
>>> +       vbus-supply = <&usb3_vbus_reg>;
>>> +};
>>> +
>>> +#include "cros-ec-keyboard.dtsi"
>>> --
>>> 1.9.3
> 


-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 N?rnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imend?rffer; HRB 16746 AG N?rnberg

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

* Re: [PATCH v4 1/4] ARM: dts: Fix MMC pinctrl for exynos5250-snow
  2014-07-31 16:08   ` Andreas Färber
@ 2014-07-31 18:41     ` Kukjin Kim
  -1 siblings, 0 replies; 61+ messages in thread
From: Kukjin Kim @ 2014-07-31 18:41 UTC (permalink / raw)
  To: Andreas Färber
  Cc: linux-samsung-soc, Mark Rutland, devicetree, Kukjin Kim,
	Vincent Palatin, Pawel Moll, Ian Campbell, open list, Kumar Gala,
	Stephan van Schaik, Doug Anderson, Jaehoon Chung, Rob Herring,
	Ben Dooks, Russell King, Javier Martinez Canillas,
	linux-arm-kernel

On 08/01/14 01:08, Andreas Färber wrote:
> The pinctrl properties should be on the device directly and not on the
> slot sub-node.
>
> Reported-by: Doug Anderson<dianders@chromium.org>
> Cc: Jaehoon Chung<jh80.chung@samsung.com>
> Signed-off-by: Andreas Färber<afaerber@suse.de>
> ---
>   v3 ->  v4: Unchanged
>
>   v3: New (Doug Anderson)
>   Redundant with Jaehoon Chung's general slot@0 deprecation,
>   in case that hits the tree earlier.
>
>   arch/arm/boot/dts/exynos5250-snow.dts | 6 ++----
>   1 file changed, 2 insertions(+), 4 deletions(-)
>
> diff --git a/arch/arm/boot/dts/exynos5250-snow.dts b/arch/arm/boot/dts/exynos5250-snow.dts
> index f2b8c4116541..eb437f6afec1 100644
> --- a/arch/arm/boot/dts/exynos5250-snow.dts
> +++ b/arch/arm/boot/dts/exynos5250-snow.dts
> @@ -240,10 +240,8 @@
>   	 */
>   	mmc@12230000 {
>   		status = "okay";
> -		slot@0 {
> -			pinctrl-names = "default";
> -			pinctrl-0 =<&sd3_clk&sd3_cmd&sd3_bus4>;
> -		};
> +		pinctrl-names = "default";
> +		pinctrl-0 =<&sd3_clk&sd3_cmd&sd3_bus4>;
>   	};
>
>   	i2c@12CD0000 {

Once I get Doug's reviewed tag on exynos5250-snow dt changes, I will 
take this series :) Though Doug suggested or reported...

Thanks,
Kukjin

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

* [PATCH v4 1/4] ARM: dts: Fix MMC pinctrl for exynos5250-snow
@ 2014-07-31 18:41     ` Kukjin Kim
  0 siblings, 0 replies; 61+ messages in thread
From: Kukjin Kim @ 2014-07-31 18:41 UTC (permalink / raw)
  To: linux-arm-kernel

On 08/01/14 01:08, Andreas F?rber wrote:
> The pinctrl properties should be on the device directly and not on the
> slot sub-node.
>
> Reported-by: Doug Anderson<dianders@chromium.org>
> Cc: Jaehoon Chung<jh80.chung@samsung.com>
> Signed-off-by: Andreas F?rber<afaerber@suse.de>
> ---
>   v3 ->  v4: Unchanged
>
>   v3: New (Doug Anderson)
>   Redundant with Jaehoon Chung's general slot at 0 deprecation,
>   in case that hits the tree earlier.
>
>   arch/arm/boot/dts/exynos5250-snow.dts | 6 ++----
>   1 file changed, 2 insertions(+), 4 deletions(-)
>
> diff --git a/arch/arm/boot/dts/exynos5250-snow.dts b/arch/arm/boot/dts/exynos5250-snow.dts
> index f2b8c4116541..eb437f6afec1 100644
> --- a/arch/arm/boot/dts/exynos5250-snow.dts
> +++ b/arch/arm/boot/dts/exynos5250-snow.dts
> @@ -240,10 +240,8 @@
>   	 */
>   	mmc at 12230000 {
>   		status = "okay";
> -		slot at 0 {
> -			pinctrl-names = "default";
> -			pinctrl-0 =<&sd3_clk&sd3_cmd&sd3_bus4>;
> -		};
> +		pinctrl-names = "default";
> +		pinctrl-0 =<&sd3_clk&sd3_cmd&sd3_bus4>;
>   	};
>
>   	i2c at 12CD0000 {

Once I get Doug's reviewed tag on exynos5250-snow dt changes, I will 
take this series :) Though Doug suggested or reported...

Thanks,
Kukjin

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

* Re: [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
  2014-07-31 17:14       ` Andreas Färber
@ 2014-07-31 18:51         ` Vincent Palatin
  -1 siblings, 0 replies; 61+ messages in thread
From: Vincent Palatin @ 2014-07-31 18:51 UTC (permalink / raw)
  To: Andreas Färber
  Cc: linux-samsung-soc, ARM PORT, OPEN FIRMWARE AND...,
	Stephan van Schaik, Doug Anderson, Javier Martinez Canillas,
	Rob Herring, Pawel Moll, Mark Rutland, Ian Campbell, Kumar Gala,
	Russell King, Ben Dooks, Kukjin Kim, LKML

On Thu, Jul 31, 2014 at 10:14 AM, Andreas Färber <afaerber@suse.de> wrote:
> Hi,
>
> Am 31.07.2014 19:00, schrieb Vincent Palatin:
>> Always a bit late to the game.
>> One small comment inline.
>>
>> Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
>
> Thanks,
>
>>
>> On Thu, Jul 31, 2014 at 9:08 AM, Andreas Färber <afaerber@suse.de> wrote:
>>> +       usb3_vbus_reg: regulator-usb3 {
>>> +               compatible = "regulator-fixed";
>>> +               regulator-name = "P5.0V_USB3CON";
>>> +               regulator-min-microvolt = <5000000>;
>>> +               regulator-max-microvolt = <5000000>;
>>> +               gpio = <&gpe1 0 GPIO_ACTIVE_LOW>;
>>> +               enable-active-high;
>>> +       };
>>
>> GPE1_0 GPIO is the HSIC hub (SMSC 3503) reset# line (already defined
>> below afaik).
>
> Yes, that was a suggestion you made on v1.
>
>> On this design there is no external USB3 port, so no VBUS reg/load
>> switch for USB3.
>
> Could you be a little clearer? Are you suggesting to drop the gpio
> property? I just re-tested that without the regulator node plus the
> vbus-supply below I don't get any USB2 (so maybe rename the regulator?).

The 3503 PHY driver is not fully correct, so we probably need to keep
this to get the right init timings when the bootloader has initiliazed
it before.
but yes renaming the regulator to mention that's actually the hsic hub
reset would make it clearer.


>>> +
>>> +       usb@12110000 {
>>> +               samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
>>> +       };
>>> +
>>> +       usb-hub {
>>> +               compatible = "smsc,usb3503a";
>>> +               reset-gpios = <&hsic_reset>;
>>> +       };
> [...]
>>> +&usbdrd_phy {
>>> +       vbus-supply = <&usb3_vbus_reg>;
>>> +};
>>> +
>>> +#include "cros-ec-keyboard.dtsi"
>>> --
>>> 1.9.3
>
> --
> SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
> GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg

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

* [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
@ 2014-07-31 18:51         ` Vincent Palatin
  0 siblings, 0 replies; 61+ messages in thread
From: Vincent Palatin @ 2014-07-31 18:51 UTC (permalink / raw)
  To: linux-arm-kernel

On Thu, Jul 31, 2014 at 10:14 AM, Andreas F?rber <afaerber@suse.de> wrote:
> Hi,
>
> Am 31.07.2014 19:00, schrieb Vincent Palatin:
>> Always a bit late to the game.
>> One small comment inline.
>>
>> Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
>
> Thanks,
>
>>
>> On Thu, Jul 31, 2014 at 9:08 AM, Andreas F?rber <afaerber@suse.de> wrote:
>>> +       usb3_vbus_reg: regulator-usb3 {
>>> +               compatible = "regulator-fixed";
>>> +               regulator-name = "P5.0V_USB3CON";
>>> +               regulator-min-microvolt = <5000000>;
>>> +               regulator-max-microvolt = <5000000>;
>>> +               gpio = <&gpe1 0 GPIO_ACTIVE_LOW>;
>>> +               enable-active-high;
>>> +       };
>>
>> GPE1_0 GPIO is the HSIC hub (SMSC 3503) reset# line (already defined
>> below afaik).
>
> Yes, that was a suggestion you made on v1.
>
>> On this design there is no external USB3 port, so no VBUS reg/load
>> switch for USB3.
>
> Could you be a little clearer? Are you suggesting to drop the gpio
> property? I just re-tested that without the regulator node plus the
> vbus-supply below I don't get any USB2 (so maybe rename the regulator?).

The 3503 PHY driver is not fully correct, so we probably need to keep
this to get the right init timings when the bootloader has initiliazed
it before.
but yes renaming the regulator to mention that's actually the hsic hub
reset would make it clearer.


>>> +
>>> +       usb at 12110000 {
>>> +               samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
>>> +       };
>>> +
>>> +       usb-hub {
>>> +               compatible = "smsc,usb3503a";
>>> +               reset-gpios = <&hsic_reset>;
>>> +       };
> [...]
>>> +&usbdrd_phy {
>>> +       vbus-supply = <&usb3_vbus_reg>;
>>> +};
>>> +
>>> +#include "cros-ec-keyboard.dtsi"
>>> --
>>> 1.9.3
>
> --
> SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 N?rnberg, Germany
> GF: Jeff Hawn, Jennifer Guild, Felix Imend?rffer; HRB 16746 AG N?rnberg

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

* Re: [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
@ 2014-07-31 19:05     ` Tomasz Figa
  0 siblings, 0 replies; 61+ messages in thread
From: Tomasz Figa @ 2014-07-31 19:05 UTC (permalink / raw)
  To: Andreas Färber, linux-samsung-soc
  Cc: linux-arm-kernel, devicetree, Stephan van Schaik,
	Vincent Palatin, Doug Anderson, Javier Martinez Canillas,
	Rob Herring, Pawel Moll, Mark Rutland, Ian Campbell, Kumar Gala,
	Russell King, Ben Dooks, Kukjin Kim, open list

Hi Andreas,

Sorry for joining the party a bit late, but there were patches with less
people involved so I preferred to review them first.

You can find my comments inline.

On 31.07.2014 18:08, Andreas Färber wrote:
> Adds initial support for the HP Chromebook 11.

[snip]

> +	gpio-keys {
> +		compatible = "gpio-keys";
> +		pinctrl-names = "default";
> +		pinctrl-0 = <&power_key_irq>, <&lid_irq>;
> +
> +		power {
> +			label = "Power";
> +			gpios = <&gpx1 3 GPIO_ACTIVE_LOW>;
> +			linux,code = <KEY_POWER>;

I assume the key is debounced in hardware, so there is no need for
debounce-interval here. Is this correct?

> +			gpio-key,wakeup;
> +		};
> +
> +		lid-switch {
> +			label = "Lid";
> +			gpios = <&gpx3 5 GPIO_ACTIVE_LOW>;
> +			linux,input-type = <5>; /* EV_SW */
> +			linux,code = <0>; /* SW_LID */
> +			debounce-interval = <1>;
> +			gpio-key,wakeup;
> +		};
> +	};
> +
> +	usb3_vbus_reg: regulator-usb3 {
> +		compatible = "regulator-fixed";
> +		regulator-name = "P5.0V_USB3CON";
> +		regulator-min-microvolt = <5000000>;
> +		regulator-max-microvolt = <5000000>;
> +		gpio = <&gpe1 0 GPIO_ACTIVE_LOW>;
> +		enable-active-high;
> +	};
> +
> +	usb@12110000 {

Since this is a brand new dts file, it should use the reference based
syntax, which would be something like

&usbhost {
	...
};

below the / { ... }; block.

> +		samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
> +	};
> +
> +	usb-hub {
> +		compatible = "smsc,usb3503a";
> +		reset-gpios = <&hsic_reset>;

Hmm, why a -gpios property points to a pinctrl node? Shouldn't there be
a phandle to GPIO bank + GPIO specifier instead?

> +	};
> +
> +	fixed-rate-clocks {
> +		xxti {
> +			compatible = "samsung,clock-xxti";
> +			clock-frequency = <24000000>;
> +		};
> +	};

This is also referencing a node from higher level, so it should be done
using a reference.

> +
> +	hdmi {
> +		hpd-gpio = <&gpx3 7 GPIO_ACTIVE_HIGH>;
> +		pinctrl-names = "default";
> +		pinctrl-0 = <&hdmi_hpd_irq>;
> +		phy = <&hdmiphy>;
> +		ddc = <&i2c_2>;
> +		hdmi-en-supply = <&s5m_ldo8_reg>;
> +		vdd-supply = <&s5m_ldo8_reg>;
> +		vdd_osc-supply = <&s5m_ldo10_reg>;
> +		vdd_pll-supply = <&s5m_ldo8_reg>;
> +	};

Ditto.

> +
> +	fimd@14400000 {
> +		status = "okay";
> +		samsung,invert-vclk;
> +	};

Ditto.

> +
> +	dp-controller@145B0000 {
> +		status = "okay";
> +		pinctrl-names = "default";
> +		pinctrl-0 = <&dp_hpd>;
> +		samsung,color-space = <0>;
> +		samsung,dynamic-range = <0>;
> +		samsung,ycbcr-coeff = <0>;
> +		samsung,color-depth = <1>;
> +		samsung,link-rate = <0x0a>;
> +		samsung,lane-count = <1>;
> +		samsung,hpd-gpio = <&gpc3 0 GPIO_ACTIVE_HIGH>;
> +	};

Ditto.

> +};
> +
> +&dp_hpd {
> +	samsung,pins = "gpc3-0";
> +	samsung,pin-function = <0>;
> +	samsung,pin-pud = <3>;
> +	samsung,pin-drv = <0>;
> +};

Hmm, what node is this referencing? I believe this should rather
reference the pin controller and add a new board-specific pinconf/pinmux
group instead....

> +
> +&i2c_0 {
> +	status = "okay";
> +	samsung,i2c-sda-delay = <100>;
> +	samsung,i2c-max-bus-freq = <378000>;

[snip]

> +/*
> + * Disabled pullups since external part has its own pullups and
> + * double-pulling gets us out of spec in some cases.
> + */
> +&i2c2_bus {
> +	samsung,pin-pud = <0>;
> +};

OK, here overriding a generic pinconf group is justified and nicely
explained by a comment.

> +
> +&i2c_2 {
> +	status = "okay";
> +	samsung,i2c-sda-delay = <100>;
> +	samsung,i2c-max-bus-freq = <66000>;
> +
> +	hdmiddc@50 {
> +		compatible = "samsung,exynos4210-hdmiddc";
> +		reg = <0x50>;
> +	};

I don't think this matches current Exynos HDMI bindings, which I believe
have been changed to just take a phandle to i2c bus instead.

> +};
> +
> +&i2c_3 {
> +	status = "okay";
> +	samsung,i2c-sda-delay = <100>;
> +	samsung,i2c-max-bus-freq = <66000>;
> +};

[snip]

> +&sd1_clk {
> +	samsung,pin-drv = <0>;
> +};
> +
> +&sd1_cmd {
> +	samsung,pin-pud = <3>;
> +	samsung,pin-drv = <0>;
> +};
> +
> +&sd1_cd {
> +	samsung,pin-drv = <0>;
> +};
> +
> +&sd1_bus4 {
> +	samsung,pin-drv = <0>;
> +};

Here generic settings are being overridden, so it might be a good idea
to explain why, like with i2c pull-up above.

Best regards,
Tomasz

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

* Re: [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
@ 2014-07-31 19:05     ` Tomasz Figa
  0 siblings, 0 replies; 61+ messages in thread
From: Tomasz Figa @ 2014-07-31 19:05 UTC (permalink / raw)
  To: Andreas Färber, linux-samsung-soc-u79uwXL29TY76Z2rM5mHXA
  Cc: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
	devicetree-u79uwXL29TY76Z2rM5mHXA, Stephan van Schaik,
	Vincent Palatin, Doug Anderson, Javier Martinez Canillas,
	Rob Herring, Pawel Moll, Mark Rutland, Ian Campbell, Kumar Gala,
	Russell King, Ben Dooks, Kukjin Kim, open list

Hi Andreas,

Sorry for joining the party a bit late, but there were patches with less
people involved so I preferred to review them first.

You can find my comments inline.

On 31.07.2014 18:08, Andreas Färber wrote:
> Adds initial support for the HP Chromebook 11.

[snip]

> +	gpio-keys {
> +		compatible = "gpio-keys";
> +		pinctrl-names = "default";
> +		pinctrl-0 = <&power_key_irq>, <&lid_irq>;
> +
> +		power {
> +			label = "Power";
> +			gpios = <&gpx1 3 GPIO_ACTIVE_LOW>;
> +			linux,code = <KEY_POWER>;

I assume the key is debounced in hardware, so there is no need for
debounce-interval here. Is this correct?

> +			gpio-key,wakeup;
> +		};
> +
> +		lid-switch {
> +			label = "Lid";
> +			gpios = <&gpx3 5 GPIO_ACTIVE_LOW>;
> +			linux,input-type = <5>; /* EV_SW */
> +			linux,code = <0>; /* SW_LID */
> +			debounce-interval = <1>;
> +			gpio-key,wakeup;
> +		};
> +	};
> +
> +	usb3_vbus_reg: regulator-usb3 {
> +		compatible = "regulator-fixed";
> +		regulator-name = "P5.0V_USB3CON";
> +		regulator-min-microvolt = <5000000>;
> +		regulator-max-microvolt = <5000000>;
> +		gpio = <&gpe1 0 GPIO_ACTIVE_LOW>;
> +		enable-active-high;
> +	};
> +
> +	usb@12110000 {

Since this is a brand new dts file, it should use the reference based
syntax, which would be something like

&usbhost {
	...
};

below the / { ... }; block.

> +		samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
> +	};
> +
> +	usb-hub {
> +		compatible = "smsc,usb3503a";
> +		reset-gpios = <&hsic_reset>;

Hmm, why a -gpios property points to a pinctrl node? Shouldn't there be
a phandle to GPIO bank + GPIO specifier instead?

> +	};
> +
> +	fixed-rate-clocks {
> +		xxti {
> +			compatible = "samsung,clock-xxti";
> +			clock-frequency = <24000000>;
> +		};
> +	};

This is also referencing a node from higher level, so it should be done
using a reference.

> +
> +	hdmi {
> +		hpd-gpio = <&gpx3 7 GPIO_ACTIVE_HIGH>;
> +		pinctrl-names = "default";
> +		pinctrl-0 = <&hdmi_hpd_irq>;
> +		phy = <&hdmiphy>;
> +		ddc = <&i2c_2>;
> +		hdmi-en-supply = <&s5m_ldo8_reg>;
> +		vdd-supply = <&s5m_ldo8_reg>;
> +		vdd_osc-supply = <&s5m_ldo10_reg>;
> +		vdd_pll-supply = <&s5m_ldo8_reg>;
> +	};

Ditto.

> +
> +	fimd@14400000 {
> +		status = "okay";
> +		samsung,invert-vclk;
> +	};

Ditto.

> +
> +	dp-controller@145B0000 {
> +		status = "okay";
> +		pinctrl-names = "default";
> +		pinctrl-0 = <&dp_hpd>;
> +		samsung,color-space = <0>;
> +		samsung,dynamic-range = <0>;
> +		samsung,ycbcr-coeff = <0>;
> +		samsung,color-depth = <1>;
> +		samsung,link-rate = <0x0a>;
> +		samsung,lane-count = <1>;
> +		samsung,hpd-gpio = <&gpc3 0 GPIO_ACTIVE_HIGH>;
> +	};

Ditto.

> +};
> +
> +&dp_hpd {
> +	samsung,pins = "gpc3-0";
> +	samsung,pin-function = <0>;
> +	samsung,pin-pud = <3>;
> +	samsung,pin-drv = <0>;
> +};

Hmm, what node is this referencing? I believe this should rather
reference the pin controller and add a new board-specific pinconf/pinmux
group instead....

> +
> +&i2c_0 {
> +	status = "okay";
> +	samsung,i2c-sda-delay = <100>;
> +	samsung,i2c-max-bus-freq = <378000>;

[snip]

> +/*
> + * Disabled pullups since external part has its own pullups and
> + * double-pulling gets us out of spec in some cases.
> + */
> +&i2c2_bus {
> +	samsung,pin-pud = <0>;
> +};

OK, here overriding a generic pinconf group is justified and nicely
explained by a comment.

> +
> +&i2c_2 {
> +	status = "okay";
> +	samsung,i2c-sda-delay = <100>;
> +	samsung,i2c-max-bus-freq = <66000>;
> +
> +	hdmiddc@50 {
> +		compatible = "samsung,exynos4210-hdmiddc";
> +		reg = <0x50>;
> +	};

I don't think this matches current Exynos HDMI bindings, which I believe
have been changed to just take a phandle to i2c bus instead.

> +};
> +
> +&i2c_3 {
> +	status = "okay";
> +	samsung,i2c-sda-delay = <100>;
> +	samsung,i2c-max-bus-freq = <66000>;
> +};

[snip]

> +&sd1_clk {
> +	samsung,pin-drv = <0>;
> +};
> +
> +&sd1_cmd {
> +	samsung,pin-pud = <3>;
> +	samsung,pin-drv = <0>;
> +};
> +
> +&sd1_cd {
> +	samsung,pin-drv = <0>;
> +};
> +
> +&sd1_bus4 {
> +	samsung,pin-drv = <0>;
> +};

Here generic settings are being overridden, so it might be a good idea
to explain why, like with i2c pull-up above.

Best regards,
Tomasz
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
@ 2014-07-31 19:05     ` Tomasz Figa
  0 siblings, 0 replies; 61+ messages in thread
From: Tomasz Figa @ 2014-07-31 19:05 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Andreas,

Sorry for joining the party a bit late, but there were patches with less
people involved so I preferred to review them first.

You can find my comments inline.

On 31.07.2014 18:08, Andreas F?rber wrote:
> Adds initial support for the HP Chromebook 11.

[snip]

> +	gpio-keys {
> +		compatible = "gpio-keys";
> +		pinctrl-names = "default";
> +		pinctrl-0 = <&power_key_irq>, <&lid_irq>;
> +
> +		power {
> +			label = "Power";
> +			gpios = <&gpx1 3 GPIO_ACTIVE_LOW>;
> +			linux,code = <KEY_POWER>;

I assume the key is debounced in hardware, so there is no need for
debounce-interval here. Is this correct?

> +			gpio-key,wakeup;
> +		};
> +
> +		lid-switch {
> +			label = "Lid";
> +			gpios = <&gpx3 5 GPIO_ACTIVE_LOW>;
> +			linux,input-type = <5>; /* EV_SW */
> +			linux,code = <0>; /* SW_LID */
> +			debounce-interval = <1>;
> +			gpio-key,wakeup;
> +		};
> +	};
> +
> +	usb3_vbus_reg: regulator-usb3 {
> +		compatible = "regulator-fixed";
> +		regulator-name = "P5.0V_USB3CON";
> +		regulator-min-microvolt = <5000000>;
> +		regulator-max-microvolt = <5000000>;
> +		gpio = <&gpe1 0 GPIO_ACTIVE_LOW>;
> +		enable-active-high;
> +	};
> +
> +	usb at 12110000 {

Since this is a brand new dts file, it should use the reference based
syntax, which would be something like

&usbhost {
	...
};

below the / { ... }; block.

> +		samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
> +	};
> +
> +	usb-hub {
> +		compatible = "smsc,usb3503a";
> +		reset-gpios = <&hsic_reset>;

Hmm, why a -gpios property points to a pinctrl node? Shouldn't there be
a phandle to GPIO bank + GPIO specifier instead?

> +	};
> +
> +	fixed-rate-clocks {
> +		xxti {
> +			compatible = "samsung,clock-xxti";
> +			clock-frequency = <24000000>;
> +		};
> +	};

This is also referencing a node from higher level, so it should be done
using a reference.

> +
> +	hdmi {
> +		hpd-gpio = <&gpx3 7 GPIO_ACTIVE_HIGH>;
> +		pinctrl-names = "default";
> +		pinctrl-0 = <&hdmi_hpd_irq>;
> +		phy = <&hdmiphy>;
> +		ddc = <&i2c_2>;
> +		hdmi-en-supply = <&s5m_ldo8_reg>;
> +		vdd-supply = <&s5m_ldo8_reg>;
> +		vdd_osc-supply = <&s5m_ldo10_reg>;
> +		vdd_pll-supply = <&s5m_ldo8_reg>;
> +	};

Ditto.

> +
> +	fimd at 14400000 {
> +		status = "okay";
> +		samsung,invert-vclk;
> +	};

Ditto.

> +
> +	dp-controller at 145B0000 {
> +		status = "okay";
> +		pinctrl-names = "default";
> +		pinctrl-0 = <&dp_hpd>;
> +		samsung,color-space = <0>;
> +		samsung,dynamic-range = <0>;
> +		samsung,ycbcr-coeff = <0>;
> +		samsung,color-depth = <1>;
> +		samsung,link-rate = <0x0a>;
> +		samsung,lane-count = <1>;
> +		samsung,hpd-gpio = <&gpc3 0 GPIO_ACTIVE_HIGH>;
> +	};

Ditto.

> +};
> +
> +&dp_hpd {
> +	samsung,pins = "gpc3-0";
> +	samsung,pin-function = <0>;
> +	samsung,pin-pud = <3>;
> +	samsung,pin-drv = <0>;
> +};

Hmm, what node is this referencing? I believe this should rather
reference the pin controller and add a new board-specific pinconf/pinmux
group instead....

> +
> +&i2c_0 {
> +	status = "okay";
> +	samsung,i2c-sda-delay = <100>;
> +	samsung,i2c-max-bus-freq = <378000>;

[snip]

> +/*
> + * Disabled pullups since external part has its own pullups and
> + * double-pulling gets us out of spec in some cases.
> + */
> +&i2c2_bus {
> +	samsung,pin-pud = <0>;
> +};

OK, here overriding a generic pinconf group is justified and nicely
explained by a comment.

> +
> +&i2c_2 {
> +	status = "okay";
> +	samsung,i2c-sda-delay = <100>;
> +	samsung,i2c-max-bus-freq = <66000>;
> +
> +	hdmiddc at 50 {
> +		compatible = "samsung,exynos4210-hdmiddc";
> +		reg = <0x50>;
> +	};

I don't think this matches current Exynos HDMI bindings, which I believe
have been changed to just take a phandle to i2c bus instead.

> +};
> +
> +&i2c_3 {
> +	status = "okay";
> +	samsung,i2c-sda-delay = <100>;
> +	samsung,i2c-max-bus-freq = <66000>;
> +};

[snip]

> +&sd1_clk {
> +	samsung,pin-drv = <0>;
> +};
> +
> +&sd1_cmd {
> +	samsung,pin-pud = <3>;
> +	samsung,pin-drv = <0>;
> +};
> +
> +&sd1_cd {
> +	samsung,pin-drv = <0>;
> +};
> +
> +&sd1_bus4 {
> +	samsung,pin-drv = <0>;
> +};

Here generic settings are being overridden, so it might be a good idea
to explain why, like with i2c pull-up above.

Best regards,
Tomasz

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

* Re: [PATCH v4 3/4] ARM: dts: Clean up exynos5250-snow
  2014-07-31 16:08   ` Andreas Färber
@ 2014-07-31 19:19     ` Tomasz Figa
  -1 siblings, 0 replies; 61+ messages in thread
From: Tomasz Figa @ 2014-07-31 19:19 UTC (permalink / raw)
  To: Andreas Färber, linux-samsung-soc
  Cc: Mark Rutland, devicetree, Kukjin Kim, Vincent Palatin,
	Pawel Moll, Ian Campbell, open list, Kumar Gala,
	Stephan van Schaik, Doug Anderson, Rob Herring, Ben Dooks,
	Russell King, Javier Martinez Canillas, linux-arm-kernel

Andreas,

Please see my comments inline.

On 31.07.2014 18:08, Andreas Färber wrote:
> Use the new style of referencing inherited nodes and use symbolic names.
> 
> Suggested-by: Doug Anderson <dianders@chromium.org>
> Signed-off-by: Andreas Färber <afaerber@suse.de>

[snip]

> -
>  	usb@12110000 {
> -		samsung,vbus-gpio = <&gpx1 1 0>;
> +		samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
>  	};

This is a higher level node being overridden, so it should be specified
using references too.

>  
>  	fixed-rate-clocks {
> @@ -287,7 +206,7 @@
>  	};
>  
>  	hdmi {

Ditto.

Best regards,
Tomasz

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

* [PATCH v4 3/4] ARM: dts: Clean up exynos5250-snow
@ 2014-07-31 19:19     ` Tomasz Figa
  0 siblings, 0 replies; 61+ messages in thread
From: Tomasz Figa @ 2014-07-31 19:19 UTC (permalink / raw)
  To: linux-arm-kernel

Andreas,

Please see my comments inline.

On 31.07.2014 18:08, Andreas F?rber wrote:
> Use the new style of referencing inherited nodes and use symbolic names.
> 
> Suggested-by: Doug Anderson <dianders@chromium.org>
> Signed-off-by: Andreas F?rber <afaerber@suse.de>

[snip]

> -
>  	usb at 12110000 {
> -		samsung,vbus-gpio = <&gpx1 1 0>;
> +		samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
>  	};

This is a higher level node being overridden, so it should be specified
using references too.

>  
>  	fixed-rate-clocks {
> @@ -287,7 +206,7 @@
>  	};
>  
>  	hdmi {

Ditto.

Best regards,
Tomasz

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

* Re: [PATCH v4 1/4] ARM: dts: Fix MMC pinctrl for exynos5250-snow
  2014-07-31 16:08   ` Andreas Färber
@ 2014-07-31 19:20     ` Tomasz Figa
  -1 siblings, 0 replies; 61+ messages in thread
From: Tomasz Figa @ 2014-07-31 19:20 UTC (permalink / raw)
  To: Andreas Färber, linux-samsung-soc
  Cc: Mark Rutland, devicetree, Kukjin Kim, Vincent Palatin,
	Pawel Moll, Ian Campbell, open list, Kumar Gala,
	Stephan van Schaik, Doug Anderson, Jaehoon Chung, Rob Herring,
	Ben Dooks, Russell King, Javier Martinez Canillas,
	linux-arm-kernel

On 31.07.2014 18:08, Andreas Färber wrote:
> The pinctrl properties should be on the device directly and not on the
> slot sub-node.
> 
> Reported-by: Doug Anderson <dianders@chromium.org>
> Cc: Jaehoon Chung <jh80.chung@samsung.com>
> Signed-off-by: Andreas Färber <afaerber@suse.de>
> ---
>  v3 -> v4: Unchanged
>  
>  v3: New (Doug Anderson)
>  Redundant with Jaehoon Chung's general slot@0 deprecation,
>  in case that hits the tree earlier.
> 
>  arch/arm/boot/dts/exynos5250-snow.dts | 6 ++----
>  1 file changed, 2 insertions(+), 4 deletions(-)
> 

Reviewed-by: Tomasz Figa <t.figa@samsung.com>

Best regards,
Tomasz

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

* [PATCH v4 1/4] ARM: dts: Fix MMC pinctrl for exynos5250-snow
@ 2014-07-31 19:20     ` Tomasz Figa
  0 siblings, 0 replies; 61+ messages in thread
From: Tomasz Figa @ 2014-07-31 19:20 UTC (permalink / raw)
  To: linux-arm-kernel

On 31.07.2014 18:08, Andreas F?rber wrote:
> The pinctrl properties should be on the device directly and not on the
> slot sub-node.
> 
> Reported-by: Doug Anderson <dianders@chromium.org>
> Cc: Jaehoon Chung <jh80.chung@samsung.com>
> Signed-off-by: Andreas F?rber <afaerber@suse.de>
> ---
>  v3 -> v4: Unchanged
>  
>  v3: New (Doug Anderson)
>  Redundant with Jaehoon Chung's general slot at 0 deprecation,
>  in case that hits the tree earlier.
> 
>  arch/arm/boot/dts/exynos5250-snow.dts | 6 ++----
>  1 file changed, 2 insertions(+), 4 deletions(-)
> 

Reviewed-by: Tomasz Figa <t.figa@samsung.com>

Best regards,
Tomasz

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

* Re: [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
  2014-07-31 19:05     ` Tomasz Figa
@ 2014-07-31 19:20       ` Andreas Färber
  -1 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 19:20 UTC (permalink / raw)
  To: Tomasz Figa, linux-samsung-soc
  Cc: linux-arm-kernel, devicetree, Stephan van Schaik,
	Vincent Palatin, Doug Anderson, Javier Martinez Canillas,
	Rob Herring, Pawel Moll, Mark Rutland, Ian Campbell, Kumar Gala,
	Russell King, Ben Dooks, Kukjin Kim, LKML

Hi Tomasz,

Am 31.07.2014 21:05, schrieb Tomasz Figa:
> Hi Andreas,
> 
> Sorry for joining the party a bit late, but there were patches with less
> people involved so I preferred to review them first.
> 
> You can find my comments inline.
> 
> On 31.07.2014 18:08, Andreas Färber wrote:
>> Adds initial support for the HP Chromebook 11.
> 
> [snip]
> 
>> +	gpio-keys {
>> +		compatible = "gpio-keys";
>> +		pinctrl-names = "default";
>> +		pinctrl-0 = <&power_key_irq>, <&lid_irq>;
>> +
>> +		power {
>> +			label = "Power";
>> +			gpios = <&gpx1 3 GPIO_ACTIVE_LOW>;
>> +			linux,code = <KEY_POWER>;
> 
> I assume the key is debounced in hardware, so there is no need for
> debounce-interval here. Is this correct?

You're asking the wrong person... This is copied from
-cros-common/-snow. Downstream 3.8 does not have a debounce-interval
property.

> 
>> +			gpio-key,wakeup;
>> +		};
>> +
>> +		lid-switch {
>> +			label = "Lid";
>> +			gpios = <&gpx3 5 GPIO_ACTIVE_LOW>;
>> +			linux,input-type = <5>; /* EV_SW */
>> +			linux,code = <0>; /* SW_LID */
>> +			debounce-interval = <1>;
>> +			gpio-key,wakeup;
>> +		};
>> +	};
>> +
>> +	usb3_vbus_reg: regulator-usb3 {
>> +		compatible = "regulator-fixed";
>> +		regulator-name = "P5.0V_USB3CON";
>> +		regulator-min-microvolt = <5000000>;
>> +		regulator-max-microvolt = <5000000>;
>> +		gpio = <&gpe1 0 GPIO_ACTIVE_LOW>;
>> +		enable-active-high;
>> +	};
>> +
>> +	usb@12110000 {
> 
> Since this is a brand new dts file, it should use the reference based
> syntax, which would be something like
> 
> &usbhost {
> 	...
> };
> 
> below the / { ... }; block.

You will find that I already did that for all nodes that have a label.
Since there are lots of usb nodes, please suggest specific label names.

I originally tried to stay out of existing code, then I was asked to fix
-cros-common, clean up -snow too, now the SoC, ... ;)

>> +		samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
>> +	};
>> +
>> +	usb-hub {
>> +		compatible = "smsc,usb3503a";
>> +		reset-gpios = <&hsic_reset>;
> 
> Hmm, why a -gpios property points to a pinctrl node? Shouldn't there be
> a phandle to GPIO bank + GPIO specifier instead?

Dunno, can change it. Can I just copy the gpio property from the
regulator above?

>> +	};
>> +
>> +	fixed-rate-clocks {
>> +		xxti {
>> +			compatible = "samsung,clock-xxti";
>> +			clock-frequency = <24000000>;
>> +		};
>> +	};
> 
> This is also referencing a node from higher level, so it should be done
> using a reference.
> 
>> +
>> +	hdmi {
>> +		hpd-gpio = <&gpx3 7 GPIO_ACTIVE_HIGH>;
>> +		pinctrl-names = "default";
>> +		pinctrl-0 = <&hdmi_hpd_irq>;
>> +		phy = <&hdmiphy>;
>> +		ddc = <&i2c_2>;
>> +		hdmi-en-supply = <&s5m_ldo8_reg>;
>> +		vdd-supply = <&s5m_ldo8_reg>;
>> +		vdd_osc-supply = <&s5m_ldo10_reg>;
>> +		vdd_pll-supply = <&s5m_ldo8_reg>;
>> +	};
> 
> Ditto.

hdmi?

> 
>> +
>> +	fimd@14400000 {
>> +		status = "okay";
>> +		samsung,invert-vclk;
>> +	};
> 
> Ditto.

fimd?

> 
>> +
>> +	dp-controller@145B0000 {
>> +		status = "okay";
>> +		pinctrl-names = "default";
>> +		pinctrl-0 = <&dp_hpd>;
>> +		samsung,color-space = <0>;
>> +		samsung,dynamic-range = <0>;
>> +		samsung,ycbcr-coeff = <0>;
>> +		samsung,color-depth = <1>;
>> +		samsung,link-rate = <0x0a>;
>> +		samsung,lane-count = <1>;
>> +		samsung,hpd-gpio = <&gpc3 0 GPIO_ACTIVE_HIGH>;
>> +	};
> 
> Ditto.

dp_controller? display_port_controller?

> 
>> +};
>> +
>> +&dp_hpd {
>> +	samsung,pins = "gpc3-0";
>> +	samsung,pin-function = <0>;
>> +	samsung,pin-pud = <3>;
>> +	samsung,pin-drv = <0>;
>> +};
> 
> Hmm, what node is this referencing? I believe this should rather
> reference the pin controller and add a new board-specific pinconf/pinmux
> group instead....

It's a -pinctrl node. See v3->v4 change log and discussion on v3.

>> +
>> +&i2c_0 {
>> +	status = "okay";
>> +	samsung,i2c-sda-delay = <100>;
>> +	samsung,i2c-max-bus-freq = <378000>;
> 
> [snip]
> 
>> +/*
>> + * Disabled pullups since external part has its own pullups and
>> + * double-pulling gets us out of spec in some cases.
>> + */
>> +&i2c2_bus {
>> +	samsung,pin-pud = <0>;
>> +};
> 
> OK, here overriding a generic pinconf group is justified and nicely
> explained by a comment.

You seem to assume that I actually understand these things. ;)
Just copied from -cros-common/-snow.

>> +
>> +&i2c_2 {
>> +	status = "okay";
>> +	samsung,i2c-sda-delay = <100>;
>> +	samsung,i2c-max-bus-freq = <66000>;
>> +
>> +	hdmiddc@50 {
>> +		compatible = "samsung,exynos4210-hdmiddc";
>> +		reg = <0x50>;
>> +	};
> 
> I don't think this matches current Exynos HDMI bindings, which I believe
> have been changed to just take a phandle to i2c bus instead.

Copied from -cros-common/-snow.

>> +};
>> +
>> +&i2c_3 {
>> +	status = "okay";
>> +	samsung,i2c-sda-delay = <100>;
>> +	samsung,i2c-max-bus-freq = <66000>;
>> +};
> 
> [snip]
> 
>> +&sd1_clk {
>> +	samsung,pin-drv = <0>;
>> +};
>> +
>> +&sd1_cmd {
>> +	samsung,pin-pud = <3>;
>> +	samsung,pin-drv = <0>;
>> +};
>> +
>> +&sd1_cd {
>> +	samsung,pin-drv = <0>;
>> +};
>> +
>> +&sd1_bus4 {
>> +	samsung,pin-drv = <0>;
>> +};
> 
> Here generic settings are being overridden, so it might be a good idea
> to explain why, like with i2c pull-up above.

Snow does not have an explanation either, so please suggest what comment
you'd like to see. Consider me just a user with no specs. :)

Cheers,
Andreas

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg

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

* [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
@ 2014-07-31 19:20       ` Andreas Färber
  0 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 19:20 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Tomasz,

Am 31.07.2014 21:05, schrieb Tomasz Figa:
> Hi Andreas,
> 
> Sorry for joining the party a bit late, but there were patches with less
> people involved so I preferred to review them first.
> 
> You can find my comments inline.
> 
> On 31.07.2014 18:08, Andreas F?rber wrote:
>> Adds initial support for the HP Chromebook 11.
> 
> [snip]
> 
>> +	gpio-keys {
>> +		compatible = "gpio-keys";
>> +		pinctrl-names = "default";
>> +		pinctrl-0 = <&power_key_irq>, <&lid_irq>;
>> +
>> +		power {
>> +			label = "Power";
>> +			gpios = <&gpx1 3 GPIO_ACTIVE_LOW>;
>> +			linux,code = <KEY_POWER>;
> 
> I assume the key is debounced in hardware, so there is no need for
> debounce-interval here. Is this correct?

You're asking the wrong person... This is copied from
-cros-common/-snow. Downstream 3.8 does not have a debounce-interval
property.

> 
>> +			gpio-key,wakeup;
>> +		};
>> +
>> +		lid-switch {
>> +			label = "Lid";
>> +			gpios = <&gpx3 5 GPIO_ACTIVE_LOW>;
>> +			linux,input-type = <5>; /* EV_SW */
>> +			linux,code = <0>; /* SW_LID */
>> +			debounce-interval = <1>;
>> +			gpio-key,wakeup;
>> +		};
>> +	};
>> +
>> +	usb3_vbus_reg: regulator-usb3 {
>> +		compatible = "regulator-fixed";
>> +		regulator-name = "P5.0V_USB3CON";
>> +		regulator-min-microvolt = <5000000>;
>> +		regulator-max-microvolt = <5000000>;
>> +		gpio = <&gpe1 0 GPIO_ACTIVE_LOW>;
>> +		enable-active-high;
>> +	};
>> +
>> +	usb at 12110000 {
> 
> Since this is a brand new dts file, it should use the reference based
> syntax, which would be something like
> 
> &usbhost {
> 	...
> };
> 
> below the / { ... }; block.

You will find that I already did that for all nodes that have a label.
Since there are lots of usb nodes, please suggest specific label names.

I originally tried to stay out of existing code, then I was asked to fix
-cros-common, clean up -snow too, now the SoC, ... ;)

>> +		samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
>> +	};
>> +
>> +	usb-hub {
>> +		compatible = "smsc,usb3503a";
>> +		reset-gpios = <&hsic_reset>;
> 
> Hmm, why a -gpios property points to a pinctrl node? Shouldn't there be
> a phandle to GPIO bank + GPIO specifier instead?

Dunno, can change it. Can I just copy the gpio property from the
regulator above?

>> +	};
>> +
>> +	fixed-rate-clocks {
>> +		xxti {
>> +			compatible = "samsung,clock-xxti";
>> +			clock-frequency = <24000000>;
>> +		};
>> +	};
> 
> This is also referencing a node from higher level, so it should be done
> using a reference.
> 
>> +
>> +	hdmi {
>> +		hpd-gpio = <&gpx3 7 GPIO_ACTIVE_HIGH>;
>> +		pinctrl-names = "default";
>> +		pinctrl-0 = <&hdmi_hpd_irq>;
>> +		phy = <&hdmiphy>;
>> +		ddc = <&i2c_2>;
>> +		hdmi-en-supply = <&s5m_ldo8_reg>;
>> +		vdd-supply = <&s5m_ldo8_reg>;
>> +		vdd_osc-supply = <&s5m_ldo10_reg>;
>> +		vdd_pll-supply = <&s5m_ldo8_reg>;
>> +	};
> 
> Ditto.

hdmi?

> 
>> +
>> +	fimd at 14400000 {
>> +		status = "okay";
>> +		samsung,invert-vclk;
>> +	};
> 
> Ditto.

fimd?

> 
>> +
>> +	dp-controller at 145B0000 {
>> +		status = "okay";
>> +		pinctrl-names = "default";
>> +		pinctrl-0 = <&dp_hpd>;
>> +		samsung,color-space = <0>;
>> +		samsung,dynamic-range = <0>;
>> +		samsung,ycbcr-coeff = <0>;
>> +		samsung,color-depth = <1>;
>> +		samsung,link-rate = <0x0a>;
>> +		samsung,lane-count = <1>;
>> +		samsung,hpd-gpio = <&gpc3 0 GPIO_ACTIVE_HIGH>;
>> +	};
> 
> Ditto.

dp_controller? display_port_controller?

> 
>> +};
>> +
>> +&dp_hpd {
>> +	samsung,pins = "gpc3-0";
>> +	samsung,pin-function = <0>;
>> +	samsung,pin-pud = <3>;
>> +	samsung,pin-drv = <0>;
>> +};
> 
> Hmm, what node is this referencing? I believe this should rather
> reference the pin controller and add a new board-specific pinconf/pinmux
> group instead....

It's a -pinctrl node. See v3->v4 change log and discussion on v3.

>> +
>> +&i2c_0 {
>> +	status = "okay";
>> +	samsung,i2c-sda-delay = <100>;
>> +	samsung,i2c-max-bus-freq = <378000>;
> 
> [snip]
> 
>> +/*
>> + * Disabled pullups since external part has its own pullups and
>> + * double-pulling gets us out of spec in some cases.
>> + */
>> +&i2c2_bus {
>> +	samsung,pin-pud = <0>;
>> +};
> 
> OK, here overriding a generic pinconf group is justified and nicely
> explained by a comment.

You seem to assume that I actually understand these things. ;)
Just copied from -cros-common/-snow.

>> +
>> +&i2c_2 {
>> +	status = "okay";
>> +	samsung,i2c-sda-delay = <100>;
>> +	samsung,i2c-max-bus-freq = <66000>;
>> +
>> +	hdmiddc at 50 {
>> +		compatible = "samsung,exynos4210-hdmiddc";
>> +		reg = <0x50>;
>> +	};
> 
> I don't think this matches current Exynos HDMI bindings, which I believe
> have been changed to just take a phandle to i2c bus instead.

Copied from -cros-common/-snow.

>> +};
>> +
>> +&i2c_3 {
>> +	status = "okay";
>> +	samsung,i2c-sda-delay = <100>;
>> +	samsung,i2c-max-bus-freq = <66000>;
>> +};
> 
> [snip]
> 
>> +&sd1_clk {
>> +	samsung,pin-drv = <0>;
>> +};
>> +
>> +&sd1_cmd {
>> +	samsung,pin-pud = <3>;
>> +	samsung,pin-drv = <0>;
>> +};
>> +
>> +&sd1_cd {
>> +	samsung,pin-drv = <0>;
>> +};
>> +
>> +&sd1_bus4 {
>> +	samsung,pin-drv = <0>;
>> +};
> 
> Here generic settings are being overridden, so it might be a good idea
> to explain why, like with i2c pull-up above.

Snow does not have an explanation either, so please suggest what comment
you'd like to see. Consider me just a user with no specs. :)

Cheers,
Andreas

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 N?rnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imend?rffer; HRB 16746 AG N?rnberg

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

* Re: [PATCH v4 3/4] ARM: dts: Clean up exynos5250-snow
  2014-07-31 19:19     ` Tomasz Figa
@ 2014-07-31 19:21       ` Andreas Färber
  -1 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 19:21 UTC (permalink / raw)
  To: Tomasz Figa, linux-samsung-soc
  Cc: Mark Rutland, devicetree, Kukjin Kim, Vincent Palatin,
	Pawel Moll, Ian Campbell, open list, Kumar Gala,
	Stephan van Schaik, Doug Anderson, Rob Herring, Ben Dooks,
	Russell King, Javier Martinez Canillas, linux-arm-kernel

Am 31.07.2014 21:19, schrieb Tomasz Figa:
> Andreas,
> 
> Please see my comments inline.
> 
> On 31.07.2014 18:08, Andreas Färber wrote:
>> Use the new style of referencing inherited nodes and use symbolic names.
>>
>> Suggested-by: Doug Anderson <dianders@chromium.org>
>> Signed-off-by: Andreas Färber <afaerber@suse.de>
> 
> [snip]
> 
>> -
>>  	usb@12110000 {
>> -		samsung,vbus-gpio = <&gpx1 1 0>;
>> +		samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
>>  	};
> 
> This is a higher level node being overridden, so it should be specified
> using references too.
> 
>>  
>>  	fixed-rate-clocks {
>> @@ -287,7 +206,7 @@
>>  	};
>>  
>>  	hdmi {
> 
> Ditto.

Same problem as with spring: We need the labels first!

Andreas

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg

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

* [PATCH v4 3/4] ARM: dts: Clean up exynos5250-snow
@ 2014-07-31 19:21       ` Andreas Färber
  0 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 19:21 UTC (permalink / raw)
  To: linux-arm-kernel

Am 31.07.2014 21:19, schrieb Tomasz Figa:
> Andreas,
> 
> Please see my comments inline.
> 
> On 31.07.2014 18:08, Andreas F?rber wrote:
>> Use the new style of referencing inherited nodes and use symbolic names.
>>
>> Suggested-by: Doug Anderson <dianders@chromium.org>
>> Signed-off-by: Andreas F?rber <afaerber@suse.de>
> 
> [snip]
> 
>> -
>>  	usb at 12110000 {
>> -		samsung,vbus-gpio = <&gpx1 1 0>;
>> +		samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
>>  	};
> 
> This is a higher level node being overridden, so it should be specified
> using references too.
> 
>>  
>>  	fixed-rate-clocks {
>> @@ -287,7 +206,7 @@
>>  	};
>>  
>>  	hdmi {
> 
> Ditto.

Same problem as with spring: We need the labels first!

Andreas

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 N?rnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imend?rffer; HRB 16746 AG N?rnberg

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

* Re: [PATCH v4 2/4] ARM: dts: Fold exynos5250-cros-common into exynos5250-snow
  2014-07-31 16:08   ` Andreas Färber
@ 2014-07-31 19:22     ` Tomasz Figa
  -1 siblings, 0 replies; 61+ messages in thread
From: Tomasz Figa @ 2014-07-31 19:22 UTC (permalink / raw)
  To: Andreas Färber, linux-samsung-soc
  Cc: Mark Rutland, devicetree, Kukjin Kim, Vincent Palatin,
	Pawel Moll, Ian Campbell, open list, Kumar Gala,
	Stephan van Schaik, Doug Anderson, Rob Herring, Ben Dooks,
	Russell King, Javier Martinez Canillas, linux-arm-kernel

Please see my comments inline.

On 31.07.2014 18:08, Andreas Färber wrote:
> The remaining common ChromeOS pieces are fairly minor.
> 

For people that might stumble upon this patch in future, it would be
nice to specify the reason for this change.

Otherwise feel free to add:

Reviewed-by: Tomasz Figa <t.figa@samsung.com>

Best regards,
Tomasz

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

* [PATCH v4 2/4] ARM: dts: Fold exynos5250-cros-common into exynos5250-snow
@ 2014-07-31 19:22     ` Tomasz Figa
  0 siblings, 0 replies; 61+ messages in thread
From: Tomasz Figa @ 2014-07-31 19:22 UTC (permalink / raw)
  To: linux-arm-kernel

Please see my comments inline.

On 31.07.2014 18:08, Andreas F?rber wrote:
> The remaining common ChromeOS pieces are fairly minor.
> 

For people that might stumble upon this patch in future, it would be
nice to specify the reason for this change.

Otherwise feel free to add:

Reviewed-by: Tomasz Figa <t.figa@samsung.com>

Best regards,
Tomasz

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

* Re: [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
  2014-07-31 19:20       ` Andreas Färber
@ 2014-07-31 19:40         ` Tomasz Figa
  -1 siblings, 0 replies; 61+ messages in thread
From: Tomasz Figa @ 2014-07-31 19:40 UTC (permalink / raw)
  To: Andreas Färber, linux-samsung-soc, Vincent Palatin, Doug Anderson
  Cc: linux-arm-kernel, devicetree, Stephan van Schaik,
	Javier Martinez Canillas, Rob Herring, Pawel Moll, Mark Rutland,
	Ian Campbell, Kumar Gala, Russell King, Ben Dooks, Kukjin Kim,
	LKML

Andreas,

On 31.07.2014 21:20, Andreas Färber wrote:
> Am 31.07.2014 21:05, schrieb Tomasz Figa:
>> On 31.07.2014 18:08, Andreas Färber wrote:
>>> Adds initial support for the HP Chromebook 11.
>>
>> [snip]
>>
>>> +	gpio-keys {
>>> +		compatible = "gpio-keys";
>>> +		pinctrl-names = "default";
>>> +		pinctrl-0 = <&power_key_irq>, <&lid_irq>;
>>> +
>>> +		power {
>>> +			label = "Power";
>>> +			gpios = <&gpx1 3 GPIO_ACTIVE_LOW>;
>>> +			linux,code = <KEY_POWER>;
>>
>> I assume the key is debounced in hardware, so there is no need for
>> debounce-interval here. Is this correct?
> 
> You're asking the wrong person... This is copied from
> -cros-common/-snow. Downstream 3.8 does not have a debounce-interval
> property.

Doug, Vincent?

> 
>>
>>> +			gpio-key,wakeup;
>>> +		};

[snip]

>>> +
>>> +	usb@12110000 {
>>
>> Since this is a brand new dts file, it should use the reference based
>> syntax, which would be something like
>>
>> &usbhost {
>> 	...
>> };
>>
>> below the / { ... }; block.
> 
> You will find that I already did that for all nodes that have a label.
> Since there are lots of usb nodes, please suggest specific label names.
> 
> I originally tried to stay out of existing code, then I was asked to fix
> -cros-common, clean up -snow too, now the SoC, ... ;)

Well, adding labels should be pretty trivial and IMHO could be squashed
into this patch. For usb@1211000 the right label would be "ehci".

> 
>>> +		samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
>>> +	};
>>> +
>>> +	usb-hub {
>>> +		compatible = "smsc,usb3503a";
>>> +		reset-gpios = <&hsic_reset>;
>>
>> Hmm, why a -gpios property points to a pinctrl node? Shouldn't there be
>> a phandle to GPIO bank + GPIO specifier instead?
> 
> Dunno, can change it. Can I just copy the gpio property from the
> regulator above?

Reading what Vincent posted earlier I would consider this as the right
thing to do and it might even let you remove the fake regulator node.

> 
>>> +	};
>>> +
>>> +	fixed-rate-clocks {
>>> +		xxti {
>>> +			compatible = "samsung,clock-xxti";
>>> +			clock-frequency = <24000000>;
>>> +		};
>>> +	};
>>
>> This is also referencing a node from higher level, so it should be done
>> using a reference.
>>
>>> +
>>> +	hdmi {
>>> +		hpd-gpio = <&gpx3 7 GPIO_ACTIVE_HIGH>;
>>> +		pinctrl-names = "default";
>>> +		pinctrl-0 = <&hdmi_hpd_irq>;
>>> +		phy = <&hdmiphy>;
>>> +		ddc = <&i2c_2>;
>>> +		hdmi-en-supply = <&s5m_ldo8_reg>;
>>> +		vdd-supply = <&s5m_ldo8_reg>;
>>> +		vdd_osc-supply = <&s5m_ldo10_reg>;
>>> +		vdd_pll-supply = <&s5m_ldo8_reg>;
>>> +	};
>>
>> Ditto.
> 
> hdmi?

Sounds good.

> 
>>
>>> +
>>> +	fimd@14400000 {
>>> +		status = "okay";
>>> +		samsung,invert-vclk;
>>> +	};
>>
>> Ditto.
> 
> fimd?

OK.

> 
>>
>>> +
>>> +	dp-controller@145B0000 {
>>> +		status = "okay";
>>> +		pinctrl-names = "default";
>>> +		pinctrl-0 = <&dp_hpd>;
>>> +		samsung,color-space = <0>;
>>> +		samsung,dynamic-range = <0>;
>>> +		samsung,ycbcr-coeff = <0>;
>>> +		samsung,color-depth = <1>;
>>> +		samsung,link-rate = <0x0a>;
>>> +		samsung,lane-count = <1>;
>>> +		samsung,hpd-gpio = <&gpc3 0 GPIO_ACTIVE_HIGH>;
>>> +	};
>>
>> Ditto.
> 
> dp_controller? display_port_controller?

dp?

> 
>>
>>> +};
>>> +
>>> +&dp_hpd {
>>> +	samsung,pins = "gpc3-0";
>>> +	samsung,pin-function = <0>;
>>> +	samsung,pin-pud = <3>;
>>> +	samsung,pin-drv = <0>;
>>> +};
>>
>> Hmm, what node is this referencing? I believe this should rather
>> reference the pin controller and add a new board-specific pinconf/pinmux
>> group instead....
> 
> It's a -pinctrl node. See v3->v4 change log and discussion on v3.
> 

Well, this is clearly a board specific node anyway, because it does not
refer to a special function, but simply an input/interrupt GPIO. If it
somehow has landed in generic pinctrl dtsi then it should be removed
from there and this patch should simply introduce its own instance of
dp_hpd node, so you did the right thing in v3.

>>> +
>>> +&i2c_0 {
>>> +	status = "okay";
>>> +	samsung,i2c-sda-delay = <100>;
>>> +	samsung,i2c-max-bus-freq = <378000>;
>>
>> [snip]
>>
>>> +/*
>>> + * Disabled pullups since external part has its own pullups and
>>> + * double-pulling gets us out of spec in some cases.
>>> + */
>>> +&i2c2_bus {
>>> +	samsung,pin-pud = <0>;
>>> +};
>>
>> OK, here overriding a generic pinconf group is justified and nicely
>> explained by a comment.
> 
> You seem to assume that I actually understand these things. ;)
> Just copied from -cros-common/-snow.
> 

It is good if those things are being done with some level of
understanding. The DT mechanics are quite well documented in
Documentation/devicetree/bindings, while for HW-specific bits I believe
Chromium guys could give you a hand.

>>> +
>>> +&i2c_2 {
>>> +	status = "okay";
>>> +	samsung,i2c-sda-delay = <100>;
>>> +	samsung,i2c-max-bus-freq = <66000>;
>>> +
>>> +	hdmiddc@50 {
>>> +		compatible = "samsung,exynos4210-hdmiddc";
>>> +		reg = <0x50>;
>>> +	};
>>
>> I don't think this matches current Exynos HDMI bindings, which I believe
>> have been changed to just take a phandle to i2c bus instead.
> 
> Copied from -cros-common/-snow.
> 

This means that somebody probably forgot to update -cros-common/-snow
dts(i). Not the first and I guess probably not the last time...

>>> +};
>>> +
>>> +&i2c_3 {
>>> +	status = "okay";
>>> +	samsung,i2c-sda-delay = <100>;
>>> +	samsung,i2c-max-bus-freq = <66000>;
>>> +};
>>
>> [snip]
>>
>>> +&sd1_clk {
>>> +	samsung,pin-drv = <0>;
>>> +};
>>> +
>>> +&sd1_cmd {
>>> +	samsung,pin-pud = <3>;
>>> +	samsung,pin-drv = <0>;
>>> +};
>>> +
>>> +&sd1_cd {
>>> +	samsung,pin-drv = <0>;
>>> +};
>>> +
>>> +&sd1_bus4 {
>>> +	samsung,pin-drv = <0>;
>>> +};
>>
>> Here generic settings are being overridden, so it might be a good idea
>> to explain why, like with i2c pull-up above.
> 
> Snow does not have an explanation either, so please suggest what comment
> you'd like to see. Consider me just a user with no specs. :)

Doug, Vincent, someone else?

Best regards,
Tomasz

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

* [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
@ 2014-07-31 19:40         ` Tomasz Figa
  0 siblings, 0 replies; 61+ messages in thread
From: Tomasz Figa @ 2014-07-31 19:40 UTC (permalink / raw)
  To: linux-arm-kernel

Andreas,

On 31.07.2014 21:20, Andreas F?rber wrote:
> Am 31.07.2014 21:05, schrieb Tomasz Figa:
>> On 31.07.2014 18:08, Andreas F?rber wrote:
>>> Adds initial support for the HP Chromebook 11.
>>
>> [snip]
>>
>>> +	gpio-keys {
>>> +		compatible = "gpio-keys";
>>> +		pinctrl-names = "default";
>>> +		pinctrl-0 = <&power_key_irq>, <&lid_irq>;
>>> +
>>> +		power {
>>> +			label = "Power";
>>> +			gpios = <&gpx1 3 GPIO_ACTIVE_LOW>;
>>> +			linux,code = <KEY_POWER>;
>>
>> I assume the key is debounced in hardware, so there is no need for
>> debounce-interval here. Is this correct?
> 
> You're asking the wrong person... This is copied from
> -cros-common/-snow. Downstream 3.8 does not have a debounce-interval
> property.

Doug, Vincent?

> 
>>
>>> +			gpio-key,wakeup;
>>> +		};

[snip]

>>> +
>>> +	usb at 12110000 {
>>
>> Since this is a brand new dts file, it should use the reference based
>> syntax, which would be something like
>>
>> &usbhost {
>> 	...
>> };
>>
>> below the / { ... }; block.
> 
> You will find that I already did that for all nodes that have a label.
> Since there are lots of usb nodes, please suggest specific label names.
> 
> I originally tried to stay out of existing code, then I was asked to fix
> -cros-common, clean up -snow too, now the SoC, ... ;)

Well, adding labels should be pretty trivial and IMHO could be squashed
into this patch. For usb at 1211000 the right label would be "ehci".

> 
>>> +		samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>;
>>> +	};
>>> +
>>> +	usb-hub {
>>> +		compatible = "smsc,usb3503a";
>>> +		reset-gpios = <&hsic_reset>;
>>
>> Hmm, why a -gpios property points to a pinctrl node? Shouldn't there be
>> a phandle to GPIO bank + GPIO specifier instead?
> 
> Dunno, can change it. Can I just copy the gpio property from the
> regulator above?

Reading what Vincent posted earlier I would consider this as the right
thing to do and it might even let you remove the fake regulator node.

> 
>>> +	};
>>> +
>>> +	fixed-rate-clocks {
>>> +		xxti {
>>> +			compatible = "samsung,clock-xxti";
>>> +			clock-frequency = <24000000>;
>>> +		};
>>> +	};
>>
>> This is also referencing a node from higher level, so it should be done
>> using a reference.
>>
>>> +
>>> +	hdmi {
>>> +		hpd-gpio = <&gpx3 7 GPIO_ACTIVE_HIGH>;
>>> +		pinctrl-names = "default";
>>> +		pinctrl-0 = <&hdmi_hpd_irq>;
>>> +		phy = <&hdmiphy>;
>>> +		ddc = <&i2c_2>;
>>> +		hdmi-en-supply = <&s5m_ldo8_reg>;
>>> +		vdd-supply = <&s5m_ldo8_reg>;
>>> +		vdd_osc-supply = <&s5m_ldo10_reg>;
>>> +		vdd_pll-supply = <&s5m_ldo8_reg>;
>>> +	};
>>
>> Ditto.
> 
> hdmi?

Sounds good.

> 
>>
>>> +
>>> +	fimd at 14400000 {
>>> +		status = "okay";
>>> +		samsung,invert-vclk;
>>> +	};
>>
>> Ditto.
> 
> fimd?

OK.

> 
>>
>>> +
>>> +	dp-controller at 145B0000 {
>>> +		status = "okay";
>>> +		pinctrl-names = "default";
>>> +		pinctrl-0 = <&dp_hpd>;
>>> +		samsung,color-space = <0>;
>>> +		samsung,dynamic-range = <0>;
>>> +		samsung,ycbcr-coeff = <0>;
>>> +		samsung,color-depth = <1>;
>>> +		samsung,link-rate = <0x0a>;
>>> +		samsung,lane-count = <1>;
>>> +		samsung,hpd-gpio = <&gpc3 0 GPIO_ACTIVE_HIGH>;
>>> +	};
>>
>> Ditto.
> 
> dp_controller? display_port_controller?

dp?

> 
>>
>>> +};
>>> +
>>> +&dp_hpd {
>>> +	samsung,pins = "gpc3-0";
>>> +	samsung,pin-function = <0>;
>>> +	samsung,pin-pud = <3>;
>>> +	samsung,pin-drv = <0>;
>>> +};
>>
>> Hmm, what node is this referencing? I believe this should rather
>> reference the pin controller and add a new board-specific pinconf/pinmux
>> group instead....
> 
> It's a -pinctrl node. See v3->v4 change log and discussion on v3.
> 

Well, this is clearly a board specific node anyway, because it does not
refer to a special function, but simply an input/interrupt GPIO. If it
somehow has landed in generic pinctrl dtsi then it should be removed
from there and this patch should simply introduce its own instance of
dp_hpd node, so you did the right thing in v3.

>>> +
>>> +&i2c_0 {
>>> +	status = "okay";
>>> +	samsung,i2c-sda-delay = <100>;
>>> +	samsung,i2c-max-bus-freq = <378000>;
>>
>> [snip]
>>
>>> +/*
>>> + * Disabled pullups since external part has its own pullups and
>>> + * double-pulling gets us out of spec in some cases.
>>> + */
>>> +&i2c2_bus {
>>> +	samsung,pin-pud = <0>;
>>> +};
>>
>> OK, here overriding a generic pinconf group is justified and nicely
>> explained by a comment.
> 
> You seem to assume that I actually understand these things. ;)
> Just copied from -cros-common/-snow.
> 

It is good if those things are being done with some level of
understanding. The DT mechanics are quite well documented in
Documentation/devicetree/bindings, while for HW-specific bits I believe
Chromium guys could give you a hand.

>>> +
>>> +&i2c_2 {
>>> +	status = "okay";
>>> +	samsung,i2c-sda-delay = <100>;
>>> +	samsung,i2c-max-bus-freq = <66000>;
>>> +
>>> +	hdmiddc at 50 {
>>> +		compatible = "samsung,exynos4210-hdmiddc";
>>> +		reg = <0x50>;
>>> +	};
>>
>> I don't think this matches current Exynos HDMI bindings, which I believe
>> have been changed to just take a phandle to i2c bus instead.
> 
> Copied from -cros-common/-snow.
> 

This means that somebody probably forgot to update -cros-common/-snow
dts(i). Not the first and I guess probably not the last time...

>>> +};
>>> +
>>> +&i2c_3 {
>>> +	status = "okay";
>>> +	samsung,i2c-sda-delay = <100>;
>>> +	samsung,i2c-max-bus-freq = <66000>;
>>> +};
>>
>> [snip]
>>
>>> +&sd1_clk {
>>> +	samsung,pin-drv = <0>;
>>> +};
>>> +
>>> +&sd1_cmd {
>>> +	samsung,pin-pud = <3>;
>>> +	samsung,pin-drv = <0>;
>>> +};
>>> +
>>> +&sd1_cd {
>>> +	samsung,pin-drv = <0>;
>>> +};
>>> +
>>> +&sd1_bus4 {
>>> +	samsung,pin-drv = <0>;
>>> +};
>>
>> Here generic settings are being overridden, so it might be a good idea
>> to explain why, like with i2c pull-up above.
> 
> Snow does not have an explanation either, so please suggest what comment
> you'd like to see. Consider me just a user with no specs. :)

Doug, Vincent, someone else?

Best regards,
Tomasz

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

* Re: [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
  2014-07-31 19:05     ` Tomasz Figa
@ 2014-07-31 20:36       ` Andreas Färber
  -1 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 20:36 UTC (permalink / raw)
  To: Tomasz Figa, linux-samsung-soc
  Cc: linux-arm-kernel, devicetree, Stephan van Schaik,
	Vincent Palatin, Doug Anderson, Javier Martinez Canillas,
	Rob Herring, Pawel Moll, Mark Rutland, Ian Campbell, Kumar Gala,
	Russell King, Ben Dooks, Kukjin Kim, open list

Am 31.07.2014 21:05, schrieb Tomasz Figa:
>> +	};
>> +
>> +	fixed-rate-clocks {
>> +		xxti {
>> +			compatible = "samsung,clock-xxti";
>> +			clock-frequency = <24000000>;
>> +		};
>> +	};
> 
> This is also referencing a node from higher level, so it should be done
> using a reference.

Actually this one isn't! Neither fixed-rate-clocks nor xxti exists in
the .dtsi.

Andreas

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg

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

* [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
@ 2014-07-31 20:36       ` Andreas Färber
  0 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 20:36 UTC (permalink / raw)
  To: linux-arm-kernel

Am 31.07.2014 21:05, schrieb Tomasz Figa:
>> +	};
>> +
>> +	fixed-rate-clocks {
>> +		xxti {
>> +			compatible = "samsung,clock-xxti";
>> +			clock-frequency = <24000000>;
>> +		};
>> +	};
> 
> This is also referencing a node from higher level, so it should be done
> using a reference.

Actually this one isn't! Neither fixed-rate-clocks nor xxti exists in
the .dtsi.

Andreas

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 N?rnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imend?rffer; HRB 16746 AG N?rnberg

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

* Re: [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
  2014-07-31 20:36       ` Andreas Färber
@ 2014-07-31 21:09         ` Tomasz Figa
  -1 siblings, 0 replies; 61+ messages in thread
From: Tomasz Figa @ 2014-07-31 21:09 UTC (permalink / raw)
  To: Andreas Färber, linux-samsung-soc
  Cc: linux-arm-kernel, devicetree, Stephan van Schaik,
	Vincent Palatin, Doug Anderson, Javier Martinez Canillas,
	Rob Herring, Pawel Moll, Mark Rutland, Ian Campbell, Kumar Gala,
	Russell King, Ben Dooks, Kukjin Kim, open list



On 31.07.2014 22:36, Andreas Färber wrote:
> Am 31.07.2014 21:05, schrieb Tomasz Figa:
>>> +	};
>>> +
>>> +	fixed-rate-clocks {
>>> +		xxti {
>>> +			compatible = "samsung,clock-xxti";
>>> +			clock-frequency = <24000000>;
>>> +		};
>>> +	};
>>
>> This is also referencing a node from higher level, so it should be done
>> using a reference.
> 
> Actually this one isn't! Neither fixed-rate-clocks nor xxti exists in
> the .dtsi.

You've got me here. :)

In new dts I actually suggest to specify those on SoC level, since they
are generic SoC inputs and just override their frequencies on board
level, but apparently Exynos5250 doesn't follow this fashion. So this is
fine as is, sorry for noise.

Best regards,
Tomasz

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

* [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
@ 2014-07-31 21:09         ` Tomasz Figa
  0 siblings, 0 replies; 61+ messages in thread
From: Tomasz Figa @ 2014-07-31 21:09 UTC (permalink / raw)
  To: linux-arm-kernel



On 31.07.2014 22:36, Andreas F?rber wrote:
> Am 31.07.2014 21:05, schrieb Tomasz Figa:
>>> +	};
>>> +
>>> +	fixed-rate-clocks {
>>> +		xxti {
>>> +			compatible = "samsung,clock-xxti";
>>> +			clock-frequency = <24000000>;
>>> +		};
>>> +	};
>>
>> This is also referencing a node from higher level, so it should be done
>> using a reference.
> 
> Actually this one isn't! Neither fixed-rate-clocks nor xxti exists in
> the .dtsi.

You've got me here. :)

In new dts I actually suggest to specify those on SoC level, since they
are generic SoC inputs and just override their frequencies on board
level, but apparently Exynos5250 doesn't follow this fashion. So this is
fine as is, sorry for noise.

Best regards,
Tomasz

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

* Re: [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
  2014-07-31 19:40         ` Tomasz Figa
@ 2014-07-31 23:17           ` Andreas Färber
  -1 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 23:17 UTC (permalink / raw)
  To: Tomasz Figa, linux-samsung-soc
  Cc: Vincent Palatin, Doug Anderson, linux-arm-kernel, devicetree,
	Stephan van Schaik, Javier Martinez Canillas, Rob Herring,
	Pawel Moll, Mark Rutland, Ian Campbell, Kumar Gala, Russell King,
	Ben Dooks, Kukjin Kim, LKML

Am 31.07.2014 21:40, schrieb Tomasz Figa:
> On 31.07.2014 21:20, Andreas Färber wrote:
>> Am 31.07.2014 21:05, schrieb Tomasz Figa:
>>> On 31.07.2014 18:08, Andreas Färber wrote:
>>>> +	usb-hub {
>>>> +		compatible = "smsc,usb3503a";
>>>> +		reset-gpios = <&hsic_reset>;
>>>
>>> Hmm, why a -gpios property points to a pinctrl node? Shouldn't there be
>>> a phandle to GPIO bank + GPIO specifier instead?
>>
>> Dunno, can change it. Can I just copy the gpio property from the
>> regulator above?
> 
> Reading what Vincent posted earlier I would consider this as the right
> thing to do and it might even let you remove the fake regulator node.

Indeed it does, thanks for spotting this!

[...]
>>>> +&dp_hpd {
>>>> +	samsung,pins = "gpc3-0";
>>>> +	samsung,pin-function = <0>;
>>>> +	samsung,pin-pud = <3>;
>>>> +	samsung,pin-drv = <0>;
>>>> +};
>>>
>>> Hmm, what node is this referencing? I believe this should rather
>>> reference the pin controller and add a new board-specific pinconf/pinmux
>>> group instead....
>>
>> It's a -pinctrl node. See v3->v4 change log and discussion on v3.
>>
> 
> Well, this is clearly a board specific node anyway, because it does not
> refer to a special function, but simply an input/interrupt GPIO. If it
> somehow has landed in generic pinctrl dtsi then it should be removed
> from there and this patch should simply introduce its own instance of
> dp_hpd node, so you did the right thing in v3.

Well, my point was that the 3.8 tree contains only one dp-hpd node, not
two as we would get by adding a new node here.

Apart from Spring, it's used in Snow and SMDK5250, so moving it there
seems feasible and the cleanest solution to me.

>>> [snip]
>>>
>>>> +/*
>>>> + * Disabled pullups since external part has its own pullups and
>>>> + * double-pulling gets us out of spec in some cases.
>>>> + */
>>>> +&i2c2_bus {
>>>> +	samsung,pin-pud = <0>;
>>>> +};
>>>
>>> OK, here overriding a generic pinconf group is justified and nicely
>>> explained by a comment.
>>
>> You seem to assume that I actually understand these things. ;)
>> Just copied from -cros-common/-snow.
>>
> 
> It is good if those things are being done with some level of
> understanding. The DT mechanics are quite well documented in
> Documentation/devicetree/bindings, while for HW-specific bits I believe
> Chromium guys could give you a hand.

I did read and even fix documentation for those bindings that I added
myself in Spring, just not for those that were already in common code,
like this one here.

A tps65090 patch has been ignored since being asked to extend the commit
message, v3 was recently sent. Help getting that in appreciated.

Cheers,
Andreas

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg

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

* [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
@ 2014-07-31 23:17           ` Andreas Färber
  0 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 23:17 UTC (permalink / raw)
  To: linux-arm-kernel

Am 31.07.2014 21:40, schrieb Tomasz Figa:
> On 31.07.2014 21:20, Andreas F?rber wrote:
>> Am 31.07.2014 21:05, schrieb Tomasz Figa:
>>> On 31.07.2014 18:08, Andreas F?rber wrote:
>>>> +	usb-hub {
>>>> +		compatible = "smsc,usb3503a";
>>>> +		reset-gpios = <&hsic_reset>;
>>>
>>> Hmm, why a -gpios property points to a pinctrl node? Shouldn't there be
>>> a phandle to GPIO bank + GPIO specifier instead?
>>
>> Dunno, can change it. Can I just copy the gpio property from the
>> regulator above?
> 
> Reading what Vincent posted earlier I would consider this as the right
> thing to do and it might even let you remove the fake regulator node.

Indeed it does, thanks for spotting this!

[...]
>>>> +&dp_hpd {
>>>> +	samsung,pins = "gpc3-0";
>>>> +	samsung,pin-function = <0>;
>>>> +	samsung,pin-pud = <3>;
>>>> +	samsung,pin-drv = <0>;
>>>> +};
>>>
>>> Hmm, what node is this referencing? I believe this should rather
>>> reference the pin controller and add a new board-specific pinconf/pinmux
>>> group instead....
>>
>> It's a -pinctrl node. See v3->v4 change log and discussion on v3.
>>
> 
> Well, this is clearly a board specific node anyway, because it does not
> refer to a special function, but simply an input/interrupt GPIO. If it
> somehow has landed in generic pinctrl dtsi then it should be removed
> from there and this patch should simply introduce its own instance of
> dp_hpd node, so you did the right thing in v3.

Well, my point was that the 3.8 tree contains only one dp-hpd node, not
two as we would get by adding a new node here.

Apart from Spring, it's used in Snow and SMDK5250, so moving it there
seems feasible and the cleanest solution to me.

>>> [snip]
>>>
>>>> +/*
>>>> + * Disabled pullups since external part has its own pullups and
>>>> + * double-pulling gets us out of spec in some cases.
>>>> + */
>>>> +&i2c2_bus {
>>>> +	samsung,pin-pud = <0>;
>>>> +};
>>>
>>> OK, here overriding a generic pinconf group is justified and nicely
>>> explained by a comment.
>>
>> You seem to assume that I actually understand these things. ;)
>> Just copied from -cros-common/-snow.
>>
> 
> It is good if those things are being done with some level of
> understanding. The DT mechanics are quite well documented in
> Documentation/devicetree/bindings, while for HW-specific bits I believe
> Chromium guys could give you a hand.

I did read and even fix documentation for those bindings that I added
myself in Spring, just not for those that were already in common code,
like this one here.

A tps65090 patch has been ignored since being asked to extend the commit
message, v3 was recently sent. Help getting that in appreciated.

Cheers,
Andreas

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 N?rnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imend?rffer; HRB 16746 AG N?rnberg

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

* Re: [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
@ 2014-07-31 23:26             ` Tomasz Figa
  0 siblings, 0 replies; 61+ messages in thread
From: Tomasz Figa @ 2014-07-31 23:26 UTC (permalink / raw)
  To: Andreas Färber, linux-samsung-soc
  Cc: Vincent Palatin, Doug Anderson, linux-arm-kernel, devicetree,
	Stephan van Schaik, Javier Martinez Canillas, Rob Herring,
	Pawel Moll, Mark Rutland, Ian Campbell, Kumar Gala, Russell King,
	Ben Dooks, Kukjin Kim, LKML

On 01.08.2014 01:17, Andreas Färber wrote:
> Am 31.07.2014 21:40, schrieb Tomasz Figa:
>> On 31.07.2014 21:20, Andreas Färber wrote:
>>> Am 31.07.2014 21:05, schrieb Tomasz Figa:
>>>> On 31.07.2014 18:08, Andreas Färber wrote:
[snip]
>>>>> +&dp_hpd {
>>>>> +	samsung,pins = "gpc3-0";
>>>>> +	samsung,pin-function = <0>;
>>>>> +	samsung,pin-pud = <3>;
>>>>> +	samsung,pin-drv = <0>;
>>>>> +};
>>>>
>>>> Hmm, what node is this referencing? I believe this should rather
>>>> reference the pin controller and add a new board-specific pinconf/pinmux
>>>> group instead....
>>>
>>> It's a -pinctrl node. See v3->v4 change log and discussion on v3.
>>>
>>
>> Well, this is clearly a board specific node anyway, because it does not
>> refer to a special function, but simply an input/interrupt GPIO. If it
>> somehow has landed in generic pinctrl dtsi then it should be removed
>> from there and this patch should simply introduce its own instance of
>> dp_hpd node, so you did the right thing in v3.
> 
> Well, my point was that the 3.8 tree contains only one dp-hpd node, not
> two as we would get by adding a new node here.
> 
> Apart from Spring, it's used in Snow and SMDK5250, so moving it there
> seems feasible and the cleanest solution to me.
> 

What I mean is that in exynos5250-pinctrl.dtsi only generic SoC pin
groups should be defined and those more or less correspond to groups
with samsung,pin-function set to something other than 0 (input) or 1
(output). Now here hpd_gpio is just a normal GPIO input used as
interrupt source to detect when a cable is plugged or unplugged. This is
by no means generic to the SoC, because any GPIO with interrupt
capability can be used for this purpose. This means that the whole
pin{conf,mux} group should be defined on board level.

Best regards,
Tomasz

>>>> [snip]
>>>>
>>>>> +/*
>>>>> + * Disabled pullups since external part has its own pullups and
>>>>> + * double-pulling gets us out of spec in some cases.
>>>>> + */
>>>>> +&i2c2_bus {
>>>>> +	samsung,pin-pud = <0>;
>>>>> +};
>>>>
>>>> OK, here overriding a generic pinconf group is justified and nicely
>>>> explained by a comment.
>>>
>>> You seem to assume that I actually understand these things. ;)
>>> Just copied from -cros-common/-snow.
>>>
>>
>> It is good if those things are being done with some level of
>> understanding. The DT mechanics are quite well documented in
>> Documentation/devicetree/bindings, while for HW-specific bits I believe
>> Chromium guys could give you a hand.
> 
> I did read and even fix documentation for those bindings that I added
> myself in Spring, just not for those that were already in common code,
> like this one here.

My intention was that if there is something not clear, rather than
blindly copy-pasting it, it might be worth to ask people that might
know. Although any issues should generally be found at review stage, so
I don't really have any objections, assuming that Chromium people assure
that this patch adds valid data indeed.

> 
> A tps65090 patch has been ignored since being asked to extend the commit
> message, v3 was recently sent. Help getting that in appreciated.

Will take a look if time allows. Thanks for your work on this.

Best regards,
Tomasz

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

* Re: [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
@ 2014-07-31 23:26             ` Tomasz Figa
  0 siblings, 0 replies; 61+ messages in thread
From: Tomasz Figa @ 2014-07-31 23:26 UTC (permalink / raw)
  To: Andreas Färber, linux-samsung-soc-u79uwXL29TY76Z2rM5mHXA
  Cc: Vincent Palatin, Doug Anderson,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
	devicetree-u79uwXL29TY76Z2rM5mHXA, Stephan van Schaik,
	Javier Martinez Canillas, Rob Herring, Pawel Moll, Mark Rutland,
	Ian Campbell, Kumar Gala, Russell King, Ben Dooks, Kukjin Kim,
	LKML

On 01.08.2014 01:17, Andreas Färber wrote:
> Am 31.07.2014 21:40, schrieb Tomasz Figa:
>> On 31.07.2014 21:20, Andreas Färber wrote:
>>> Am 31.07.2014 21:05, schrieb Tomasz Figa:
>>>> On 31.07.2014 18:08, Andreas Färber wrote:
[snip]
>>>>> +&dp_hpd {
>>>>> +	samsung,pins = "gpc3-0";
>>>>> +	samsung,pin-function = <0>;
>>>>> +	samsung,pin-pud = <3>;
>>>>> +	samsung,pin-drv = <0>;
>>>>> +};
>>>>
>>>> Hmm, what node is this referencing? I believe this should rather
>>>> reference the pin controller and add a new board-specific pinconf/pinmux
>>>> group instead....
>>>
>>> It's a -pinctrl node. See v3->v4 change log and discussion on v3.
>>>
>>
>> Well, this is clearly a board specific node anyway, because it does not
>> refer to a special function, but simply an input/interrupt GPIO. If it
>> somehow has landed in generic pinctrl dtsi then it should be removed
>> from there and this patch should simply introduce its own instance of
>> dp_hpd node, so you did the right thing in v3.
> 
> Well, my point was that the 3.8 tree contains only one dp-hpd node, not
> two as we would get by adding a new node here.
> 
> Apart from Spring, it's used in Snow and SMDK5250, so moving it there
> seems feasible and the cleanest solution to me.
> 

What I mean is that in exynos5250-pinctrl.dtsi only generic SoC pin
groups should be defined and those more or less correspond to groups
with samsung,pin-function set to something other than 0 (input) or 1
(output). Now here hpd_gpio is just a normal GPIO input used as
interrupt source to detect when a cable is plugged or unplugged. This is
by no means generic to the SoC, because any GPIO with interrupt
capability can be used for this purpose. This means that the whole
pin{conf,mux} group should be defined on board level.

Best regards,
Tomasz

>>>> [snip]
>>>>
>>>>> +/*
>>>>> + * Disabled pullups since external part has its own pullups and
>>>>> + * double-pulling gets us out of spec in some cases.
>>>>> + */
>>>>> +&i2c2_bus {
>>>>> +	samsung,pin-pud = <0>;
>>>>> +};
>>>>
>>>> OK, here overriding a generic pinconf group is justified and nicely
>>>> explained by a comment.
>>>
>>> You seem to assume that I actually understand these things. ;)
>>> Just copied from -cros-common/-snow.
>>>
>>
>> It is good if those things are being done with some level of
>> understanding. The DT mechanics are quite well documented in
>> Documentation/devicetree/bindings, while for HW-specific bits I believe
>> Chromium guys could give you a hand.
> 
> I did read and even fix documentation for those bindings that I added
> myself in Spring, just not for those that were already in common code,
> like this one here.

My intention was that if there is something not clear, rather than
blindly copy-pasting it, it might be worth to ask people that might
know. Although any issues should generally be found at review stage, so
I don't really have any objections, assuming that Chromium people assure
that this patch adds valid data indeed.

> 
> A tps65090 patch has been ignored since being asked to extend the commit
> message, v3 was recently sent. Help getting that in appreciated.

Will take a look if time allows. Thanks for your work on this.

Best regards,
Tomasz
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
@ 2014-07-31 23:26             ` Tomasz Figa
  0 siblings, 0 replies; 61+ messages in thread
From: Tomasz Figa @ 2014-07-31 23:26 UTC (permalink / raw)
  To: linux-arm-kernel

On 01.08.2014 01:17, Andreas F?rber wrote:
> Am 31.07.2014 21:40, schrieb Tomasz Figa:
>> On 31.07.2014 21:20, Andreas F?rber wrote:
>>> Am 31.07.2014 21:05, schrieb Tomasz Figa:
>>>> On 31.07.2014 18:08, Andreas F?rber wrote:
[snip]
>>>>> +&dp_hpd {
>>>>> +	samsung,pins = "gpc3-0";
>>>>> +	samsung,pin-function = <0>;
>>>>> +	samsung,pin-pud = <3>;
>>>>> +	samsung,pin-drv = <0>;
>>>>> +};
>>>>
>>>> Hmm, what node is this referencing? I believe this should rather
>>>> reference the pin controller and add a new board-specific pinconf/pinmux
>>>> group instead....
>>>
>>> It's a -pinctrl node. See v3->v4 change log and discussion on v3.
>>>
>>
>> Well, this is clearly a board specific node anyway, because it does not
>> refer to a special function, but simply an input/interrupt GPIO. If it
>> somehow has landed in generic pinctrl dtsi then it should be removed
>> from there and this patch should simply introduce its own instance of
>> dp_hpd node, so you did the right thing in v3.
> 
> Well, my point was that the 3.8 tree contains only one dp-hpd node, not
> two as we would get by adding a new node here.
> 
> Apart from Spring, it's used in Snow and SMDK5250, so moving it there
> seems feasible and the cleanest solution to me.
> 

What I mean is that in exynos5250-pinctrl.dtsi only generic SoC pin
groups should be defined and those more or less correspond to groups
with samsung,pin-function set to something other than 0 (input) or 1
(output). Now here hpd_gpio is just a normal GPIO input used as
interrupt source to detect when a cable is plugged or unplugged. This is
by no means generic to the SoC, because any GPIO with interrupt
capability can be used for this purpose. This means that the whole
pin{conf,mux} group should be defined on board level.

Best regards,
Tomasz

>>>> [snip]
>>>>
>>>>> +/*
>>>>> + * Disabled pullups since external part has its own pullups and
>>>>> + * double-pulling gets us out of spec in some cases.
>>>>> + */
>>>>> +&i2c2_bus {
>>>>> +	samsung,pin-pud = <0>;
>>>>> +};
>>>>
>>>> OK, here overriding a generic pinconf group is justified and nicely
>>>> explained by a comment.
>>>
>>> You seem to assume that I actually understand these things. ;)
>>> Just copied from -cros-common/-snow.
>>>
>>
>> It is good if those things are being done with some level of
>> understanding. The DT mechanics are quite well documented in
>> Documentation/devicetree/bindings, while for HW-specific bits I believe
>> Chromium guys could give you a hand.
> 
> I did read and even fix documentation for those bindings that I added
> myself in Spring, just not for those that were already in common code,
> like this one here.

My intention was that if there is something not clear, rather than
blindly copy-pasting it, it might be worth to ask people that might
know. Although any issues should generally be found at review stage, so
I don't really have any objections, assuming that Chromium people assure
that this patch adds valid data indeed.

> 
> A tps65090 patch has been ignored since being asked to extend the commit
> message, v3 was recently sent. Help getting that in appreciated.

Will take a look if time allows. Thanks for your work on this.

Best regards,
Tomasz

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

* Re: [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
  2014-07-31 23:26             ` Tomasz Figa
@ 2014-07-31 23:31               ` Andreas Färber
  -1 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 23:31 UTC (permalink / raw)
  To: Tomasz Figa, linux-samsung-soc
  Cc: Vincent Palatin, Doug Anderson, linux-arm-kernel, devicetree,
	Stephan van Schaik, Javier Martinez Canillas, Rob Herring,
	Pawel Moll, Mark Rutland, Ian Campbell, Kumar Gala, Russell King,
	Ben Dooks, Kukjin Kim, LKML

Am 01.08.2014 01:26, schrieb Tomasz Figa:
> On 01.08.2014 01:17, Andreas Färber wrote:
>> Am 31.07.2014 21:40, schrieb Tomasz Figa:
>>> On 31.07.2014 21:20, Andreas Färber wrote:
>>>> Am 31.07.2014 21:05, schrieb Tomasz Figa:
>>>>> On 31.07.2014 18:08, Andreas Färber wrote:
> [snip]
>>>>>> +&dp_hpd {
>>>>>> +	samsung,pins = "gpc3-0";
>>>>>> +	samsung,pin-function = <0>;
>>>>>> +	samsung,pin-pud = <3>;
>>>>>> +	samsung,pin-drv = <0>;
>>>>>> +};
>>>>>
>>>>> Hmm, what node is this referencing? I believe this should rather
>>>>> reference the pin controller and add a new board-specific pinconf/pinmux
>>>>> group instead....
>>>>
>>>> It's a -pinctrl node. See v3->v4 change log and discussion on v3.
>>>>
>>>
>>> Well, this is clearly a board specific node anyway, because it does not
>>> refer to a special function, but simply an input/interrupt GPIO. If it
>>> somehow has landed in generic pinctrl dtsi then it should be removed
>>> from there and this patch should simply introduce its own instance of
>>> dp_hpd node, so you did the right thing in v3.
>>
>> Well, my point was that the 3.8 tree contains only one dp-hpd node, not
>> two as we would get by adding a new node here.
>>
>> Apart from Spring, it's used in Snow and SMDK5250, so moving it there
>> seems feasible and the cleanest solution to me.
>>
> 
> What I mean is that in exynos5250-pinctrl.dtsi only generic SoC pin
> groups should be defined and those more or less correspond to groups
> with samsung,pin-function set to something other than 0 (input) or 1
> (output). Now here hpd_gpio is just a normal GPIO input used as
> interrupt source to detect when a cable is plugged or unplugged. This is
> by no means generic to the SoC, because any GPIO with interrupt
> capability can be used for this purpose. This means that the whole
> pin{conf,mux} group should be defined on board level.

Exactly what I meant! :)

Andreas

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg

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

* [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
@ 2014-07-31 23:31               ` Andreas Färber
  0 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-07-31 23:31 UTC (permalink / raw)
  To: linux-arm-kernel

Am 01.08.2014 01:26, schrieb Tomasz Figa:
> On 01.08.2014 01:17, Andreas F?rber wrote:
>> Am 31.07.2014 21:40, schrieb Tomasz Figa:
>>> On 31.07.2014 21:20, Andreas F?rber wrote:
>>>> Am 31.07.2014 21:05, schrieb Tomasz Figa:
>>>>> On 31.07.2014 18:08, Andreas F?rber wrote:
> [snip]
>>>>>> +&dp_hpd {
>>>>>> +	samsung,pins = "gpc3-0";
>>>>>> +	samsung,pin-function = <0>;
>>>>>> +	samsung,pin-pud = <3>;
>>>>>> +	samsung,pin-drv = <0>;
>>>>>> +};
>>>>>
>>>>> Hmm, what node is this referencing? I believe this should rather
>>>>> reference the pin controller and add a new board-specific pinconf/pinmux
>>>>> group instead....
>>>>
>>>> It's a -pinctrl node. See v3->v4 change log and discussion on v3.
>>>>
>>>
>>> Well, this is clearly a board specific node anyway, because it does not
>>> refer to a special function, but simply an input/interrupt GPIO. If it
>>> somehow has landed in generic pinctrl dtsi then it should be removed
>>> from there and this patch should simply introduce its own instance of
>>> dp_hpd node, so you did the right thing in v3.
>>
>> Well, my point was that the 3.8 tree contains only one dp-hpd node, not
>> two as we would get by adding a new node here.
>>
>> Apart from Spring, it's used in Snow and SMDK5250, so moving it there
>> seems feasible and the cleanest solution to me.
>>
> 
> What I mean is that in exynos5250-pinctrl.dtsi only generic SoC pin
> groups should be defined and those more or less correspond to groups
> with samsung,pin-function set to something other than 0 (input) or 1
> (output). Now here hpd_gpio is just a normal GPIO input used as
> interrupt source to detect when a cable is plugged or unplugged. This is
> by no means generic to the SoC, because any GPIO with interrupt
> capability can be used for this purpose. This means that the whole
> pin{conf,mux} group should be defined on board level.

Exactly what I meant! :)

Andreas

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 N?rnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imend?rffer; HRB 16746 AG N?rnberg

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

* Re: [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
  2014-07-31 19:05     ` Tomasz Figa
@ 2014-08-01  3:17       ` Andreas Färber
  -1 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-08-01  3:17 UTC (permalink / raw)
  To: Tomasz Figa, linux-samsung-soc
  Cc: linux-arm-kernel, devicetree, Stephan van Schaik,
	Vincent Palatin, Doug Anderson, Javier Martinez Canillas,
	Rob Herring, Pawel Moll, Mark Rutland, Ian Campbell, Kumar Gala,
	Russell King, Ben Dooks, Kukjin Kim, open list

Am 31.07.2014 21:05, schrieb Tomasz Figa:
>> +
>> +&i2c_2 {
>> +	status = "okay";
>> +	samsung,i2c-sda-delay = <100>;
>> +	samsung,i2c-max-bus-freq = <66000>;
>> +
>> +	hdmiddc@50 {
>> +		compatible = "samsung,exynos4210-hdmiddc";
>> +		reg = <0x50>;
>> +	};
> 
> I don't think this matches current Exynos HDMI bindings, which I believe
> have been changed to just take a phandle to i2c bus instead.

Looks correct to me:

http://git.kernel.org/cgit/linux/kernel/git/kgene/linux-samsung.git/tree/Documentation/devicetree/bindings/video/exynos_hdmiddc.txt?h=for-next

https://git.kernel.org/cgit/linux/kernel/git/next/linux-next.git/tree/Documentation/devicetree/bindings/video/exynos_hdmiddc.txt

Andreas

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg

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

* [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
@ 2014-08-01  3:17       ` Andreas Färber
  0 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-08-01  3:17 UTC (permalink / raw)
  To: linux-arm-kernel

Am 31.07.2014 21:05, schrieb Tomasz Figa:
>> +
>> +&i2c_2 {
>> +	status = "okay";
>> +	samsung,i2c-sda-delay = <100>;
>> +	samsung,i2c-max-bus-freq = <66000>;
>> +
>> +	hdmiddc at 50 {
>> +		compatible = "samsung,exynos4210-hdmiddc";
>> +		reg = <0x50>;
>> +	};
> 
> I don't think this matches current Exynos HDMI bindings, which I believe
> have been changed to just take a phandle to i2c bus instead.

Looks correct to me:

http://git.kernel.org/cgit/linux/kernel/git/kgene/linux-samsung.git/tree/Documentation/devicetree/bindings/video/exynos_hdmiddc.txt?h=for-next

https://git.kernel.org/cgit/linux/kernel/git/next/linux-next.git/tree/Documentation/devicetree/bindings/video/exynos_hdmiddc.txt

Andreas

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 N?rnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imend?rffer; HRB 16746 AG N?rnberg

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

* Re: [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
  2014-07-31 19:40         ` Tomasz Figa
@ 2014-08-02  5:15           ` Doug Anderson
  -1 siblings, 0 replies; 61+ messages in thread
From: Doug Anderson @ 2014-08-02  5:15 UTC (permalink / raw)
  To: Tomasz Figa
  Cc: Andreas Färber, linux-samsung-soc, Vincent Palatin,
	linux-arm-kernel, devicetree, Stephan van Schaik,
	Javier Martinez Canillas, Rob Herring, Pawel Moll, Mark Rutland,
	Ian Campbell, Kumar Gala, Russell King, Ben Dooks, Kukjin Kim,
	LKML

Tomasz,

On Thu, Jul 31, 2014 at 12:40 PM, Tomasz Figa <tomasz.figa@gmail.com> wrote:
> Andreas,
>
> On 31.07.2014 21:20, Andreas Färber wrote:
>> Am 31.07.2014 21:05, schrieb Tomasz Figa:
>>> On 31.07.2014 18:08, Andreas Färber wrote:
>>>> Adds initial support for the HP Chromebook 11.
>>>
>>> [snip]
>>>
>>>> +   gpio-keys {
>>>> +           compatible = "gpio-keys";
>>>> +           pinctrl-names = "default";
>>>> +           pinctrl-0 = <&power_key_irq>, <&lid_irq>;
>>>> +
>>>> +           power {
>>>> +                   label = "Power";
>>>> +                   gpios = <&gpx1 3 GPIO_ACTIVE_LOW>;
>>>> +                   linux,code = <KEY_POWER>;
>>>
>>> I assume the key is debounced in hardware, so there is no need for
>>> debounce-interval here. Is this correct?
>>
>> You're asking the wrong person... This is copied from
>> -cros-common/-snow. Downstream 3.8 does not have a debounce-interval
>> property.
>
> Doug, Vincent?

Not something I've looked at, but it's never been a problem...


>>>> +&sd1_clk {
>>>> +   samsung,pin-drv = <0>;
>>>> +};
>>>> +
>>>> +&sd1_cmd {
>>>> +   samsung,pin-pud = <3>;
>>>> +   samsung,pin-drv = <0>;
>>>> +};
>>>> +
>>>> +&sd1_cd {
>>>> +   samsung,pin-drv = <0>;
>>>> +};
>>>> +
>>>> +&sd1_bus4 {
>>>> +   samsung,pin-drv = <0>;
>>>> +};
>>>
>>> Here generic settings are being overridden, so it might be a good idea
>>> to explain why, like with i2c pull-up above.
>>
>> Snow does not have an explanation either, so please suggest what comment
>> you'd like to see. Consider me just a user with no specs. :)
>
> Doug, Vincent, someone else?

The comment is just in a different place--it's in the dw_mmc node.
Probably belongs here, though:

                /*
                 * Wifi is a SiP, so can keep drive strengths low
                 * to reduce EMI.
                 */

I guess the cmd line isn't documented.  There is no external pull on
the command line and on most boards there is one.  Our hardware guys
thought we didn't need it and apparently we don't...

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

* [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
@ 2014-08-02  5:15           ` Doug Anderson
  0 siblings, 0 replies; 61+ messages in thread
From: Doug Anderson @ 2014-08-02  5:15 UTC (permalink / raw)
  To: linux-arm-kernel

Tomasz,

On Thu, Jul 31, 2014 at 12:40 PM, Tomasz Figa <tomasz.figa@gmail.com> wrote:
> Andreas,
>
> On 31.07.2014 21:20, Andreas F?rber wrote:
>> Am 31.07.2014 21:05, schrieb Tomasz Figa:
>>> On 31.07.2014 18:08, Andreas F?rber wrote:
>>>> Adds initial support for the HP Chromebook 11.
>>>
>>> [snip]
>>>
>>>> +   gpio-keys {
>>>> +           compatible = "gpio-keys";
>>>> +           pinctrl-names = "default";
>>>> +           pinctrl-0 = <&power_key_irq>, <&lid_irq>;
>>>> +
>>>> +           power {
>>>> +                   label = "Power";
>>>> +                   gpios = <&gpx1 3 GPIO_ACTIVE_LOW>;
>>>> +                   linux,code = <KEY_POWER>;
>>>
>>> I assume the key is debounced in hardware, so there is no need for
>>> debounce-interval here. Is this correct?
>>
>> You're asking the wrong person... This is copied from
>> -cros-common/-snow. Downstream 3.8 does not have a debounce-interval
>> property.
>
> Doug, Vincent?

Not something I've looked at, but it's never been a problem...


>>>> +&sd1_clk {
>>>> +   samsung,pin-drv = <0>;
>>>> +};
>>>> +
>>>> +&sd1_cmd {
>>>> +   samsung,pin-pud = <3>;
>>>> +   samsung,pin-drv = <0>;
>>>> +};
>>>> +
>>>> +&sd1_cd {
>>>> +   samsung,pin-drv = <0>;
>>>> +};
>>>> +
>>>> +&sd1_bus4 {
>>>> +   samsung,pin-drv = <0>;
>>>> +};
>>>
>>> Here generic settings are being overridden, so it might be a good idea
>>> to explain why, like with i2c pull-up above.
>>
>> Snow does not have an explanation either, so please suggest what comment
>> you'd like to see. Consider me just a user with no specs. :)
>
> Doug, Vincent, someone else?

The comment is just in a different place--it's in the dw_mmc node.
Probably belongs here, though:

                /*
                 * Wifi is a SiP, so can keep drive strengths low
                 * to reduce EMI.
                 */

I guess the cmd line isn't documented.  There is no external pull on
the command line and on most boards there is one.  Our hardware guys
thought we didn't need it and apparently we don't...

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

* Re: [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
  2014-08-02  5:15           ` Doug Anderson
  (?)
@ 2014-08-02  7:49             ` Andreas Färber
  -1 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-08-02  7:49 UTC (permalink / raw)
  To: Doug Anderson, Tomasz Figa
  Cc: linux-samsung-soc, Vincent Palatin, linux-arm-kernel, devicetree,
	Stephan van Schaik, Javier Martinez Canillas, Rob Herring,
	Pawel Moll, Mark Rutland, Ian Campbell, Kumar Gala, Russell King,
	Ben Dooks, Kukjin Kim, LKML

Am 02.08.2014 07:15, schrieb Doug Anderson:
> On Thu, Jul 31, 2014 at 12:40 PM, Tomasz Figa <tomasz.figa@gmail.com> wrote:
>> On 31.07.2014 21:20, Andreas Färber wrote:
>>> Am 31.07.2014 21:05, schrieb Tomasz Figa:
>>>> On 31.07.2014 18:08, Andreas Färber wrote:
>>>>> +&sd1_clk {
>>>>> +   samsung,pin-drv = <0>;
>>>>> +};
>>>>> +
>>>>> +&sd1_cmd {
>>>>> +   samsung,pin-pud = <3>;
>>>>> +   samsung,pin-drv = <0>;
>>>>> +};
>>>>> +
>>>>> +&sd1_cd {
>>>>> +   samsung,pin-drv = <0>;
>>>>> +};
>>>>> +
>>>>> +&sd1_bus4 {
>>>>> +   samsung,pin-drv = <0>;
>>>>> +};
>>>>
>>>> Here generic settings are being overridden, so it might be a good idea
>>>> to explain why, like with i2c pull-up above.
>>>
>>> Snow does not have an explanation either, so please suggest what comment
>>> you'd like to see. Consider me just a user with no specs. :)
>>
>> Doug, Vincent, someone else?
> 
> The comment is just in a different place--it's in the dw_mmc node.
> Probably belongs here, though:
> 
>                 /*
>                  * Wifi is a SiP, so can keep drive strengths low
>                  * to reduce EMI.
>                  */
> 

I did copy such a comment for the MMC node in v5, still present in v6.

Andreas

> I guess the cmd line isn't documented.  There is no external pull on
> the command line and on most boards there is one.  Our hardware guys
> thought we didn't need it and apparently we don't...

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg

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

* Re: [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
@ 2014-08-02  7:49             ` Andreas Färber
  0 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-08-02  7:49 UTC (permalink / raw)
  To: Doug Anderson, Tomasz Figa
  Cc: linux-samsung-soc, Vincent Palatin, linux-arm-kernel, devicetree,
	Stephan van Schaik, Javier Martinez Canillas, Rob Herring,
	Pawel Moll, Mark Rutland, Ian Campbell, Kumar Gala, Russell King,
	Ben Dooks, Kukjin Kim, LKML

Am 02.08.2014 07:15, schrieb Doug Anderson:
> On Thu, Jul 31, 2014 at 12:40 PM, Tomasz Figa <tomasz.figa@gmail.com> wrote:
>> On 31.07.2014 21:20, Andreas Färber wrote:
>>> Am 31.07.2014 21:05, schrieb Tomasz Figa:
>>>> On 31.07.2014 18:08, Andreas Färber wrote:
>>>>> +&sd1_clk {
>>>>> +   samsung,pin-drv = <0>;
>>>>> +};
>>>>> +
>>>>> +&sd1_cmd {
>>>>> +   samsung,pin-pud = <3>;
>>>>> +   samsung,pin-drv = <0>;
>>>>> +};
>>>>> +
>>>>> +&sd1_cd {
>>>>> +   samsung,pin-drv = <0>;
>>>>> +};
>>>>> +
>>>>> +&sd1_bus4 {
>>>>> +   samsung,pin-drv = <0>;
>>>>> +};
>>>>
>>>> Here generic settings are being overridden, so it might be a good idea
>>>> to explain why, like with i2c pull-up above.
>>>
>>> Snow does not have an explanation either, so please suggest what comment
>>> you'd like to see. Consider me just a user with no specs. :)
>>
>> Doug, Vincent, someone else?
> 
> The comment is just in a different place--it's in the dw_mmc node.
> Probably belongs here, though:
> 
>                 /*
>                  * Wifi is a SiP, so can keep drive strengths low
>                  * to reduce EMI.
>                  */
> 

I did copy such a comment for the MMC node in v5, still present in v6.

Andreas

> I guess the cmd line isn't documented.  There is no external pull on
> the command line and on most boards there is one.  Our hardware guys
> thought we didn't need it and apparently we don't...

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg

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

* [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
@ 2014-08-02  7:49             ` Andreas Färber
  0 siblings, 0 replies; 61+ messages in thread
From: Andreas Färber @ 2014-08-02  7:49 UTC (permalink / raw)
  To: linux-arm-kernel

Am 02.08.2014 07:15, schrieb Doug Anderson:
> On Thu, Jul 31, 2014 at 12:40 PM, Tomasz Figa <tomasz.figa@gmail.com> wrote:
>> On 31.07.2014 21:20, Andreas F?rber wrote:
>>> Am 31.07.2014 21:05, schrieb Tomasz Figa:
>>>> On 31.07.2014 18:08, Andreas F?rber wrote:
>>>>> +&sd1_clk {
>>>>> +   samsung,pin-drv = <0>;
>>>>> +};
>>>>> +
>>>>> +&sd1_cmd {
>>>>> +   samsung,pin-pud = <3>;
>>>>> +   samsung,pin-drv = <0>;
>>>>> +};
>>>>> +
>>>>> +&sd1_cd {
>>>>> +   samsung,pin-drv = <0>;
>>>>> +};
>>>>> +
>>>>> +&sd1_bus4 {
>>>>> +   samsung,pin-drv = <0>;
>>>>> +};
>>>>
>>>> Here generic settings are being overridden, so it might be a good idea
>>>> to explain why, like with i2c pull-up above.
>>>
>>> Snow does not have an explanation either, so please suggest what comment
>>> you'd like to see. Consider me just a user with no specs. :)
>>
>> Doug, Vincent, someone else?
> 
> The comment is just in a different place--it's in the dw_mmc node.
> Probably belongs here, though:
> 
>                 /*
>                  * Wifi is a SiP, so can keep drive strengths low
>                  * to reduce EMI.
>                  */
> 

I did copy such a comment for the MMC node in v5, still present in v6.

Andreas

> I guess the cmd line isn't documented.  There is no external pull on
> the command line and on most boards there is one.  Our hardware guys
> thought we didn't need it and apparently we don't...

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 N?rnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imend?rffer; HRB 16746 AG N?rnberg

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

* Re: [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
  2014-08-01  3:17       ` Andreas Färber
@ 2014-08-02 12:40         ` Tomasz Figa
  -1 siblings, 0 replies; 61+ messages in thread
From: Tomasz Figa @ 2014-08-02 12:40 UTC (permalink / raw)
  To: Andreas Färber, linux-samsung-soc
  Cc: linux-arm-kernel, devicetree, Stephan van Schaik,
	Vincent Palatin, Doug Anderson, Javier Martinez Canillas,
	Rob Herring, Pawel Moll, Mark Rutland, Ian Campbell, Kumar Gala,
	Russell King, Ben Dooks, Kukjin Kim, open list

On 01.08.2014 05:17, Andreas Färber wrote:
> Am 31.07.2014 21:05, schrieb Tomasz Figa:
>>> +
>>> +&i2c_2 {
>>> +	status = "okay";
>>> +	samsung,i2c-sda-delay = <100>;
>>> +	samsung,i2c-max-bus-freq = <66000>;
>>> +
>>> +	hdmiddc@50 {
>>> +		compatible = "samsung,exynos4210-hdmiddc";
>>> +		reg = <0x50>;
>>> +	};
>>
>> I don't think this matches current Exynos HDMI bindings, which I believe
>> have been changed to just take a phandle to i2c bus instead.
> 
> Looks correct to me:
> 
> http://git.kernel.org/cgit/linux/kernel/git/kgene/linux-samsung.git/tree/Documentation/devicetree/bindings/video/exynos_hdmiddc.txt?h=for-next
> 
> https://git.kernel.org/cgit/linux/kernel/git/next/linux-next.git/tree/Documentation/devicetree/bindings/video/exynos_hdmiddc.txt

Looks correct according to the documentation, but unfortunately this is
not the first time (and most likely not the last time) when our Exynos
DRM people carelessly change the binding without taking care of updating
relevant documentation correctly...

Please see following code:

https://git.kernel.org/cgit/linux/kernel/git/daeinki/drm-exynos.git/tree/drivers/gpu/drm/exynos/exynos_hdmi.c?h=exynos-drm-next#n2415

To get the DDC I2C adapter it first tries to look by a hardcoded
compatible string for backwards compatibility, but when there is no such
node, it uses the "ddc" property which is a phandle to the I2C adapter
node on which the DDC channel will be present.

Long story short, the binding of fake DDC device is obsolete and should
be marked so in documentation, while new device trees should only use
the new way with phandle.

However what this patch adds is for now technically correct and should
work even if support for old bindings is dropped in future, so I won't
consider this an issue.

Best regards,
Tomasz

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

* [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree
@ 2014-08-02 12:40         ` Tomasz Figa
  0 siblings, 0 replies; 61+ messages in thread
From: Tomasz Figa @ 2014-08-02 12:40 UTC (permalink / raw)
  To: linux-arm-kernel

On 01.08.2014 05:17, Andreas F?rber wrote:
> Am 31.07.2014 21:05, schrieb Tomasz Figa:
>>> +
>>> +&i2c_2 {
>>> +	status = "okay";
>>> +	samsung,i2c-sda-delay = <100>;
>>> +	samsung,i2c-max-bus-freq = <66000>;
>>> +
>>> +	hdmiddc at 50 {
>>> +		compatible = "samsung,exynos4210-hdmiddc";
>>> +		reg = <0x50>;
>>> +	};
>>
>> I don't think this matches current Exynos HDMI bindings, which I believe
>> have been changed to just take a phandle to i2c bus instead.
> 
> Looks correct to me:
> 
> http://git.kernel.org/cgit/linux/kernel/git/kgene/linux-samsung.git/tree/Documentation/devicetree/bindings/video/exynos_hdmiddc.txt?h=for-next
> 
> https://git.kernel.org/cgit/linux/kernel/git/next/linux-next.git/tree/Documentation/devicetree/bindings/video/exynos_hdmiddc.txt

Looks correct according to the documentation, but unfortunately this is
not the first time (and most likely not the last time) when our Exynos
DRM people carelessly change the binding without taking care of updating
relevant documentation correctly...

Please see following code:

https://git.kernel.org/cgit/linux/kernel/git/daeinki/drm-exynos.git/tree/drivers/gpu/drm/exynos/exynos_hdmi.c?h=exynos-drm-next#n2415

To get the DDC I2C adapter it first tries to look by a hardcoded
compatible string for backwards compatibility, but when there is no such
node, it uses the "ddc" property which is a phandle to the I2C adapter
node on which the DDC channel will be present.

Long story short, the binding of fake DDC device is obsolete and should
be marked so in documentation, while new device trees should only use
the new way with phandle.

However what this patch adds is for now technically correct and should
work even if support for old bindings is dropped in future, so I won't
consider this an issue.

Best regards,
Tomasz

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

end of thread, other threads:[~2014-08-02 12:40 UTC | newest]

Thread overview: 61+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-07-31 16:08 [PATCH v4 0/4] ARM: dts: exynos: Prepare Spring Andreas Färber
2014-07-31 16:08 ` Andreas Färber
2014-07-31 16:08 ` [PATCH v4 1/4] ARM: dts: Fix MMC pinctrl for exynos5250-snow Andreas Färber
2014-07-31 16:08   ` Andreas Färber
2014-07-31 16:08   ` Andreas Färber
2014-07-31 18:41   ` Kukjin Kim
2014-07-31 18:41     ` Kukjin Kim
2014-07-31 19:20   ` Tomasz Figa
2014-07-31 19:20     ` Tomasz Figa
2014-07-31 16:08 ` [PATCH v4 2/4] ARM: dts: Fold exynos5250-cros-common into exynos5250-snow Andreas Färber
2014-07-31 16:08   ` Andreas Färber
2014-07-31 16:08   ` Andreas Färber
2014-07-31 19:22   ` Tomasz Figa
2014-07-31 19:22     ` Tomasz Figa
2014-07-31 16:08 ` [PATCH v4 3/4] ARM: dts: Clean up exynos5250-snow Andreas Färber
2014-07-31 16:08   ` Andreas Färber
2014-07-31 16:08   ` Andreas Färber
2014-07-31 19:19   ` Tomasz Figa
2014-07-31 19:19     ` Tomasz Figa
2014-07-31 19:21     ` Andreas Färber
2014-07-31 19:21       ` Andreas Färber
2014-07-31 16:08 ` [PATCH v4 4/4] ARM: dts: Add exynos5250-spring device tree Andreas Färber
2014-07-31 16:08   ` Andreas Färber
2014-07-31 16:08   ` Andreas Färber
2014-07-31 17:00   ` Vincent Palatin
2014-07-31 17:00     ` Vincent Palatin
2014-07-31 17:14     ` Andreas Färber
2014-07-31 17:14       ` Andreas Färber
2014-07-31 17:38       ` Andreas Färber
2014-07-31 17:38         ` Andreas Färber
2014-07-31 18:51       ` Vincent Palatin
2014-07-31 18:51         ` Vincent Palatin
2014-07-31 19:05   ` Tomasz Figa
2014-07-31 19:05     ` Tomasz Figa
2014-07-31 19:05     ` Tomasz Figa
2014-07-31 19:20     ` Andreas Färber
2014-07-31 19:20       ` Andreas Färber
2014-07-31 19:40       ` Tomasz Figa
2014-07-31 19:40         ` Tomasz Figa
2014-07-31 23:17         ` Andreas Färber
2014-07-31 23:17           ` Andreas Färber
2014-07-31 23:26           ` Tomasz Figa
2014-07-31 23:26             ` Tomasz Figa
2014-07-31 23:26             ` Tomasz Figa
2014-07-31 23:31             ` Andreas Färber
2014-07-31 23:31               ` Andreas Färber
2014-08-02  5:15         ` Doug Anderson
2014-08-02  5:15           ` Doug Anderson
2014-08-02  7:49           ` Andreas Färber
2014-08-02  7:49             ` Andreas Färber
2014-08-02  7:49             ` Andreas Färber
2014-07-31 20:36     ` Andreas Färber
2014-07-31 20:36       ` Andreas Färber
2014-07-31 21:09       ` Tomasz Figa
2014-07-31 21:09         ` Tomasz Figa
2014-08-01  3:17     ` Andreas Färber
2014-08-01  3:17       ` Andreas Färber
2014-08-02 12:40       ` Tomasz Figa
2014-08-02 12:40         ` Tomasz Figa
2014-07-31 16:21 ` [PATCH v4 0/4] ARM: dts: exynos: Prepare Spring Andreas Färber
2014-07-31 16:21   ` Andreas Färber

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.