Does i.MX6 u-boot for Linux BSP supports USB OTG Host mode?

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 
已解决

Does i.MX6 u-boot for Linux BSP supports USB OTG Host mode?

跳至解决方案
3,231 次查看
satoshishimoda
Senior Contributor I

Hi community,

I have a question about i.MX6 Linux BSP.

I want to know whether u-boot for i.MX6 Linux BSP (L3.0.35_4.1.0) supports USB OTG Host mode, because I could not find the code for USB OTG Host mode.

Could you let me know it?

And if it supports USB OTG Host, could you let me know what source code supports it?

Best Regards,

Satoshi Shimoda

标签 (5)
标记 (2)
0 项奖励
1 解答
1,447 次查看
fabio_estevam
NXP Employee
NXP Employee

In mainline U-boot:

drivers/usb/host/ehci-mx6.c

You can see the mx6 nitrogen board that supports USB host:

board/boundary/nitrogen6x/nitrogen6x.c

and its config file:

include/configs/nitrogen6x.h

在原帖中查看解决方案

0 项奖励
7 回复数
1,447 次查看
artyeffem
Contributor II

I'm using OTG Host mode to run USB-NET from U-boot, implemented per Fabio's references.  It works great after a soft reboot from userspace, but fails on a hard power-cycle.  The kernel/FDT seems to properly setup the USB ID pin to identify this as Host mode, but from U-boot the pin is not correctly read, always thinks its in Device mode.  What setup am I missing here?

0 项奖励
1,447 次查看
artyeffem
Contributor II

I was missing an IOMUX setup for the USB_OTG_ID, but am now getting failures in the ehci_submit_async().  The handshake fails with "EHCI fail timeout STS_ASS set".  Interestingly, now I hit this failure even after a soft reboot, where it was successful before my IOMUX fix.

0 项奖励
1,447 次查看
artyeffem
Contributor II

Argh... I was tinkering with the ethact environment variable earlier.  Do not set it to usb_ether.  You can let it stay as FEC, and will switch to the proper device, in my case mcs0.  All is well.

1,447 次查看
satoshishimoda
Senior Contributor I

Could you reply to me someone?

0 项奖励
1,447 次查看
fabio_estevam
NXP Employee
NXP Employee

Mainline U-boot does support USB host for mx6.

1,446 次查看
satoshishimoda
Senior Contributor I

Hi Fabio Estevam,

Thank you for your reply.

And could you let me know what code in u-boot set USB host if you prefer?

Best Regards,

Satoshi SHimoda

0 项奖励
1,448 次查看
fabio_estevam
NXP Employee
NXP Employee

In mainline U-boot:

drivers/usb/host/ehci-mx6.c

You can see the mx6 nitrogen board that supports USB host:

board/boundary/nitrogen6x/nitrogen6x.c

and its config file:

include/configs/nitrogen6x.h

0 项奖励