arm64: dts: rockchip: update usb2phy config for rk3399
authorFrank Wang <frank.wang@rock-chips.com>
Fri, 22 Jul 2016 01:42:31 +0000 (09:42 +0800)
committerHuang, Tao <huangtao@rock-chips.com>
Mon, 25 Jul 2016 02:37:48 +0000 (10:37 +0800)
Add host-port dt config and remove the old ones to support the
new usb2phy driver. Plus, Add vcc5v0_host regulator for usb2phy
and enable host-port config for all rk3399 board.

Change-Id: Ia9d00525f53e5a6f52ca6681b4b6b98235822940
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
arch/arm64/boot/dts/rockchip/rk3399-box-808-android.dts
arch/arm64/boot/dts/rockchip/rk3399-evb.dtsi
arch/arm64/boot/dts/rockchip/rk3399-mid-818-android.dts
arch/arm64/boot/dts/rockchip/rk3399-vr-android.dts
arch/arm64/boot/dts/rockchip/rk3399.dtsi

index f9de243..51f42e3 100644 (file)
                vin-supply = <&vcc_sys>;
        };
 
+       vcc5v0_host: vcc5v0-host-regulator {
+               compatible = "regulator-fixed";
+               enable-active-high;
+               gpio = <&gpio4 25 GPIO_ACTIVE_HIGH>;
+               pinctrl-names = "default";
+               pinctrl-0 = <&host_vbus_drv>;
+               regulator-name = "vcc5v0_host";
+       };
+
        vdd_center: vdd-center {
                compatible = "pwm-regulator";
                pwms = <&pwm2 0 25000 0>;
        status = "okay";
 };
 
+&u2phy0 {
+       status = "okay";
+
+       u2phy0_host: host-port {
+               phy-supply = <&vcc5v0_host>;
+               status = "okay";
+       };
+};
+
+&u2phy1 {
+       status = "okay";
+
+       u2phy1_host: host-port {
+               phy-supply = <&vcc5v0_host>;
+               status = "okay";
+       };
+};
+
 &uart0 {
        pinctrl-names = "default";
        pinctrl-0 = <&uart0_xfer &uart0_cts>;
        status = "okay";
 };
 
-&usb2phy {
-       vbus_drv-gpio = <&gpio4 25 GPIO_ACTIVE_HIGH>;
-};
-
 &usb_host0_ehci {
        status = "okay";
 };
                                <1 21 RK_FUNC_GPIO &pcfg_pull_up>;
                };
        };
+
+       usb2 {
+               host_vbus_drv: host-vbus-drv {
+                       rockchip,pins =
+                               <4 25 RK_FUNC_GPIO &pcfg_pull_none>;
+               };
+       };
 };
 
 &rk_screen {
index a1a4bea..c4533e8 100644 (file)
                regulator-max-microvolt = <3300000>;
        };
 
+       vcc5v0_host: vcc5v0-host-regulator {
+               compatible = "regulator-fixed";
+               enable-active-high;
+               gpio = <&gpio4 25 GPIO_ACTIVE_HIGH>;
+               pinctrl-names = "default";
+               pinctrl-0 = <&host_vbus_drv>;
+               regulator-name = "vcc5v0_host";
+       };
+
        backlight: backlight {
                compatible = "pwm-backlight";
                pwms = <&pwm0 0 25000 0>;
        status = "okay";
 };
 
+&u2phy0 {
+       status = "okay";
+
+       u2phy0_host: host-port {
+               phy-supply = <&vcc5v0_host>;
+               status = "okay";
+       };
+};
+
+&u2phy1 {
+       status = "okay";
+
+       u2phy1_host: host-port {
+               phy-supply = <&vcc5v0_host>;
+               status = "okay";
+       };
+};
+
 &uart0 {
        pinctrl-names = "default";
        pinctrl-0 = <&uart0_xfer &uart0_cts>;
        status = "okay";
 };
 
-&usb2phy {
-       vbus_drv-gpio = <&gpio4 25 GPIO_ACTIVE_HIGH>;
-};
-
 &usb_host0_ehci {
        status = "okay";
 };
                                <1 18 RK_FUNC_GPIO &pcfg_pull_down>;
                };
        };
+
+       usb2 {
+               host_vbus_drv: host-vbus-drv {
+                       rockchip,pins =
+                               <4 25 RK_FUNC_GPIO &pcfg_pull_none>;
+               };
+       };
 };
index 33b4ecc..eefd8fd 100644 (file)
                regulator-max-microvolt = <3300000>;
        };
 
+       vcc5v0_host: vcc5v0-host-regulator {
+               compatible = "regulator-fixed";
+               enable-active-high;
+               gpio = <&gpio4 25 GPIO_ACTIVE_HIGH>;
+               pinctrl-names = "default";
+               pinctrl-0 = <&host_vbus_drv>;
+               regulator-name = "vcc5v0_host";
+       };
+
        vdd_log: vdd-log {
                compatible = "pwm-regulator";
                pwms = <&pwm2 0 25000 0>;
        status = "okay";
 };
 
+&u2phy1 {
+       status = "okay";
+
+       u2phy1_host: host-port {
+               phy-supply = <&vcc5v0_host>;
+               status = "okay";
+       };
+};
+
 &uart0 {
        pinctrl-names = "default";
        pinctrl-0 = <&uart0_xfer &uart0_cts>;
        status = "okay";
 };
 
-&usb2phy {
-       vbus_drv-gpio = <&gpio4 25 GPIO_ACTIVE_HIGH>;
-};
-
 &usb_host0_ehci {
        status = "okay";
 };
                        rockchip,pins = <4 24 RK_FUNC_GPIO &pcfg_pull_none>;
                };
        };
+
+       usb2 {
+               host_vbus_drv: host-vbus-drv {
+                       rockchip,pins =
+                               <4 25 RK_FUNC_GPIO &pcfg_pull_none>;
+               };
+       };
 };
 
 &rk_screen {
index 013eb15..e816a01 100644 (file)
                regulator-max-microvolt = <3300000>;
        };
 
+       vcc5v0_host: vcc5v0-host-regulator {
+               compatible = "regulator-fixed";
+               enable-active-high;
+               gpio = <&gpio4 25 GPIO_ACTIVE_HIGH>;
+               pinctrl-names = "default";
+               pinctrl-0 = <&host_vbus_drv>;
+               regulator-name = "vcc5v0_host";
+       };
+
        backlight: backlight {
                compatible = "pwm-backlight";
                pwms = <&pwm0 0 25000 0>;
        };
 };
 
+&u2phy0 {
+       status = "okay";
+
+       u2phy0_host: host-port {
+               phy-supply = <&vcc5v0_host>;
+               status = "okay";
+       };
+};
+
+&u2phy1 {
+       status = "okay";
+
+       u2phy1_host: host-port {
+               phy-supply = <&vcc5v0_host>;
+               status = "okay";
+       };
+};
+
 &uart0 {
        pinctrl-names = "default";
        pinctrl-0 = <&uart0_xfer &uart0_cts>;
        status = "okay";
 };
 
-&usb2phy {
-       vbus_drv-gpio = <&gpio4 25 GPIO_ACTIVE_HIGH>;
-};
-
 &usb_host0_ehci {
        status = "okay";
 };
                        rockchip,pins = <1 4 RK_FUNC_GPIO &pcfg_pull_none>;
                };
        };
+
+       usb2 {
+               host_vbus_drv: host-vbus-drv {
+                       rockchip,pins =
+                               <4 25 RK_FUNC_GPIO &pcfg_pull_none>;
+               };
+       };
 };
index 3c16f6a..6ce3dcc 100644 (file)
                status = "disabled";
        };
 
-       usb2phy: usb2phy {
-               compatible = "rockchip,rk3399-usb-phy";
-               rockchip,grf = <&grf>;
-               #address-cells = <1>;
-               #size-cells = <0>;
-
-               usb2phy0: usb2-phy0 {
-                       #phy-cells = <0>;
-                       #clock-cells = <0>;
-                       reg = <0xe458>;
-               };
-
-               usb2phy1: usb2-phy1 {
-                       #phy-cells = <0>;
-                       #clock-cells = <0>;
-                       reg = <0xe468>;
-               };
-       };
-
        usb_host0_ehci: usb@fe380000 {
                compatible = "generic-ehci";
                reg = <0x0 0xfe380000 0x0 0x20000>;
                interrupts = <GIC_SPI 26 IRQ_TYPE_LEVEL_HIGH>;
                clocks = <&cru HCLK_HOST0>, <&cru HCLK_HOST0_ARB>;
                clock-names = "hclk_host0", "hclk_host0_arb";
-               phys = <&usb2phy0>;
-               phy-names = "usb2_phy0";
+               phys = <&u2phy0_host>;
+               phy-names = "usb";
                status = "disabled";
        };
 
                interrupts = <GIC_SPI 30 IRQ_TYPE_LEVEL_HIGH>;
                clocks = <&cru HCLK_HOST1>, <&cru HCLK_HOST1_ARB>;
                clock-names = "hclk_host1", "hclk_host1_arb";
-               phys = <&usb2phy1>;
-               phy-names = "usb2_phy1";
+               phys = <&u2phy1_host>;
+               phy-names = "usb";
                status = "disabled";
        };
 
                                                  "linestate";
                                status = "disabled";
                        };
+
+                       u2phy0_host: host-port {
+                               #phy-cells = <0>;
+                               interrupts = <GIC_SPI 27 IRQ_TYPE_LEVEL_HIGH>;
+                               interrupt-names = "linestate";
+                               status = "disabled";
+                       };
+               };
+
+               u2phy1: usb2-phy@e460 {
+                       compatible = "rockchip,rk3399-usb2phy";
+                       reg = <0xe460 0x10>;
+                       clocks = <&cru SCLK_USB2PHY1_REF>;
+                       clock-names = "phyclk";
+                       #clock-cells = <0>;
+                       clock-output-names = "clk_usbphy1_480m";
+                       status = "disabled";
+
+                       u2phy1_host: host-port {
+                               #phy-cells = <0>;
+                               interrupts = <GIC_SPI 31 IRQ_TYPE_LEVEL_HIGH>;
+                               interrupt-names = "linestate";
+                               status = "disabled";
+                       };
                };
        };