I am currently modifying the i.MX8MP, and I plan to use USB port 2 (USB 3.0 Type-A host) as a USB 2.0 Type-A device. I have also modified the Device Tree.
usb@32f10108 {
compatible = "fsl,imx8mp-dwc3";
reg = <0x32f10108 0x08 0x382f0000 0x20>;
clocks = <0x02 0x10c 0x02 0x14a>;
clock-names = "hsio\0suspend";
interrupts = <0x00 0x95 0x04>;
power-domains = <0x60 0x00>;
#address-cells = <0x01>;
#size-cells = <0x01>;
dma-ranges = <0x40000000 0x40000000 0xc0000000>;
ranges;
status = "okay";
phandle = <0x123>;
usb@38200000 {
compatible = "snps,dwc3";
reg = <0x38200000 0x10000>;
clocks = <0x02 0xff 0x02 0x92 0x02 0x14a>;
clock-names = "bus_early\0ref\0suspend";
interrupts = <0x00 0x29 0x04>;
phys = <0x85 0x85>;
phy-names = "usb2-phy\0usb3-phy";
snps,gfladj-refclk-lpm-sel-quirk;
snps,parkmode-disable-ss-quirk;
vbus-supply = <0x86>;
dr_mode = "peripheral";
status = "okay";
phandle = <0x124>;
};
};
cat /sys/kernel/debug/usb/38200000.usb -->> device
However, when using a USB 2.0 cable to connect to the PC, the PC did not recognize the device. I want to know what other modifications need to be made besides modifying the Device Tree.