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.

USB problem with onboard 3G Modem

Other Parts Discussed in Thread: TPS2051

Hello, 

We buit a custom AM335x board with a onboard USB hub connected to a USB connector and a onboard modem. We are working with linux-ti-staging from Yocto (fido). Kernel version is 3.14.49-ge9cd4cc819.

During the startup, the hub is well detected and everything is ready :

[    4.446515] musb-hdrc musb-hdrc.1.auto: MUSB HDRC host driver
[    4.452835] musb-hdrc musb-hdrc.1.auto: new USB bus registered, assigned bus number 2
[    4.460886] usb usb2: New USB device found, idVendor=1d6b, idProduct=0002
[    4.467756] usb usb2: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    4.475009] usb usb2: Product: MUSB HDRC host driver
[    4.480006] usb usb2: Manufacturer: Linux 3.14.49-ge9cd4cc819 musb-hcd
[    4.486568] usb usb2: SerialNumber: musb-hdrc.1.auto
[    4.493258] hub 2-0:1.0: USB hub found
[    4.497163] hub 2-0:1.0: 1 port detected
[    4.775454] musb-hdrc musb-hdrc.1.auto: otg: usb_otg_kick_fsm: invalid host/gadget device
[    4.925346] usb 2-1: new high-speed USB device number 2 using musb-hdrc
[    5.085504] usb 2-1: device v0424 p2513 is not supported
[    5.090865] usb 2-1: New USB device found, idVendor=0424, idProduct=2513
[    5.097636] usb 2-1: New USB device strings: Mfr=0, Product=0, SerialNumber=0
[    5.129778] hub 2-1:1.0: USB hub found
[    5.144167] hub 2-1:1.0: 3 ports detected

Since we power up the modem (connected on the port 2 of the hub) (by enabling his power supply with a GPIO), the USB Hub disconnect and I got some strange errors :

[   76.540271] usb 2-1.2: device v058b p0041 is not supported
[   76.545889] usb 2-1.2: New USB device found, idVendor=058b, idProduct=0041
[   76.552820] usb 2-1.2: New USB device strings: Mfr=0, Product=0, SerialNumber=0
[   76.568288] cdc_acm 2-1.2:1.0: This device cannot do calls on its own. It is not a modem.
[   76.580522] cdc_acm 2-1.2:1.0: ttyACM0: USB ACM device
[   77.861933] usb 2-1.2: USB disconnect, device number 10
[   78.115549] usb 2-1.2: new high-speed USB device number 11 using musb-hdrc
[   83.245787] usb 2-1.2: unable to read config index 0 descriptor/start: -110
[   83.252827] usb 2-1.2: can't read configurations, error -110
[   83.335523] usb 2-1.2: new high-speed USB device number 12 using musb-hdrc
[   85.195502] musb-hdrc musb-hdrc.1.auto: otg: usb_otg_kick_fsm: invalid host/gadget device
[   85.315631] usb 2-1: reset high-speed USB device number 2 using musb-hdrc
[   85.775563] musb-hdrc musb-hdrc.1.auto: otg: usb_otg_kick_fsm: invalid host/gadget device
[   85.895525] usb 2-1: reset high-speed USB device number 2 using musb-hdrc
[   86.355555] musb-hdrc musb-hdrc.1.auto: otg: usb_otg_kick_fsm: invalid host/gadget device
[   86.475505] usb 2-1: reset high-speed USB device number 2 using musb-hdrc
[   86.895582] usb 2-1: USB disconnect, device number 2
[   86.908415] musb-hdrc musb-hdrc.1.auto: otg: usb_otg_kick_fsm: invalid host/gadget device
[   87.035514] usb 2-1: new high-speed USB device number 13 using musb-hdrc
[   87.495556] musb-hdrc musb-hdrc.1.auto: otg: usb_otg_kick_fsm: invalid host/gadget device
[   87.615542] usb 2-1: new high-speed USB device number 14 using musb-hdrc
[   88.075541] musb-hdrc musb-hdrc.1.auto: otg: usb_otg_kick_fsm: invalid host/gadget device
[   88.195500] usb 2-1: new high-speed USB device number 15 using musb-hdrc

