Skip to contentSkip to conversation

dts: Add usb2phy to Exynos 5250/5420

PATCH New Vikas Sajjan 2 participants 6 messages May 19, 2014 – May 21, 2014

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

v3 cover dts: Add usb2phy to Exynos 5250/5420

Based on 'for-next' branch of Kgene's linux-samsung tree. These patches are as per discussions on the driver side patches which have already been acked. [1]

Changes from v2:
- Addressed kukjin's comments to update DT binding documentation for sysreg.
- removed the version for each patch. Made all patches version as same.

Changes from v1:
- Rebase on 'for-next' branch.
- Removed 'phy-names' property as per discuusion in the driver patches. [1]

V1 of this series was the next version for earlier patch-series:
[PATCH v7 0/2] dts: Add usb2phy to Exynos 5250 [2]

Changes from v7 series:
- Added patches to enable usb 2.0 support on exynos5420; which include dt nodes for usb2phy as well as ehci and ohci controllers.

Changes from v6:
- Splitted the patch into two:
adding syscon nodes to Exynos5250 and Exynos5420 in first; and phy entry change in the second.
- Changed the name of phandle for usb2phy from 'usb2_phy_new' to 'usb2_phy_gen' indicating generic phy.
- Using clock macros in dt entries.

[1] http://www.spinics.net/lists/linux-usb/msg106908.html

    http://www.spinics.net/lists/linux-usb/msg106837.html

[2] http://www.spinics.net/lists/linux-usb/msg106427.html

Kamil Debski (1):
ARM: dts: Add usb2phy to Exynos 5250

Vivek Gautam (3):
ARM: dts: Add sysreg sytem controller node to exynos5250 and

    exynos5420

ARM: dts: Add usb2phy support on exynos5420
ARM: dts: Add usb 2.0 support on exynos5420

 .../devicetree/bindings/arm/samsung/sysreg.txt     |   11 ++++-
 arch/arm/boot/dts/exynos5250.dtsi                  |   27 ++++++++++++
 arch/arm/boot/dts/exynos5420.dtsi                  |   45 ++++++++++++++++++++
 3 files changed, 81 insertions(+), 2 deletions(-)
Signature · 1 line
1.7.9.5
#1 lore raw

PATCH v3 1/4 ARM: dts: Add sysreg sytem controller node to exynos5250 and exynos5420

From: Vivek Gautam <[email protected]>

This patch adds sysreg-syscon node to exynos5250 and exynos5420 device tree, to access System Register's registers using syscon driver.

[gautam.vivek at samsung.com: Split this syreg-syscon dts entry from
dts: Add usb2phy to Exynos 5250 patch]

[gautam.vivek at samsung.com: added similar syscon entry for exynos5420]
[vikas.sajjan at samsung.com: updated the binding document]
---
 .../devicetree/bindings/arm/samsung/sysreg.txt     |   11 +++++++++--
 arch/arm/boot/dts/exynos5250.dtsi                  |    5 +++++
 arch/arm/boot/dts/exynos5420.dtsi                  |    5 +++++
 3 files changed, 19 insertions(+), 2 deletions(-)
Documentation/devicetree/bindings/arm/samsung/sysreg.txt +9 -2
index 0ab3251..4fced6e 100644
@@ -1,8 +1,10 @@
 SAMSUNG S5P/Exynos SoC series System Registers (SYSREG)
 
 Properties:
- - compatible : should contain "samsung,<chip name>-sysreg", "syscon";
-   For Exynos4 SoC series it should be "samsung,exynos4-sysreg", "syscon";
+ - compatible : should contain two values. First value must be one from following list:
+		- "samsung,exynos4-sysreg" - for Exynos4 based SoCs,
+		- "samsung,exynos5-sysreg" - for Exynos5 based SoCs.
+		second value must be always "syscon".
  - reg : offset and length of the register set.
 
 Example:
@@ -10,3 +12,8 @@ Example:
 		compatible = "samsung,exynos4-sysreg", "syscon";
 		reg = <0x10010000 0x400>;
 	};
+
+	syscon at 10050000 {
+		compatible = "samsung,exynos5-sysreg", "syscon";
+		reg = <0x10050000 0x5000>;
+	};
arch/arm/boot/dts/exynos5250.dtsi +5 -0
index 68a3e6f..8e9b9a3 100644
@@ -193,6 +193,11 @@
 		reg = <0x10040000 0x5000>;
 	};
 
