Hi,
i’ve got info that USB-OTG driver was included in upstream an added it to my 5.4-main-tree.
now i hang on dts-node…i took node from example of Patch and modified to have no alias/name-problem
otg: [email protected] {
compatible = "mediatek,mt2701-musb",
"mediatek,mtk-musb";
reg = <0 0x11200000 0 0x1000>;
interrupts = <GIC_SPI 32 IRQ_TYPE_LEVEL_LOW>;
interrupt-names = "mc";
phys = <&u2port2 PHY_TYPE_USB2>;
dr_mode = "otg";
clocks = <&pericfg CLK_PERI_USB0>,
<&pericfg CLK_PERI_USB0_MCU>,
<&pericfg CLK_PERI_USB_SLV>;
clock-names = "main","mcu","univpll";
power-domains = <&scpsys MT2701_POWER_DOMAIN_IFR_MSC>;
usb-role-switch;
connector{
compatible = "gpio-usb-b-connector", "usb-b-connector";
type = "micro";
id-gpios = <&pio 44 GPIO_ACTIVE_HIGH>;
vbus-supply = <&usb_vbus>;
};
};
below the memory node in bpi-r2.dts in 5.4
DTC arch/arm/boot/dts/mt7623n-bananapi-bpi-r2.dtb
arch/arm/boot/dts/mt7623n-bananapi-bpi-r2.dts:141.20-161.4: ERROR (phandle_references): /[email protected]: Reference to non-existent node or label "u2port2"
arch/arm/boot/dts/mt7623n-bananapi-bpi-r2.dts:155.12-160.5: ERROR (phandle_references): /[email protected]/connector: Reference to non-existent node or label "usb_vbus"
so i need the u2port2 (the phy?) and usb_vbus nodes. i have u2port0 and u2port1 defined in mt7623.dtsi, but imho these are the “normal” usb-ports. And i have no vbus-node which i can use…
i got some hints from MTK, but need some help to solve it
- rename musb phy dts node because it was used by XHCI driver. => which phy is used for otg-port? there are 2 u3phy1 and u3phy2 (5.4-main/mt7623.dtsi#L1136)
- check usb VBUS/IDDIG gpio number (cannot use original mt2701 gpio number) => shematics Page 18 => i found gpio45 for NCEB0 but not for NCEB1=IDDIG
- check MT7623’s clock-names and power-domains => will look if first 2 are solved
Questions mainly go to @sinovoip / @Jackzeng (if he is still by bpi) and maybe @ray but maybe anybody else can help me here