The error repeats in loop... As you can see the USB 2-1 Hub has been deconnected.

If I put a normal USB device on the USB connector and starts the 3G modem, it works...

[  149.295433] usb 2-1.2: new high-speed USB device number 4 using musb-hdrc
[  149.416738] usb 2-1.2: config 1 interface 0 altsetting 0 endpoint 0x81 has an invalid bInterval 255, changing to 11
[  149.427719] usb 2-1.2: device v058b p0041 is not supported
[  149.433264] usb 2-1.2: New USB device found, idVendor=058b, idProduct=0041
[  149.440254] usb 2-1.2: New USB device strings: Mfr=0, Product=0, SerialNumber=0
[  149.485639] cdc_acm 2-1.2:1.0: This device cannot do calls on its own. It is not a modem.
[  149.497124] cdc_acm 2-1.2:1.0: ttyACM0: USB ACM device
[  150.506353] usbcore: registered new interface driver cdc_acm
[  150.512083] cdc_acm: USB Abstract Control Model driver for USB modems and ISDN adapters
[  150.592229] usb 2-1.2: USB disconnect, device number 4
[  150.845417] usb 2-1.2: new high-speed USB device number 5 using musb-hdrc
[  155.975362] usb 2-1.2: unable to read config index 0 descriptor/start: -110
[  155.982395] usb 2-1.2: can't read configurations, error -110
[  156.065641] usb 2-1.2: new high-speed USB device number 6 using musb-hdrc
[  159.275334] usb 2-1.2: new high-speed USB device number 7 using musb-hdrc
[  159.406527] usb 2-1.2: device v1519 p0020 is not supported
[  159.412082] usb 2-1.2: New USB device found, idVendor=1519, idProduct=0020
[  159.419063] usb 2-1.2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[  159.426451] usb 2-1.2: Product: 7 CDC-ACM
[  159.430498] usb 2-1.2: Manufacturer: Comneon
[  159.434802] usb 2-1.2: SerialNumber: 359516050026378
[  159.483190] cdc_acm 2-1.2:1.0: This device cannot do calls on its own. It is not a modem.
[  159.493954] cdc_acm 2-1.2:1.0: ttyACM0: USB ACM device
[  159.506469] cdc_acm 2-1.2:1.2: This device cannot do calls on its own. It is not a modem.
[  159.518067] cdc_acm 2-1.2:1.2: ttyACM1: USB ACM device
[  159.530018] cdc_acm 2-1.2:1.4: This device cannot do calls on its own. It is not a modem.
[  159.541207] cdc_acm 2-1.2:1.4: ttyACM2: USB ACM device
[  159.553218] cdc_acm 2-1.2:1.6: This device cannot do calls on its own. It is not a modem.
[  159.564640] cdc_acm 2-1.2:1.6: ttyACM3: USB ACM device
[  159.577133] cdc_acm 2-1.2:1.8: This device cannot do calls on its own. It is not a modem.
[  159.588558] cdc_acm 2-1.2:1.8: ttyACM4: USB ACM device
[  159.600369] cdc_acm 2-1.2:1.10: This device cannot do calls on its own. It is not a modem.
[  159.612768] cdc_acm 2-1.2:1.10: ttyACM5: USB ACM device
[  159.624800] cdc_acm 2-1.2:1.12: This device cannot do calls on its own. It is not a modem.
[  159.636679] cdc_acm 2-1.2:1.12: ttyACM6: USB ACM device