+	sysreg_system_controller: syscon at 10050000 {
+		compatible = "samsung,exynos5-sysreg", "syscon";
+		reg = <0x10050000 0x5000>;
+	};
+
 	watchdog at 101D0000 {
 		compatible = "samsung,exynos5250-wdt";
 		reg = <0x101D0000 0x100>;
arch/arm/boot/dts/exynos5420.dtsi +5 -0
index 13a083e..f9b051b 100644
@@ -725,6 +725,11 @@
 		reg = <0x10040000 0x5000>;
 	};
 
+	sysreg_system_controller: syscon at 10050000 {
+		compatible = "samsung,exynos5-sysreg", "syscon";
+		reg = <0x10050000 0x5000>;
+	};
+
 	tmu_cpu0: tmu at 10060000 {
 		compatible = "samsung,exynos5420-tmu";
 		reg = <0x10060000 0x100>;
Signature · 1 line
1.7.9.5
#2 lore raw

PATCH v3 2/4 ARM: dts: Add usb2phy to Exynos 5250

In reply to Vikas Sajjan

From: Kamil Debski <[email protected]>

Add support to PHY of USB2 of the Exynos 5250 SoC.

[gautam.vivek at samsung.com: Split the usb phy entries from syscon entries from earlier patch: dts: Add usb2phy to Exynos 5250]

[gautam.vivek at samsung.com: Added phy entry for OHCI also along with EHCI]
---
 arch/arm/boot/dts/exynos5250.dtsi |   22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)
arch/arm/boot/dts/exynos5250.dtsi +22 -0
index 8e9b9a3..cb29642 100644
@@ -577,6 +577,12 @@
 
 		clocks = <&clock CLK_USB2>;
 		clock-names = "usbhost";
+		#address-cells = <1>;
+		#size-cells = <0>;
+		port at 0 {
+			reg = <0>;
+			phys = <&usb2_phy_gen 1>;
+		};
 	};
 
 	usb at 12120000 {
@@ -586,6 +592,12 @@
 
 		clocks = <&clock CLK_USB2>;
 		clock-names = "usbhost";
+		#address-cells = <1>;
+		#size-cells = <0>;
+		port at 0 {
+			reg = <0>;
+			phys = <&usb2_phy_gen 1>;
+		};
 	};
 
 	usb2_phy: usbphy at 12130000 {
@@ -603,6 +615,16 @@
 		};
 	};
 
+	usb2_phy_gen: phy at 12130000 {
+		compatible = "samsung,exynos5250-usb2-phy";
+		reg = <0x12130000 0x100>;
+		clocks = <&clock CLK_USB2>, <&clock CLK_FIN_PLL>;
+		clock-names = "phy", "ref";
+		#phy-cells = <1>;
+		samsung,sysreg-phandle = <&sysreg_system_controller>;
+		samsung,pmureg-phandle = <&pmu_system_controller>;
+	};
+
 	pwm: pwm at 12dd0000 {
 		compatible = "samsung,exynos4210-pwm";
 		reg = <0x12dd0000 0x100>;
Signature · 1 line
1.7.9.5
#3 lore raw

PATCH v3 3/4 ARM: dts: Add usb2phy support on exynos5420

In reply to Vikas Sajjan

From: Vivek Gautam <[email protected]>

Add required device node for usb2phy to let enable USB 2.0 support.

---
 arch/arm/boot/dts/exynos5420.dtsi |   10 ++++++++++
 1 file changed, 10 insertions(+)
arch/arm/boot/dts/exynos5420.dtsi +10 -0
index f9b051b..2eb00cb 100644
@@ -838,4 +838,14 @@
 		samsung,pmu-syscon = <&pmu_system_controller>;
 		#phy-cells = <1>;
 	};
+
+	usb2_phy: phy at 12130000 {
+		compatible = "samsung,exynos5250-usb2-phy";
+		reg = <0x12130000 0x100>;
+		clocks = <&clock CLK_USBH20>, <&clock CLK_SCLK_USBPHY300>;
+		clock-names = "phy", "ref";
+		#phy-cells = <1>;
+		samsung,sysreg-phandle = <&sysreg_system_controller>;
+		samsung,pmureg-phandle = <&pmu_system_controller>;
+	};
 };
