| 1 |
// SPDX-License-Identifier: (GPL-2.0-or-later OR MIT) |
| 2 |
/* |
| 3 |
* Copyright (c) 2022-2024 TQ-Systems GmbH <[email protected]>, |
| 4 |
* D-82229 Seefeld, Germany. |
| 5 |
* Author: Alexander Stein |
| 6 |
*/ |
| 7 |
|
| 8 |
/dts-v1/; |
| 9 |
/plugin/; |
| 10 |
|
| 11 |
#include <dt-bindings/gpio/gpio.h> |
| 12 |
|
| 13 |
#include "imx8mn-pinfunc.h" |
| 14 |
|
| 15 |
&{/} { |
| 16 |
connector { |
| 17 |
compatible = "gpio-usb-b-connector", "usb-b-connector"; |
| 18 |
type = "micro"; |
| 19 |
label = "X19"; |
| 20 |
pinctrl-names = "default"; |
| 21 |
pinctrl-0 = <&pinctrl_usb1_connector>; |
| 22 |
id-gpios = <&gpio1 10 GPIO_ACTIVE_HIGH>; |
| 23 |
|
| 24 |
port { |
| 25 |
usb_dr_connector: endpoint { |
| 26 |
remote-endpoint = <&usb1_drd_sw>; |
| 27 |
}; |
| 28 |
}; |
| 29 |
}; |
| 30 |
}; |
| 31 |
|
| 32 |
/* |
| 33 |
* rst_usb_hub_hog and sel_usb_hub_hog have property 'output-high', |
| 34 |
* dt overlay don't support /delete-property/. Both 'output-low' and |
| 35 |
* 'output-high' will be exist under hog nodes if overlay file set |
| 36 |
* 'output-low'. Workaround is disable these hog and create new hog with |
| 37 |
* 'output-low'. |
| 38 |
*/ |
| 39 |
|
| 40 |
&rst_usb_hub_hog { |
| 41 |
status = "disabled"; |
| 42 |
}; |
| 43 |
|
| 44 |
&expander0 { |
| 45 |
rst-usb-low-hub-hog { |
| 46 |
gpio-hog; |
| 47 |
gpios = <13 0>; |
| 48 |
output-low; |
| 49 |
line-name = "RST_USB_HUB#"; |
| 50 |
}; |
| 51 |
}; |
| 52 |
|
| 53 |
&sel_usb_hub_hog { |
| 54 |
status = "disabled"; |
| 55 |
}; |
| 56 |
|
| 57 |
&gpio2 { |
| 58 |
sel-usb-low-hub-hog { |
| 59 |
gpio-hog; |
| 60 |
gpios = <1 GPIO_ACTIVE_HIGH>; |
| 61 |
output-low; |
| 62 |
}; |
| 63 |
}; |
| 64 |
|
| 65 |
&usbotg1 { |
| 66 |
pinctrl-names = "default"; |
| 67 |
pinctrl-0 = <&pinctrl_usbotg>; |
| 68 |
dr_mode = "otg"; |
| 69 |
srp-disable; |
| 70 |
hnp-disable; |
| 71 |
adp-disable; |
| 72 |
power-active-high; |
| 73 |
/delete-property/ disable-over-current; |
| 74 |
over-current-active-low; |
| 75 |
usb-role-switch; |
| 76 |
status = "okay"; |
| 77 |
|
| 78 |
port { |
| 79 |
usb1_drd_sw: endpoint { |
| 80 |
remote-endpoint = <&usb_dr_connector>; |
| 81 |
}; |
| 82 |
}; |
| 83 |
}; |
| 84 |
|
| 85 |
&iomuxc { |
| 86 |
pinctrl_usb1_connector: usb1-connectorgrp { |
| 87 |
fsl,pins = <MX8MN_IOMUXC_GPIO1_IO10_GPIO1_IO10 0x1c0>; |
| 88 |
}; |
| 89 |
}; |