diff options
author | Philippe Schenker <philippe.schenker@toradex.com> | 2022-11-02 16:58:01 +0100 |
---|---|---|
committer | Philippe Schenker <philippe.schenker@toradex.com> | 2022-11-02 16:59:53 +0100 |
commit | a9d1419f9cca3f3d86590cfca49db5be990b3b81 (patch) | |
tree | f510ca102da88a403d64f68ca1ac293d0179b59c /recipes-kernel/linux/linux-toradex-mainline-git/0001-ARM-dts-colibri-imx6ull-Enable-dual-role-switching.patch | |
parent | be8cf57e1bf2ccb049923a62787a6a90efd58a4c (diff) |
linux-toradex-mainline: Support usb otg on colibri-imx6ull
This commit adds two patches to our upstream kernel that solves the
reset loop and the OTG device-host dual-role switching
Related-to: ELB-4790, ELB-4610
Signed-off-by: Philippe Schenker <philippe.schenker@toradex.com>
Diffstat (limited to 'recipes-kernel/linux/linux-toradex-mainline-git/0001-ARM-dts-colibri-imx6ull-Enable-dual-role-switching.patch')
-rw-r--r-- | recipes-kernel/linux/linux-toradex-mainline-git/0001-ARM-dts-colibri-imx6ull-Enable-dual-role-switching.patch | 50 |
1 files changed, 50 insertions, 0 deletions
diff --git a/recipes-kernel/linux/linux-toradex-mainline-git/0001-ARM-dts-colibri-imx6ull-Enable-dual-role-switching.patch b/recipes-kernel/linux/linux-toradex-mainline-git/0001-ARM-dts-colibri-imx6ull-Enable-dual-role-switching.patch new file mode 100644 index 0000000..4582f07 --- /dev/null +++ b/recipes-kernel/linux/linux-toradex-mainline-git/0001-ARM-dts-colibri-imx6ull-Enable-dual-role-switching.patch @@ -0,0 +1,50 @@ +From 35f50699d4d17dbd3b116ea4d3c9f349567d3805 Mon Sep 17 00:00:00 2001 +From: Philippe Schenker <philippe.schenker@toradex.com> +Date: Wed, 19 Oct 2022 17:59:13 +0200 +Subject: [PATCH 1/2] ARM: dts: colibri-imx6ull: Enable dual-role switching + +The Colibri standard provides a GPIO called USBC_DET to switch from +USB Host to USB Device and back. The Colibri iMX6ULL does have the SoC +ball USB_OTG1_VBUS connected in series with a capacitor to ground. + +This means that we need to provide to the extcon framework VBUS and ID +events using the single GPIO we have. The Extcon USB GPIO driver does +use id-gpio also for VBUS event, as in our case where vbus-gpio is +absent. + +Upstream-Status: Submitted [https://lore.kernel.org/linux-devicetree/20221102155226.51587-1-dev@pschenker.ch] + +Signed-off-by: Philippe Schenker <philippe.schenker@toradex.com> +--- + arch/arm/boot/dts/imx6ull-colibri.dtsi | 8 ++++++++ + 1 file changed, 8 insertions(+) + +diff --git a/arch/arm/boot/dts/imx6ull-colibri.dtsi b/arch/arm/boot/dts/imx6ull-colibri.dtsi +index 577a424b0e1d..feb1fcd9a684 100644 +--- a/arch/arm/boot/dts/imx6ull-colibri.dtsi ++++ b/arch/arm/boot/dts/imx6ull-colibri.dtsi +@@ -24,6 +24,13 @@ backlight: backlight { + status = "okay"; + }; + ++ extcon_usbc_det: usbc-det { ++ compatible = "linux,extcon-usb-gpio"; ++ id-gpio = <&gpio5 2 GPIO_ACTIVE_HIGH>; /* SODIMM 137 / USBC_DET */ ++ pinctrl-names = "default"; ++ pinctrl-0 = <&pinctrl_snvs_usbc_det>; ++ }; ++ + gpio-keys { + compatible = "gpio-keys"; + pinctrl-names = "default"; +@@ -275,6 +282,7 @@ &uart5 { + /* Colibri USBC */ + &usbotg1 { + dr_mode = "otg"; ++ extcon = <&extcon_usbc_det>, <&extcon_usbc_det>; + srp-disable; + hnp-disable; + adp-disable; +-- +2.38.0 + |