Signature · 1 line
1.7.9.5
#4 lore raw

PATCH v3 4/4 ARM: dts: Add usb 2.0 support on exynos5420

In reply to Vikas Sajjan

From: Vivek Gautam <[email protected]>

Add required device node for ehci and ohci controllers to enable USB 2.0 support.

---
 arch/arm/boot/dts/exynos5420.dtsi |   30 ++++++++++++++++++++++++++++++
 1 file changed, 30 insertions(+)
arch/arm/boot/dts/exynos5420.dtsi +30 -0
index 2eb00cb..921885a 100644
@@ -839,6 +839,36 @@
 		#phy-cells = <1>;
 	};
 
+	usbhost2: usb at 12110000 {
+		compatible = "samsung,exynos4210-ehci";
+		reg = <0x12110000 0x100>;
+		interrupts = <0 71 0>;
+
+		clocks = <&clock CLK_USBH20>;
+		clock-names = "usbhost";
+		#address-cells = <1>;
+		#size-cells = <0>;
+		port at 0 {
+			reg = <0>;
+			phys = <&usb2_phy 1>;
+		};
+	};
+
+	usbhost1: usb at 12120000 {
+		compatible = "samsung,exynos4210-ohci";
+		reg = <0x12120000 0x100>;
+		interrupts = <0 71 0>;
+
+		clocks = <&clock CLK_USBH20>;
+		clock-names = "usbhost";
+		#address-cells = <1>;
+		#size-cells = <0>;
+		port at 0 {
+			reg = <0>;
+			phys = <&usb2_phy 1>;
+		};
+	};
+
 	usb2_phy: phy at 12130000 {
 		compatible = "samsung,exynos5250-usb2-phy";
 		reg = <0x12130000 0x100>;
Signature · 1 line
1.7.9.5
#5 lore raw

v3 cover dts: Add usb2phy to Exynos 5250/5420

In reply to Vikas Sajjan
Quoted 5 lines · Vikas Sajjan

Based on 'for-next' branch of Kgene's linux-samsung tree. These patches are as per discussions on the driver side patches which have already been acked. [1]

Sounds good. I will apply this whole series if dt guys have no objection to add the exynos5-sysreg dt binding.

Thanks,
Kukjin

Quoted 36 lines

Changes from v2:
- Addressed kukjin's comments to update DT binding documentation
for sysreg.
- removed the version for each patch. Made all patches version as
same.

Changes from v1:
- Rebase on 'for-next' branch.
- Removed 'phy-names' property as per discuusion in the driver patches.
[1]

V1 of this series was the next version for earlier patch-series:
[PATCH v7 0/2] dts: Add usb2phy to Exynos 5250 [2]

Changes from v7 series:
- Added patches to enable usb 2.0 support on exynos5420; which include dt nodes for usb2phy as well as ehci and ohci controllers.

Changes from v6:
- Splitted the patch into two:
adding syscon nodes to Exynos5250 and Exynos5420 in first; and phy entry change in the second.
- Changed the name of phandle for usb2phy from 'usb2_phy_new' to 'usb2_phy_gen' indicating generic phy.
- Using clock macros in dt entries.

[1] http://www.spinics.net/lists/linux-usb/msg106908.html

    http://www.spinics.net/lists/linux-usb/msg106837.html

[2] http://www.spinics.net/lists/linux-usb/msg106427.html

Kamil Debski (1):
ARM: dts: Add usb2phy to Exynos 5250

Vivek Gautam (3):
ARM: dts: Add sysreg sytem controller node to exynos5250 and

Quoted 7 lines
    exynos5420

ARM: dts: Add usb2phy support on exynos5420
ARM: dts: Add usb 2.0 support on exynos5420

 .../devicetree/bindings/arm/samsung/sysreg.txt     |   11 ++++-
 arch/arm/boot/dts/exynos5250.dtsi                  |   27 ++++++++++++
 arch/arm/boot/dts/exynos5420.dtsi                  |   45

++++++++++++++++++++

Quoted 1 line
 3 files changed, 81 insertions(+), 2 deletions(-)