I'm really lost with this behavior... Has somebody an idea ?

  • Hi,

    I will ask the USB experts to look at this.
  • Feedback from the USB team is that this seems like a hardware issue. Did you have your schematic reviewed by TI?
  • Hello,
    Not really, I did not know that was possible...
    Best regards
    Steve
  • Hi Steve,

    Why are you controlling the Hub's downstream power with a GPIO? The hub should control power to its DS ports as it is acting as the host in this case. Depending on your particular design, you may be confusing the Hub by supplying "VBUS" before the hub enables it.
  • Hi,

    No I only power the onboard USB 3G Modem with a GPIO, It requires 3.7V and we put a dedicated power supply for it.

    The VBUS is powered from the 5V of our board with a TPS2051. See a part of the schematic below :

  • I understand.

    You don't show the hub portion here, but I still think it's possible that you are confusing it. In this case, your USB modem is likely activating its USB DP pull-up immediately on power-up due to its VBUS being supplied from board power rather than a true 5V VBUS from the host (or the hub in your case). The hub would not expect to see the pull-up on DP until after it turns on VBUS as per the USB specification. If I understand your passing case correctly, you don't activate the modem until after the hub is up and running, which is what would be expected from a hub's perspective.

    The order of operations for a USB topology that implements a hub is:

    1) The host applies VBUS to the hub. The hub sees VBUS and activates its pull-up to signal the host that it is present.

    2) After the host configures the hub, the hub will apply VBUS to all downstream ports looking for attached devices.

    3) Any device attached downstream of the hub enables its pull-up to let the hub know it is present.

    4) The hub now reports attached devices to the host which then configures them.

    In your case, I believe you are skipping 1 and 2 by allowing the USB modem to enable its pull-up prior to the hub (or host for that matter) being ready for it.

  • Hello,

    If I'm not wrong, the TPS2051 will be enabled only from the hub (GSM_USB_PWR_EN, connected to PRTPWR2). So in every case, the USB_VBUS of the U108 (3G Modem) will only be powered since the hub has been initialized.

    After that, I'll power up my modem and the hub will detect it ? 

    Or I'm wrong ?

    I send you the hub part of the schematic. The port 1 is used externaly with a USB connector, the 2 is the 3G modem and the 3 is for futur usage on an extension board.

    Strange thing is that everythings works fine if I've a Memory Stick on the port 1... how can it change the behavior of the port 2 !!!

  • Just had a thought...is the hub entering suspend mode with just the modem enabled? The memory stick being attached will prevent the hub from suspending...
  • Hello,

    I've made an interesting test by using the 3G modem SDK card on the USB connector of our board (port1 on the hub) :

    Case 1 (working) :

    1. I boot my AM335x
    2. I powered up the SDK (by connecting the power supply)
    3. Make a pulse on ON signal on the modem SDK to start the modem
    4. Connect the USB cable
    5. Everything is working well

    Case 2 (same problem as with the onboard modem)

    1. I boot my AM335x WITH THE USB CABLE OF MODEM CONNECTED
    2. I power up the board
    3. Make a pulse on ON signal
    4. It fails as before

    So I think the problem should be in the hotplug part... This is a strange behavior since the official modem SDK makes the same problem.

    Any idea ?

    Best regards

    Steve 

  • I've done another test...

    By resetting the modem...

    echo 1 > /sys/class/gpio/gpio61/value
    echo 0 > /sys/class/gpio/gpio61/value
    [  549.738045] usb 2-1.2: USB disconnect, device number 3

    And starting it again :

    echo 1 > /sys/class/gpio/gpio68/value
    echo 0 > /sys/class/gpio/gpio68/value
    
    [  633.145572] usb 2-1.2: new high-speed USB device number 4 using musb-hdrc
    [  633.266940] usb 2-1.2: config 1 interface 0 altsetting 0 endpoint 0x81 has an invalid bInterval 255, changing to 11
    [  633.277884] usb 2-1.2: device v058b p0041 is not supported
    [  633.283428] usb 2-1.2: New USB device found, idVendor=058b, idProduct=0041
    [  633.290414] usb 2-1.2: New USB device strings: Mfr=0, Product=0, SerialNumber=0
    [  633.307380] cdc_acm 2-1.2:1.0: This device cannot do calls on its own. It is not a modem.
    [  633.324566] cdc_acm 2-1.2:1.0: ttyACM0: USB ACM device
    [  634.602076] usb 2-1.2: USB disconnect, device number 4
    [  634.855568] usb 2-1.2: new high-speed USB device number 5 using musb-hdrc
    [  639.985592] usb 2-1.2: unable to read config index 0 descriptor/start: -110
    [  639.992630] usb 2-1.2: can't read configurations, error -110
    [  640.075557] usb 2-1.2: new high-speed USB device number 6 using musb-hdrc
    [  642.105536] musb-hdrc musb-hdrc.1.auto: otg: usb_otg_kick_fsm: invalid host/gadget device
    [  642.225619] usb 2-1: reset high-speed USB device number 2 using musb-hdrc
    [  642.685546] musb-hdrc musb-hdrc.1.auto: otg: usb_otg_kick_fsm: invalid host/gadget device
    [  642.806114] usb 2-1: reset high-speed USB device number 2 using musb-hdrc
    [  643.265550] musb-hdrc musb-hdrc.1.auto: otg: usb_otg_kick_fsm: invalid host/gadget device
    [  643.385545] usb 2-1: reset high-speed USB device number 2 using musb-hdrc
    [  643.805663] usb 2-1: USB disconnect, device number 2
    [  643.818617] musb-hdrc musb-hdrc.1.auto: otg: usb_otg_kick_fsm: invalid host/gadget device
    [  643.945597] usb 2-1: new high-speed USB device number 7 using musb-hdrc
    [  644.405600] musb-hdrc musb-hdrc.1.auto: otg: usb_otg_kick_fsm: invalid host/gadget device
    [  644.525538] usb 2-1: new high-speed USB device number 8 using musb-hdrc
    [  644.985600] musb-hdrc musb-hdrc.1.auto: otg: usb_otg_kick_fsm: invalid host/gadget device
    [  645.105535] usb 2-1: new high-speed USB device number 9 using musb-hdrc
    [  645.525586] musb-hdrc musb-hdrc.1.auto: otg: usb_otg_kick_fsm: invalid host/gadget device
    [  645.645592] usb 2-1: new high-speed USB device number 10 using musb-hdrc
    [  646.175630] musb-hdrc musb-hdrc.1.auto: otg: usb_otg_kick_fsm: invalid host/gadget device
    [  646.295544] usb 2-1: new high-speed USB device number 11 using musb-hdrc
    [  646.755606] musb-hdrc musb-hdrc.1.auto: otg: usb_otg_kick_fsm: invalid host/gadget device
    [  646.875537] usb 2-1: new high-speed USB device number 12 using musb-hdrc
    [  647.335555] musb-hdrc musb-hdrc.1.auto: otg: usb_otg_kick_fsm: invalid host/gadget device
    [  647.455565] usb 2-1: new high-speed USB device number 13 using musb-hdrc
    [  647.875569] musb-hdrc musb-hdrc.1.auto: otg: usb_otg_kick_fsm: invalid host/gadget device
    [  647.995535] usb 2-1: new high-speed USB device number 14 using musb-hdrc
    [  648.525650] musb-hdrc musb-hdrc.1.auto: otg: usb_otg_kick_fsm: invalid host/gadget device
    [  648.645550] usb 2-1: new high-speed USB device number 15 using musb-hdrc
    [  649.105580] musb-hdrc musb-hdrc.1.auto: otg: usb_otg_kick_fsm: invalid host/gadget device
    ...

    USB stop working...

    And now... doing a 

    rmmod musb_dsps
    modprobe musb_dsps
    
    

    The modem is well detected...

    [  693.176660] musb-hdrc musb-hdrc.0.auto: MUSB HDRC host driver
    [  693.183682] musb-hdrc musb-hdrc.0.auto: new USB bus registered, assigned bus number 1
    [  693.193211] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002
    [  693.200138] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
    [  693.207443] usb usb1: Product: MUSB HDRC host driver
    [  693.212449] usb usb1: Manufacturer: Linux 3.14.49-ge9cd4cc819 musb-hcd
    [  693.219051] usb usb1: SerialNumber: musb-hdrc.0.auto
    [  693.227072] hub 1-0:1.0: USB hub found
    [  693.230950] hub 1-0:1.0: 1 port detected
    [  693.250194] musb-hdrc musb-hdrc.1.auto: MUSB HDRC host driver
    [  693.259934] musb-hdrc musb-hdrc.1.auto: new USB bus registered, assigned bus number 2
    [  693.268659] usb usb2: New USB device found, idVendor=1d6b, idProduct=0002
    [  693.275575] usb usb2: New USB device strings: Mfr=3, Product=2, SerialNumber=1
    [  693.282850] usb usb2: Product: MUSB HDRC host driver
    [  693.287885] usb usb2: Manufacturer: Linux 3.14.49-ge9cd4cc819 musb-hcd
    [  693.294460] usb usb2: SerialNumber: musb-hdrc.1.auto
    [  693.302412] hub 2-0:1.0: USB hub found
    [  693.306370] hub 2-0:1.0: 1 port detected
    [  693.705948] usb 2-1: new high-speed USB device number 2 using musb-hdrc
    [  693.845757] usb 2-1: device v0424 p2513 is not supported
    [  693.851133] usb 2-1: New USB device found, idVendor=0424, idProduct=2513
    [  693.857941] usb 2-1: New USB device strings: Mfr=0, Product=0, SerialNumber=0
    [  693.874463] hub 2-1:1.0: USB hub found
    [  693.883862] hub 2-1:1.0: 3 ports detected
    [  694.165562] usb 2-1.2: new high-speed USB device number 3 using musb-hdrc
    [  694.296162] usb 2-1.2: device v1519 p0020 is not supported
    [  694.301711] usb 2-1.2: New USB device found, idVendor=1519, idProduct=0020
    [  694.308687] usb 2-1.2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
    [  694.316087] usb 2-1.2: Product: 7 CDC-ACM
    [  694.320135] usb 2-1.2: Manufacturer: Comneon
    [  694.324440] usb 2-1.2: SerialNumber: 359516050026378
    [  694.377077] cdc_acm 2-1.2:1.0: This device cannot do calls on its own. It is not a modem.
    [  694.393401] cdc_acm 2-1.2:1.0: ttyACM0: USB ACM device
    [  694.406254] cdc_acm 2-1.2:1.2: This device cannot do calls on its own. It is not a modem.
    [  694.420492] cdc_acm 2-1.2:1.2: ttyACM1: USB ACM device
    [  694.432607] cdc_acm 2-1.2:1.4: This device cannot do calls on its own. It is not a modem.
    [  694.446944] cdc_acm 2-1.2:1.4: ttyACM2: USB ACM device
    [  694.459287] cdc_acm 2-1.2:1.6: This device cannot do calls on its own. It is not a modem.
    [  694.473050] cdc_acm 2-1.2:1.6: ttyACM3: USB ACM device
    [  694.485484] cdc_acm 2-1.2:1.8: This device cannot do calls on its own. It is not a modem.
    [  694.499301] cdc_acm 2-1.2:1.8: ttyACM4: USB ACM device
    [  694.511258] cdc_acm 2-1.2:1.10: This device cannot do calls on its own. It is not a modem.
    [  694.525187] cdc_acm 2-1.2:1.10: ttyACM5: USB ACM device
    [  694.538119] cdc_acm 2-1.2:1.12: This device cannot do calls on its own. It is not a modem.
    [  694.551220] cdc_acm 2-1.2:1.12: ttyACM6: USB ACM device
    

    But this is not a proper solution, just a poor workaround...

    So I think this is more an USB driver problem...

    Any idea ?

    BR

    Steve

  • Steve,

    Please add 'usbcore.autosuspend=-1' to your uboot bootargs to see if it changes any behavior.