Re: [PATCH 13/16] rockchip: rk3588-rock-5b: Drop usb-typec node from u-boot.dtsi
On 2024/5/5 03:43, Jonas Karlman wrote: The usb-typec related nodes and props added in the board u-boot.dtsi file has not yet landed in upstream Linux kernel DT, and they are not needed for U-Boot to use the USB Type-C port in peripheral mode. Remove superfluous usb-typec related nodes and props and replace them with a simple dr_mode and maximum-speed prop to cleanup the board u-boot.dtsi file. Signed-off-by: Jonas Karlman Reviewed-by: Kever Yang Thanks, - Kever --- arch/arm/dts/rk3588-rock-5b-u-boot.dtsi | 106 +--- 1 file changed, 2 insertions(+), 104 deletions(-) diff --git a/arch/arm/dts/rk3588-rock-5b-u-boot.dtsi b/arch/arm/dts/rk3588-rock-5b-u-boot.dtsi index d6020ca790f6..69914f4ce183 100644 --- a/arch/arm/dts/rk3588-rock-5b-u-boot.dtsi +++ b/arch/arm/dts/rk3588-rock-5b-u-boot.dtsi @@ -4,32 +4,12 @@ */ #include "rk3588-u-boot.dtsi" -#include - -/ { - vcc12v_dcin: vcc12v-dcin-regulator { - compatible = "regulator-fixed"; - regulator-name = "vcc12v_dcin"; - regulator-always-on; - regulator-boot-on; - regulator-min-microvolt = <1200>; - regulator-max-microvolt = <1200>; - }; -}; _pins { bootph-pre-ram; bootph-some-ram; }; - { - usb { - usbc0_int: usbc0-int { - rockchip,pins = <3 RK_PB4 RK_FUNC_GPIO _pull_none>; - }; - }; -}; - { cap-mmc-highspeed; mmc-hs200-1_8v; @@ -76,26 +56,7 @@ }; _phy0 { - orientation-switch; - mode-switch; - sbu1-dc-gpios = < RK_PA6 GPIO_ACTIVE_HIGH>; - sbu2-dc-gpios = < RK_PA7 GPIO_ACTIVE_HIGH>; status = "okay"; - - port { - #address-cells = <1>; - #size-cells = <0>; - - usbdp_phy0_typec_ss: endpoint@0 { - reg = <0>; - remote-endpoint = <_ss>; - }; - - usbdp_phy0_typec_sbu: endpoint@1 { - reg = <1>; - remote-endpoint = <_sbu>; - }; - }; }; _phy0_u3 { @@ -103,74 +64,11 @@ }; _host0_xhci { - usb-role-switch; + dr_mode = "peripheral"; + maximum-speed = "high-speed"; status = "okay"; - - port { - #address-cells = <1>; - #size-cells = <0>; - - usb_host0_xhci_drd_sw: endpoint { - remote-endpoint = <_hs>; - }; - }; }; _host1_xhci { status = "okay"; }; - - { - pinctrl-names = "default"; - pinctrl-0 = <_xfer>; - status = "okay"; - - usbc0: usb-typec@22 { - compatible = "fcs,fusb302"; - reg = <0x22>; - interrupt-parent = <>; - interrupts = ; - pinctrl-names = "default"; - pinctrl-0 = <_int>; - vbus-supply = <_dcin>; - status = "okay"; - - usb_con: connector { - compatible = "usb-c-connector"; - label = "USB-C"; - data-role = "dual"; - power-role = "sink"; - try-power-role = "sink"; - op-sink-microwatt = <100>; - sink-pdos = - , - ; - - ports { - #address-cells = <1>; - #size-cells = <0>; - - port@0 { - reg = <0>; - usbc0_hs: endpoint { - remote-endpoint = <_host0_xhci_drd_sw>; - }; - }; - - port@1 { - reg = <1>; - usbc0_ss: endpoint { - remote-endpoint = <_phy0_typec_ss>; - }; - }; - - port@2 { - reg = <2>; - usbc0_sbu: endpoint { - remote-endpoint = <_phy0_typec_sbu>; - }; - }; - }; - }; - }; -};
[PATCH 13/16] rockchip: rk3588-rock-5b: Drop usb-typec node from u-boot.dtsi
The usb-typec related nodes and props added in the board u-boot.dtsi file has not yet landed in upstream Linux kernel DT, and they are not needed for U-Boot to use the USB Type-C port in peripheral mode. Remove superfluous usb-typec related nodes and props and replace them with a simple dr_mode and maximum-speed prop to cleanup the board u-boot.dtsi file. Signed-off-by: Jonas Karlman --- arch/arm/dts/rk3588-rock-5b-u-boot.dtsi | 106 +--- 1 file changed, 2 insertions(+), 104 deletions(-) diff --git a/arch/arm/dts/rk3588-rock-5b-u-boot.dtsi b/arch/arm/dts/rk3588-rock-5b-u-boot.dtsi index d6020ca790f6..69914f4ce183 100644 --- a/arch/arm/dts/rk3588-rock-5b-u-boot.dtsi +++ b/arch/arm/dts/rk3588-rock-5b-u-boot.dtsi @@ -4,32 +4,12 @@ */ #include "rk3588-u-boot.dtsi" -#include - -/ { - vcc12v_dcin: vcc12v-dcin-regulator { - compatible = "regulator-fixed"; - regulator-name = "vcc12v_dcin"; - regulator-always-on; - regulator-boot-on; - regulator-min-microvolt = <1200>; - regulator-max-microvolt = <1200>; - }; -}; _pins { bootph-pre-ram; bootph-some-ram; }; - { - usb { - usbc0_int: usbc0-int { - rockchip,pins = <3 RK_PB4 RK_FUNC_GPIO _pull_none>; - }; - }; -}; - { cap-mmc-highspeed; mmc-hs200-1_8v; @@ -76,26 +56,7 @@ }; _phy0 { - orientation-switch; - mode-switch; - sbu1-dc-gpios = < RK_PA6 GPIO_ACTIVE_HIGH>; - sbu2-dc-gpios = < RK_PA7 GPIO_ACTIVE_HIGH>; status = "okay"; - - port { - #address-cells = <1>; - #size-cells = <0>; - - usbdp_phy0_typec_ss: endpoint@0 { - reg = <0>; - remote-endpoint = <_ss>; - }; - - usbdp_phy0_typec_sbu: endpoint@1 { - reg = <1>; - remote-endpoint = <_sbu>; - }; - }; }; _phy0_u3 { @@ -103,74 +64,11 @@ }; _host0_xhci { - usb-role-switch; + dr_mode = "peripheral"; + maximum-speed = "high-speed"; status = "okay"; - - port { - #address-cells = <1>; - #size-cells = <0>; - - usb_host0_xhci_drd_sw: endpoint { - remote-endpoint = <_hs>; - }; - }; }; _host1_xhci { status = "okay"; }; - - { - pinctrl-names = "default"; - pinctrl-0 = <_xfer>; - status = "okay"; - - usbc0: usb-typec@22 { - compatible = "fcs,fusb302"; - reg = <0x22>; - interrupt-parent = <>; - interrupts = ; - pinctrl-names = "default"; - pinctrl-0 = <_int>; - vbus-supply = <_dcin>; - status = "okay"; - - usb_con: connector { - compatible = "usb-c-connector"; - label = "USB-C"; - data-role = "dual"; - power-role = "sink"; - try-power-role = "sink"; - op-sink-microwatt = <100>; - sink-pdos = - , - ; - - ports { - #address-cells = <1>; - #size-cells = <0>; - - port@0 { - reg = <0>; - usbc0_hs: endpoint { - remote-endpoint = <_host0_xhci_drd_sw>; - }; - }; - - port@1 { - reg = <1>; - usbc0_ss: endpoint { - remote-endpoint = <_phy0_typec_ss>; - }; - }; - - port@2 { - reg = <2>; - usbc0_sbu: endpoint { - remote-endpoint = <_phy0_typec_sbu>; - }; - }; - }; - }; - }; -}; -- 2.43.2