diff options
author | Adrian Alonso <adrian.alonso@nxp.com> | 2021-03-15 21:48:48 -0500 |
---|---|---|
committer | Ye Li <ye.li@nxp.com> | 2021-06-18 01:43:22 -0700 |
commit | 8c2a94472d3a6020ecbc0f0b870cdb9bdd6d7f58 (patch) | |
tree | 0396d295014d6733c7cb4c0bffec97fa30ce7c1c | |
parent | 183d28a10400a481b41734b9a1064e65c6581f16 (diff) |
MLK-25347-5: dts: arm: imx8mm ab2: enable usbotg1 support
Enable usbotg1 on host mode for serial download support
Signed-off-by: Adrian Alonso <adrian.alonso@nxp.com>
Reviewed-by: Ye Li <ye.li@nxp.com>
(cherry picked from commit 09e5e3f3e246849b13a62c573d44042f3a944db3)
-rw-r--r-- | arch/arm/dts/imx8mm-ab2-u-boot.dtsi | 11 | ||||
-rw-r--r-- | arch/arm/dts/imx8mm-ab2.dts | 43 |
2 files changed, 54 insertions, 0 deletions
diff --git a/arch/arm/dts/imx8mm-ab2-u-boot.dtsi b/arch/arm/dts/imx8mm-ab2-u-boot.dtsi index b19020f70d..37a4e826c8 100644 --- a/arch/arm/dts/imx8mm-ab2-u-boot.dtsi +++ b/arch/arm/dts/imx8mm-ab2-u-boot.dtsi @@ -4,12 +4,23 @@ */ / { + aliases { + usbgadget0 = &usbg1; + }; + firmware { optee { compatible = "linaro,optee-tz"; method = "smc"; }; }; + + usbg1: usbg1 { + compatible = "fsl,imx27-usb-gadget"; + dr_mode = "peripheral"; + chipidea,usb = <&usbotg1>; + status = "okay"; + }; }; &{/soc@0} { diff --git a/arch/arm/dts/imx8mm-ab2.dts b/arch/arm/dts/imx8mm-ab2.dts index 4f346c20c0..442a7188ee 100644 --- a/arch/arm/dts/imx8mm-ab2.dts +++ b/arch/arm/dts/imx8mm-ab2.dts @@ -5,6 +5,7 @@ /dts-v1/; +#include <dt-bindings/usb/pd.h> #include "imx8mm.dtsi" / { @@ -455,6 +456,31 @@ scl-gpios = <&gpio5 16 GPIO_ACTIVE_HIGH>; sda-gpios = <&gpio5 17 GPIO_ACTIVE_HIGH>; status = "okay"; + + ptn5150: tcpc@1d { + compatible = "nxp,ptn5150"; + reg = <0x1d>; + status = "okay"; + + port { + typec1_dr_sw: endpoint { + remote-endpoint = <&usb1_drd_sw>; + }; + }; + + typec1_con: connector { + compatible = "usb-c-connector"; + label = "USB-C"; + power-role = "dual"; + data-role = "dual"; + try-power-role = "sink"; + source-pdos = <PDO_FIXED(5000, 3000, PDO_FIXED_USB_COMM)>; + sink-pdos = <PDO_FIXED(5000, 3000, PDO_FIXED_USB_COMM) + PDO_VAR(5000, 20000, 3000)>; + op-sink-microwatt = <15000000>; + self-powered; + }; + }; }; &i2c3 { @@ -498,6 +524,23 @@ status = "okay"; }; +&usbotg1 { + picophy,pre-emp-curr-control = <3>; + picophy,dc-vol-level-adjust = <7>; + dr_mode = "host"; + hnp-disable; + srp-disable; + adp-disable; + usb-role-switch; + status = "okay"; + + port { + usb1_drd_sw: endpoint { + remote-endpoint = <&typec1_dr_sw>; + }; + }; +}; + &wdog1 { pinctrl-names = "default"; pinctrl-0 = <&pinctrl_wdog>; |