Skip to content

Commit f9167f1

Browse files
laeyraudAngeloGioacchino Del Regno
authored andcommitted
arm64: dts: mediatek: mt8390-genio-common: Set ssusb2 default dual role mode to host
On the Mediatek Genio 510-EVK and 700-EVK boards, ssusb2 controller is one but has two ports: one is routed to the M.2 slot, the other is on the RPi header who does support full OTG. Since Mediatek Genio 700-EVK USB support was added, dual role mode property is set to otg for ssusb2. This config prevents the M.2 Wifi/Bluetooth module, present on those boards and exposing Bluetooth as an USB device to be properly detected at startup as the default role is device. To keep the OTG functionality and make the M.2 module be detected at the same time, add role-switch-default-mode property set to host and also fix the polarity of GPIO associated to the USB connector, so the ssusb2 controller role is properly set to host when the other port is unused. Fixes: 1afaeca ("arm64: dts: mediatek: mt8390-genio-700: Add USB, TypeC Controller, MUX") Signed-off-by: Louis-Alexis Eyraud <[email protected]> Link: https://lore.kernel.org/r/20250502-mtk-genio-510-700-fix-bt-detection-v2-1-870aa2145480@collabora.com Signed-off-by: AngeloGioacchino Del Regno <[email protected]>
1 parent 0eae9ce commit f9167f1

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

arch/arm64/boot/dts/mediatek/mt8390-genio-common.dtsi

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1333,8 +1333,18 @@
13331333
};
13341334

13351335
&ssusb2 {
1336+
/*
1337+
* the ssusb2 controller is one but we got two ports : one is routed
1338+
* to the M.2 slot, the other is on the RPi header who does support
1339+
* full OTG.
1340+
* As the controller is shared between them, the role switch default
1341+
* mode is set to host to make any peripheral inserted in the M.2
1342+
* slot (i.e BT/WIFI module) be detected when the other port is
1343+
* unused.
1344+
*/
13361345
dr_mode = "otg";
13371346
maximum-speed = "high-speed";
1347+
role-switch-default-mode = "host";
13381348
usb-role-switch;
13391349
vusb33-supply = <&mt6359_vusb_ldo_reg>;
13401350
wakeup-source;
@@ -1345,7 +1355,7 @@
13451355
connector {
13461356
compatible = "gpio-usb-b-connector", "usb-b-connector";
13471357
type = "micro";
1348-
id-gpios = <&pio 89 GPIO_ACTIVE_HIGH>;
1358+
id-gpios = <&pio 89 GPIO_ACTIVE_LOW>;
13491359
vbus-supply = <&usb_p2_vbus>;
13501360
};
13511361
};

0 commit comments

Comments
 (0)