Re: [PATCH v1 2/2] ARM: dts: colibri-imx6ull: add extcon for usbotg1

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Oct 21, 2019 at 07:16:54PM +0300, Igor Opaniuk wrote:
> From: Igor Opaniuk <igor.opaniuk@xxxxxxxxxxx>
> 
> Add extcon usb gpio configuration for support dual roles for usbotg1.
> 
> USB host/gadget switching test (1. USB NIC emulation; 2. USB storage):
> 
> [   52.491957] ci_hdrc ci_hdrc.1: switching to gadget role
> [   52.502911] mxs_phy 20c9000.usbphy: vbus is not valid
> [   56.749160] using random self ethernet address
> [   56.758637] using random host ethernet address
> [   65.768968] usb0: HOST MAC 00:14:2d:ff:ff:fe
> [   65.887980] usb0: MAC 00:14:2d:ff:ff:ff
> [   66.294961] configfs-gadget gadget: high-speed config #1: c
> [   78.741971] ci_hdrc ci_hdrc.1: switching to host role
> [   78.747522] ci_hdrc ci_hdrc.1: EHCI Host Controller
> [   78.790174] ci_hdrc ci_hdrc.1: new USB bus registered, assigned bus
> number 2
> [   78.868498] ci_hdrc ci_hdrc.1: USB 2.0 started, EHCI 1.00
> 
> Signed-off-by: Igor Opaniuk <igor.opaniuk@xxxxxxxxxxx>
> ---
> 
>  arch/arm/boot/dts/imx6ull-colibri-eval-v3.dtsi | 9 +++++++++
>  1 file changed, 9 insertions(+)
> 
> diff --git a/arch/arm/boot/dts/imx6ull-colibri-eval-v3.dtsi b/arch/arm/boot/dts/imx6ull-colibri-eval-v3.dtsi
> index a78849fd2afa..988f1a800d5a 100644
> --- a/arch/arm/boot/dts/imx6ull-colibri-eval-v3.dtsi
> +++ b/arch/arm/boot/dts/imx6ull-colibri-eval-v3.dtsi
> @@ -29,6 +29,14 @@
>  		clock-frequency = <16000000>;
>  	};
>  
> +	extcon_usbc_det: usbc_det {

Can we find a more generic name for the node?  Also hyphen is preferred
over underscore in node name.

Shawn

> +		compatible = "linux,extcon-usb-gpio";
> +		debounce = <25>;
> +		id-gpio = <&gpio5 2 GPIO_ACTIVE_HIGH>;
> +		pinctrl-names = "default";
> +		pinctrl-0 = <&pinctrl_snvs_usbc_det>;
> +	};
> +
>  	panel: panel {
>  		compatible = "edt,et057090dhu";
>  		backlight = <&bl>;
> @@ -150,6 +158,7 @@
>  };
>  
>  &usbotg1 {
> +	extcon = <&extcon_usbc_det &extcon_usbc_det>;
>  	status = "okay";
>  };
>  
> -- 
> 2.17.1
> 



[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux