Skip to contentSkip to conversation

Add USB PHY device tree support for R8A7794/SILK board

PATCH New Sergei Shtylyov 2 participants 6 messages Sep 12, 2015 – Sep 30, 2015

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

cover Add USB PHY device tree support for R8A7794/SILK board

Hello.

Here's the set of 2 patches against Simon Horman's 'renesas.git' repo's
'renesas-devel-20150911v2-v4.2' tag plus the PCI USB patches just posted. Here we add the USB PHY device tree support on the R8A7794/SILK low cost board.

[1/2] ARM: shmobile: r8a7794: add USB PHY DT support [2/2] ARM: shmobile: silk: enable USB PHY

WBR, Sergei

#1 lore raw

PATCH 1/2 ARM: shmobile: r8a7794: add USB PHY DT support

Define the R8A7794 generic part of the USB PHY device node. It is up to the board file to enable the device.

---
 arch/arm/boot/dts/r8a7794.dtsi |   19 +++++++++++++++++++
 1 file changed, 19 insertions(+)
arch/arm/boot/dts/r8a7794.dtsi +19 -0
Index: renesas/arch/arm/boot/dts/r8a7794.dtsi
===================================================================
@@ -690,6 +690,25 @@
 				 0x1000 0 0 2 &gic 0 113 IRQ_TYPE_LEVEL_HIGH>;
 	};
 
+	usbphy: usb-phy at e6590100 {
+		compatible = "renesas,usb-phy-r8a7794";
+		reg = <0 0xe6590100 0 0x100>;
+		#address-cells = <1>;
+		#size-cells = <0>;
+		clocks = <&mstp7_clks R8A7794_CLK_HSUSB>;
+		clock-names = "usbhs";
+		status = "disabled";
+
+		usb0: usb-channel at 0 {
+			reg = <0>;
+			#phy-cells = <1>;
+		};
+		usb2: usb-channel at 2 {
+			reg = <2>;
+			#phy-cells = <1>;
+		};
+	};
+
 	clocks {
 		#address-cells = <2>;
 		#size-cells = <2>;
#2 lore raw

PATCH 1/2 ARM: shmobile: r8a7794: add USB PHY DT support

Hello.

Quoted 14 lines · Sergei Shtylyov

Define the R8A7794 generic part of the USB PHY device node. It is up to the board file to enable the device.

---
  arch/arm/boot/dts/r8a7794.dtsi |   19 +++++++++++++++++++
  1 file changed, 19 insertions(+)

Index: renesas/arch/arm/boot/dts/r8a7794.dtsi
===================================================================

arch/arm/boot/dts/r8a7794.dtsi line 699

Quoted 10 lines
arch/arm/boot/dts/r8a7794.dtsi +7 -0
@@ -690,6 +690,25 @@
  				 0x1000 0 0 2 &gic 0 113 IRQ_TYPE_LEVEL_HIGH>;
  	};
 
+	usbphy: usb-phy at e6590100 {
+		compatible = "renesas,usb-phy-r8a7794";
+		reg = <0 0xe6590100 0 0x100>;
+		#address-cells = <1>;
+		#size-cells = <0>;
+		clocks = <&mstp7_clks R8A7794_CLK_HSUSB>;
+		clock-names = "usbhs";
    Forgot to add "power-domains" prop here. :-(

MBR, Sergei

#3 lore raw

PATCH 1/2 ARM: shmobile: r8a7794: add USB PHY DT support

Quoted 21 lines · Sergei Shtylyov

Hello.

Quoted 17 lines · Sergei Shtylyov

Define the R8A7794 generic part of the USB PHY device node. It is up to the board file to enable the device.

---
 arch/arm/boot/dts/r8a7794.dtsi |   19 +++++++++++++++++++
 1 file changed, 19 insertions(+)

Index: renesas/arch/arm/boot/dts/r8a7794.dtsi
===================================================================

arch/arm/boot/dts/r8a7794.dtsi +0 -0
@@ -690,6 +690,25 @@
 				 0x1000 0 0 2 &gic 0 113 IRQ_TYPE_LEVEL_HIGH>;
 	};
 
Quoted 9 lines

arch/arm/boot/dts/r8a7794.dtsi line 699

Quoted 7 lines
arch/arm/boot/dts/r8a7794.dtsi +7 -0
+	usbphy: usb-phy at e6590100 {
+		compatible = "renesas,usb-phy-r8a7794";
+		reg = <0 0xe6590100 0 0x100>;
+		#address-cells = <1>;
+		#size-cells = <0>;
+		clocks = <&mstp7_clks R8A7794_CLK_HSUSB>;
+		clock-names = "usbhs";
   Forgot to add "power-domains" prop here. :-(

Are you planning to repost this?

#4 lore raw

PATCH 1/2 ARM: shmobile: r8a7794: add USB PHY DT support

Hello.

Quoted 27 lines · Simon Horman
Quoted 17 lines
Quoted 17 lines

Define the R8A7794 generic part of the USB PHY device node. It is up to the board file to enable the device.

---
  arch/arm/boot/dts/r8a7794.dtsi |   19 +++++++++++++++++++
  1 file changed, 19 insertions(+)

Index: renesas/arch/arm/boot/dts/r8a7794.dtsi
===================================================================

arch/arm/boot/dts/r8a7794.dtsi +0 -0
@@ -690,6 +690,25 @@
  				 0x1000 0 0 2 &gic 0 113 IRQ_TYPE_LEVEL_HIGH>;
  	};
 
Quoted 9 lines

arch/arm/boot/dts/r8a7794.dtsi line 699

Quoted 7 lines
arch/arm/boot/dts/r8a7794.dtsi +7 -0
+	usbphy: usb-phy at e6590100 {
+		compatible = "renesas,usb-phy-r8a7794";
+		reg = <0 0xe6590100 0 0x100>;
+		#address-cells = <1>;
+		#size-cells = <0>;
+		clocks = <&mstp7_clks R8A7794_CLK_HSUSB>;
+		clock-names = "usbhs";
    Forgot to add "power-domains" prop here. :-(
Quoted 1 line

Are you planning to repost this?

Yes.

MBR, Sergei

#5 lore raw

PATCH 2/2 ARM: shmobile: silk: enable USB PHY

In reply to Sergei Shtylyov

Enable USB PHY device for the SILK board.

---
 arch/arm/boot/dts/r8a7794-silk.dts |    4 ++++
 1 file changed, 4 insertions(+)
arch/arm/boot/dts/r8a7794-silk.dts +4 -0
Index: renesas/arch/arm/boot/dts/r8a7794-silk.dts
===================================================================
@@ -210,3 +210,7 @@
 	pinctrl-0 = <&usb1_pins>;
 	pinctrl-names = "default";
 };
+
+&usbphy {
+	status = "okay";
+};