This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Linux/PROCESSOR-SDK-AM335X: usb VBUS_ERROR in ti sdk 03_03_00_04

Part Number: PROCESSOR-SDK-AM335X
Other Parts Discussed in Thread: AM3352, TPS2051B, TPS2051

Tool/software: Linux

We connect the usb ethernet chip lan9500 to am3352 with newest sdk

there is one board ,it always report such error  what is wong ?

[ 13.183492] musb-hdrc musb-hdrc.1.auto: new USB bus registered, assigned bus number 2
[ 13.206436] hub 2-0:1.0: USB hub found
[ 13.210284] hub 2-0:1.0: 1 port detected
Starting Synchronize System and HW clocks...
[[0;32m OK [0m] Reached target System Time Synchronized.
[[0;32m OK [0m] Started Synchronize System and HW clocks.
[ 13.833306] usb 2-1: new high-speed USB device number 2 using musb-hdrc
[[0;32m OK [0m] Reached target System Initialization.
[[0;32m OK [0m] Started Daily Cleanup of Temporary Directories.
[[0;32m OK [0m] Listening on RPCbind Server Activation Socket.
[[0;32m OK [0m] Started DLS test timer.
[[0;32m OK [0m] Reached target Timers.
[[0;32m OK [0m] Listening on D-Bus System Message Bus Socket.
[[0;32m OK [0m] Listening on dropbear.socket.
[[0;32m OK [0m] Reached target Sockets.
[ 14.060873] musb-hdrc musb-hdrc.1.auto: VBUS_ERROR in a_wait_vrise (88, <AValid), retry #3, port1 000a050f
[[0;32m OK [0m] Reached target Basic System.
Starting telnetd.service...
[[0;32m OK [0m] Started Kernel Logging Service.
Starting Permit User Sessions...

[ 14.941082] net eth1: initializing cpsw version 1.12 (0)
[ 14.953029] net eth0: initialized cpsw ale version 1.4
[ 14.975110] net eth0: ALE Table size 1024
[ 14.982559] net eth1: phy found : id is : 0x7c0f1
[ 15.029979] IPv6: ADDRCONF(NETDEV_UP): eth1: link is not ready
[ 15.075665] net eth0: initializing cpsw version 1.12 (0)
[ 15.099128] net eth0: phy found : id is : 0x7c0f1
[ 15.122511] IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
[[0;32m OK [0m] Started Login Service.
[[0;32m OK [0m] Reached target Network.
[[0;32m OK [0m] Started Omap Server.
Starting Ftp Server...
Starting Network Name Resolution...
[[0;32m OK [0m] Started Getty on tty1.
[[0;32m OK [0m] Started Serial Getty on ttyS0.
[[0;32m OK [0m] Reached target Login Prompts.
Starting rng-tools.service...
[[0;32m OK [0m] Started Ftp Server.
[[0;32m OK [0m] Started Network Name Resolution.
[ 16.417026] random: nonblocking pool is initialized
[[0;32m OK [0m] Started rng-tools.service.
[[0;32m OK [0m] Reached target Multi-User System.
Starting Update UTMP about System Runlevel Changes...
[[0;32m OK [0m] Started Update UTMP about System Runlevel Changes.

DLS login: [ 17.994299] cpsw 4a100000.ethernet eth1: Link is Up - 100Mbps/Full - flow control rx/tx
[ 18.002516] IPv6: ADDRCONF(NETDEV_CHANGE): eth1: link becomes ready
[ 18.114276] cpsw 4a100000.ethernet eth0: Link is Up - 100Mbps/Full - flow control rx/tx
[ 18.122497] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
[ 18.953540] usb 2-1: device descriptor read/64, error -110
[ 34.183487] usb 2-1: device descriptor read/64, error -110
[ 34.413489] usb 2-1: new high-speed USB device number 3 using musb-hdrc
[ 39.533487] usb 2-1: device descriptor read/64, error -110
[ 54.763489] usb 2-1: device descriptor read/64, error -110
[ 54.993544] usb 2-1: new high-speed USB device number 4 using musb-hdrc
[ 65.413502] usb 2-1: device not accepting address 4, error -110
[ 65.533493] usb 2-1: new high-speed USB device number 5 using musb-hdrc
[ 75.953490] usb 2-1: device not accepting address 5, error -110
[ 75.959654] usb usb2-port1: unable to enumerate USB device
[ 76.183601] usb usb2-port1: over-current condition
[ 76.503492] usb 2-1: new full-speed USB device number 6 using musb-hdrc
[ 78.422025] musb-hdrc musb-hdrc.1.auto: VBUS_ERROR in a_host (88, <AValid), retry #3, port1 000b010d
[ 81.783600] usb usb2-port1: over-current condition
[ 82.183494] usb 2-1: new full-speed USB device number 7 using musb-hdrc
[ 85.951800] musb-hdrc musb-hdrc.1.auto: VBUS_ERROR in a_wait_vrise (88, <AValid), retry #3, port1 000b010d
[ 87.463603] usb usb2-port1: over-current condition
[ 87.863493] usb 2-1: new full-speed USB device number 8 using musb-hdrc
[ 90.115936] musb-hdrc musb-hdrc.1.auto: VBUS_ERROR in a_host (88, <AValid), retry #3, port1 000b010d
[ 93.143600] usb usb2-port1: over-current condition
[ 93.543561] usb 2-1: new full-speed USB device number 9 using musb-hdrc
[ 95.436875] musb-hdrc musb-hdrc.1.auto: VBUS_ERROR in a_host (88, <AValid), retry #3, port1 000b010d
[ 98.823600] usb usb2-port1: over-current condition
[ 99.223544] usb 2-1: new high-speed USB device number 10 using musb-hdrc
[ 101.123722] musb-hdrc musb-hdrc.1.auto: VBUS_ERROR in a_host (88, <AValid), retry #3, port1 000b010d
[ 109.763485] usb 2-1: device not accepting address 10, error -110
[ 110.043584] usb usb2-port1: over-current condition
[ 110.443494] usb 2-1: new high-speed USB device number 12 using musb-hdrc
[ 111.776783] musb-hdrc musb-hdrc.1.auto: VBUS_ERROR in a_host (88, <AValid), retry #3, port1 000b010d
[ 115.723604] usb usb2-port1: over-current condition
[ 116.123544] usb 2-1: new high-speed USB device number 13 using musb-hdrc
[ 118.058468] musb-hdrc musb-hdrc.1.auto: VBUS_ERROR in a_host (88, <AValid), retry #3, port1 000b010d
[ 121.403646] usb usb2-port1: over-current condition
[ 121.683495] usb 2-1: new full-speed USB device number 14 using musb-hdrc
[ 122.023511] usb 2-1: new high-speed USB device number 15 using musb-hdrc
[ 123.848850] musb-hdrc musb-hdrc.1.auto: VBUS_ERROR in a_host (88, <AValid), retry #3, port1 000b010d
[ 127.303619] usb usb2-port1: over-current condition
[ 127.583493] usb 2-1: new full-speed USB device number 16 using musb-hdrc

What does the VBUS_ERROR in a_wait_vrise  mean? Is the OTG  waiting for the VBus over than 4.6v  of the A device threhold? 

And what is the state a_host mean?

there is another board ,when we use the old 3.2.0 version it report VBUS_ERROR like the following photo ,are they meet the same error ?

  • Hi Liang,

    If VBUS drops below 4.4 volts the USB subsystem in AM335x will assume an over-current condition and disconnect. The product design must insure VBUS does not drop below 4.4 volts because that is considered the minimum voltage for VBUS to be valid.

    See the below e2e threads for details:

    e2e.ti.com/.../589783
    e2e.ti.com/.../476837
    e2e.ti.com/.../324491
    e2e.ti.com/.../593133

    Regards,
    Pavel
  • Hello Pavel:
    we remove the drvvbus control of am335x and make tps2051B output 5V directly to my lan9500ai.
    At first it work seems fine,but later
    It report that VBUS_ERROR in a_host (89, <AValid), retry #1, port1 00000507
    We have use the scope to capture the VBUS which connect to the am335x ,there is no drop ,it always 5.1v .
    I look through the bf527 datasheet which also use the musb,
    the VBUS ERROR mean VBUS below VBUS Valid threshold detected (valid when USB is 'A' device)
    a_host (89, <AValid) should mean that the devctl register 1 - 'B' device detected 11 - Above VBUS valid
    I guess the am335x musb turn to B device。
    The voltage should above the valid thredhold.
    Why there is VBUS error?
    Regards
    wangl
  • Please post the usb portion of the schematics for review.
    Please ensure you have a minimum 120uF CAP on the VBUS line, this is required in the USB Spec for USB host port.
  • hi Bin:

    Is it fine to add an 220uF cap on the VBUS line?And can you tell me which spec define the requirement?

  • Though there is no 120uF cap on VBUS line,I remove the FB26 ,I add the +5v from DC regulated power supply to C214, VBUS should  never drop.

    But it report the 0x89   VBUS_ERROR   in a_host(89, <AValid).

    Is there any other reason for it become a B device?

    I will add the 220uF cap to our other boards parralel with C169 ,is it correct?Or I add the the cap to parralel with c171?

    Best regards

    wangl.

  • The 120uF CAP is needed no matter how the input power source to the power switch is connected. The cap is for compensating the inrush current while usb device attaching which could cause VBUS_ERROR.

    Please add the cap next to C171, not to C169. It should be on the output side of the power switch, so that USB1_VBUS pin can sense it.

    BTY, R60 and R61 are too big for grounding the USB ID pin, please replace them with 0R resisters.
  • LIANG WANG102707 said:

    Is it fine to add an 220uF cap on the VBUS line?And can you tell me which spec define the requirement?

    Please check the USB2.0 Spec, Section 7.2.4.1 (Inrush Current Limiting).
    And yes, 220uF is fine.
  • hi Bin :
    We have done the change add the CAP and use an stable power chip for usb before the tps2051,howerver ,it come out again.

    When we do the high temperature test of our board in 70 degree 
    It report
    [11.969571]dsps_interrrupt 360 VBUS error workaround(delay coming)
    [12.065857] musb-hdrc musb-hdrc.1.auto :VBUS_ERROR in a _wait_vrise(89,<AValid),retry #1,port1 00000100
    [12.119341] musb-hdrc musb-hdrc.1.auto :VBUS_ERROR in a _wait_vrise(89,<AValid),retry #2,port1 00000104
    [12.172778] musb-hdrc musb-hdrc.1.auto :VBUS_ERROR in a _wait_vrise(89,<AValid),retry #3,port1 00000104
    I look the code the differece between the interrupt flag of the past is the
    1 << wrp->drvvbus.
    what is the mean of this bit set?
    Why there is still this error?

    Regards
    wangl

  • LIANG WANG102707 said:
    When we do the high temperature test of our board in 70 degree 
    It report
    [11.969571]dsps_interrrupt 360 VBUS error workaround(delay coming)

    Do you mean after added the VBUS CAP, the VBUS error only happens in high temperature, but not in normal temperature?

    LIANG WANG102707 said:
    1 << wrp->drvvbus.
    what is the mean of this bit set?

    wrp->drvvbus is defined in am33xx_driver_data in musb_dsps.c, it is the bit field for the DRVVBUS interrupt.

  • Hello,

    1) Does this issue occur at all temperatures, or only at high-temp?

    2) What percentage of boards are affected by this issue?

  • >>Do you mean after added the VBUS CAP, the VBUS error only happens in high temperature, but not in normal temperature?
    after added the VBUS CAP, [11.969571]dsps_interrrupt 360 VBUS error workaround(delay coming) come out in high temperature.
    it is come out on usb1, The usb0 is configure as usb host with A connector.The usb1 is connect with lan9500 in our system.
    but I do see the lan9500 is enumerate fine later.
    But I ask our hardware guy,they said that they do not have 220uF cap ,they use two 100uF cap instead for usb0 and usb1 ,is it fine?
    >>wrp->drvvbus is defined in am33xx_driver_data in musb_dsps.c, it is the bit field for the DRVVBUS interrupt.
    why this bit is set ?When this bit set ,what does it mean?Is it mean DRVVBUS pin can not be set to high level by hardware?
    The technical reference manual said that "The control on the USB_DRVVBUS is automatic and is handled by the USB controller."
    Why there is such interrupt occured?

    There is still such error in normal temperature:
    musb-hdrc musb-hdrc.0.auto :VBUS_ERROR in a _wait_vrise(89,<AValid),retry #1,port1 00000100
    musb-hdrc musb-hdrc.0.auto :VBUS_ERROR in a _wait_vrise(89,<AValid),retry #2,port1 00000100
    musb-hdrc musb-hdrc.0.auto :VBUS_ERROR in a _wait_vrise(89,<AValid),retry #3,port1 00000104
    musb-hdrc musb-hdrc.0.auto :VBUS_ERROR in a _wait_vrise(88,<AValid),retry #3,port1 0000010c
    and then I insert the usb disk ,the system can not recognize the usb new device insert.
  • LIANG WANG102707 said:
    >>wrp->drvvbus is defined in am33xx_driver_data in musb_dsps.c, it is the bit field for the DRVVBUS interrupt.
    why this bit is set ?When this bit set ,what does it mean?Is it mean DRVVBUS pin can not be set to high level by hardware?
    The technical reference manual said that "The control on the USB_DRVVBUS is automatic and is handled by the USB controller."
    Why there is such interrupt occured?

    While the MUSB controller enters the host mode, it enables USBx_DRVVBUS pin to turn on the VBUS power switch, and the controller also generates the DRVVBUS interrupt to notify the software.

    LIANG WANG102707 said:
    There is still such error in normal temperature:

    So the 220uF CAP doesn't change any of the symptom, right? Just trying to understand if you mentioning high-temp is anything new or not.

    I am unable to think of any other reason why VBUS error happens. Please use a scope to probe the AM335x USB1_DRVVBUS and USB1_VBUS pins simultaneously to see if there is any VBUS drop.

  • LIANG WANG102707 said:
    There is still such error in normal temperature:
    musb-hdrc musb-hdrc.0.auto :VBUS_ERROR in a _wait_vrise(89,<AValid),retry #1,port1 00000100
    musb-hdrc musb-hdrc.0.auto :VBUS_ERROR in a _wait_vrise(89,<AValid),retry #2,port1 00000100
    musb-hdrc musb-hdrc.0.auto :VBUS_ERROR in a _wait_vrise(89,<AValid),retry #3,port1 00000104
    musb-hdrc musb-hdrc.0.auto :VBUS_ERROR in a _wait_vrise(88,<AValid),retry #3,port1 0000010c

    Wait a minute, this message happens on USB0 port, which has nothing connected, right? You don't see this message on USB0 port before adding the VBUS CAP on USB1 port?

    Did you add CAP on USB0 port as while, since USB0 is also a host-only port?

  • >>Wait a minute, this message happens on USB0 port, which has nothing connected, right? You don't see this message on USB0 port before >>adding the VBUS CAP on USB1 port?
    There is a industry USB disk connected on usb0 when it boot ,but the host do not recognize the usb
    There is two 100uF cap on the usb0 port too.
  • >>So the 220uF CAP doesn't change any of the symptom, right?
    It seems does not change. The" dsps_interrupt 360 :VBUS error workaround " happen almost in high temperature.
    But it also come out in normal temperature .

    Is there anyway to change the code to configure the musb as usb host directly and do not change otg role according to the VBUS?

    I want to change the hardware to output directly without the control of VBUSDRV

  • Can you please answer DK's query "What percentage of boards are affected by this issue"?

    LIANG WANG102707 said:

    Is there anyway to change the code to configure the musb as usb host directly and do not change otg role according to the VBUS?

    I want to change the hardware to output directly without the control of VBUSDRV

    The USB controller on AM335x is a dual-role controller, some of the role changing work is done in the hardware, so there is no true host-only mode.

    The VBUS error is detected in the hardware, removing DRVVBUS control doesn't solve the issue. We should figure out the root cause of the issue so that we will know how to properly fix it.

  • >>1) Does this issue occur at all temperatures, or only at high-temp?
    as I said in last reply ,it occur at all temperature ,but the mostly in high temperature.
    >>2) What percentage of boards are affected by this issue?
    the percentage is meaningless.

    Because we only have 9 boards can work.

    Only one board do not meet the VBUS error before add the cap and DC regulator in the high temperature test.
    we only test two board in high temp environment after add the cap and DC regulator.
    The one never meet the VBUS error also report the dsps vbus error and drvbus interrupt after add the cap and DC regulator in the high temperature test.

    It means 100%.

  • Do you mean the VBUS error is hardware problem?
    Is there any method to debug in the kernel?Or do you have any idea how to fix it?
    Is it an usb bug in kernel?Or it is an hardware bug in usb controller?
  • LIANG WANG102707 said:
    Do you mean the VBUS error is hardware problem?
    Is there any method to debug in the kernel?Or do you have any idea how to fix it?
    Is it an usb bug in kernel?Or it is an hardware bug in usb controller?

    It is an VBUS error condition reported by the hardware, in which the VBUS drops below 4.4v. The common root cause is the VBUS doesn't have enough capacitance as required in the USB Spec. I don't think it is a kernel bug.

    Please boot the board without any usb devices connected to USB0 and USB1 port, and hook up the scope probes to USBx_DRVVBUS and USBx_VBUS pins where close to AM335x, then plug in the USB device and use the scope to capture the signals of the two pins. We want to check if USBx_VBUS indeed drops while the USB device is attached.

  • Hello Bin:
    I have do the high temp again myself .
    When I use drvvbus to control the output of VBUS_USB to am335x ,I do found that there is an pulse of drvbus.
    The drvvbus jump from low to high ,then VBUS_USB is 5V.
    But VBUS_USB jump to below 4.4v soon ,then drvvbus jump from high to low.
    Then VBUS_USB is 0v steady,and drvbus is low steady.
    Then I check the kernel output " dsps_interrupt 360 :VBUS error workaround ".
    This is correct according to your opinion.

    But what I strange is that when I do not use drvvbus to control the output of VBUS_USB,
    i make the tps2051 pin 4 hight to output VUSB_USB directly to am335x ,
    there is do no fall below 4.4v on scope .
    But there is still error like following and the lan9500 do not work.
    [ 13.806475] musb-hdrc musb-hdrc.1.auto: VBUS_ERROR in a_wait_vrise (81, <SessEnd), retry #1, port1 00000104
    [ 13.958900] musb-hdrc musb-hdrc.1.auto: VBUS_ERROR in a_wait_vrise (81, <SessEnd), retry #2, port1 00000104
    [ 14.263741] musb-hdrc musb-hdrc.1.auto: VBUS_ERROR in a_wait_vrise (80, <SessEnd), retry #3, port1 0008010c
    Does the VBUS_USB need some power and the current supply of our board is not big enough to enable the host feature?

    Can you give me some idea?
    Best regards
  • I have sent you the friendship request, which has my email address. Please email me your board schematics. What is the Processor SDK version you use?