2011-02-01 06:09:38     BF527 USB devices enumeration problem.

Document created by Aaronwu Employee on Aug 26, 2013
Version 1Show Document
  • View in full screen mode

2011-02-01 06:09:38     BF527 USB devices enumeration problem.

Sergei Zenkevich (BELARUS)

Message: 97839   

 

Hi,

 

We have the problem with the enumeration of a USB device. A USB device is enumerated only if it is connected during musb_hdrc module load. If we connect a USB device after loading of the musb_hdrc module or connect repeatedly it is not enumerated.

 

We are using the 2010R1 RC5 uClinux dist and BF527 rev. 0.2 custom board. musb CLKIN is 12 MHZ.

 

We have also been faced with this problem on BF526 EZ-Board. The similar problem is described in the

 

https://blackfin.uclinux.org/gf/project/uclinux-dist/forum/?_forum_action=ForumMessageBrowse&thread_id=44230&action=ForumBrowse&forum_id=39

 

 

Here is our console log.

 

Image Name: bf527-2.6.34.7-ADI-2010R1

Created: 2011-01-28 16:26:48 UTC

Image Type: Blackfin Linux Kernel Image (gzip compressed)

Data Size: 3137115 Bytes = 3 MiB

Load Address: 00001000

Entry Point: 001dc2b4

Verifying Checksum ... OK

Uncompressing Kernel Image ... OK

Starting Kernel at = 001dc2b4

Linux version 2.6.34.7-ADI-2010R1 (serge_z@ws-023) (gcc version 4.3.5 (ADI-2010R1-RC3) ) #40 Fri Jan 28 18:26:44 EET 2011

register early platform devices

bootconsole [early_shadow0] enabled

bootconsole [early_BFuart0] enabled

early printk enabled on early_BFuart0

Board Memory: 32MB

Kernel Managed Memory: 32MB

Memory map:

fixedcode = 0x00000400-0x00000490

text = 0x00001000-0x0014aeb8

rodata = 0x0014aeb8-0x001b3dd0

bss = 0x001b4000-0x001c55b8

data = 0x001c55b8-0x001d8000

stack = 0x001d6000-0x001d8000

init = 0x001d8000-0x0058f000

available = 0x0058f000-0x01f00000

DMA Zone = 0x01f00000-0x02000000

Hardware Trace Active and Enabled

Boot Mode: 7

Blackfin support (C) 2004-2010 Analog Devices, Inc.

Compiled for ADSP-BF527 Rev 0.2

Blackfin Linux support by   blackfin.uclinux.org/

Processor Speed: 387 MHz core clock and 48 MHz System Clock

NOMPU: setting up cplb tables

Instruction Cache Enabled for CPU0

External memory: cacheable in instruction cache

Data Cache Enabled for CPU0

External memory: cacheable (write-back) in data cache

Built 1 zonelists in Zone order, mobility grouping off. Total pages: 7874

Kernel command line: earlyprintk=serial,uart0,115200 console=ttyBF0,115200

PID hash table entries: 128 (order: -3, 512 bytes)

Dentry cache hash table entries: 4096 (order: 2, 16384 bytes)

Inode-cache hash table entries: 2048 (order: 1, 8192 bytes)

Memory available: 25764k/32768k RAM, (3804k init code, 1319k kernel code, 565k data, 1024k dma, 292k reserved)

Hierarchical RCU implementation.

NR_IRQS:159

Configuring Blackfin Priority Driven Interrupts

console [ttyBF0] enabled, bootconsole disabled

console [ttyBF0] enabled, bootconsole disabled

Calibrating delay loop... 770.04 BogoMIPS (lpj=1540096)

Security Framework initialized

Mount-cache hash table entries: 512

Blackfin Scratchpad data SRAM: 4 KB

Blackfin L1 Data A SRAM: 16 KB (16 KB free)

Blackfin L1 Data B SRAM: 16 KB (16 KB free)

Blackfin L1 Instruction SRAM: 48 KB (42 KB free)

NET: Registered protocol family 16

Blackfin DMA Controller

cm_init(): registering device resources

bio: create slab <bio-0> at 0

SCSI subsystem initialized

bfin-spi bfin-spi.0: Blackfin on-chip SPI Controller Driver, Version 1.0, regs_base@ffc00500, dma channel@7

usbcore: registered new interface driver usbfs

usbcore: registered new interface driver hub

usbcore: registered new device driver usb

NET: Registered protocol family 2

IP route cache hash table entries: 1024 (order: 0, 4096 bytes)

TCP established hash table entries: 1024 (order: 1, 8192 bytes)

TCP bind hash table entries: 1024 (order: 0, 4096 bytes)

TCP: Hash tables configured (established 1024 bind 1024)

TCP reno registered

UDP hash table entries: 256 (order: 0, 4096 bytes)

UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)

NET: Registered protocol family 1

JFFS2 version 2.2. (NAND) �© 2001-2006 Red Hat, Inc.

msgmni has been set to 50

io scheduler noop registered

io scheduler cfq registered (default)

bfin-otp: initialized

bfin-uart: Blackfin serial driver

bfin-uart.0: ttyBF0 at MMIO 0xffc00400 (irq = 29) is a BFIN-UART

brd: module loaded

BF5xx on-chip NAND FLash Controller Driver, Version 1.2 (c) 2007 Analog Devices, Inc.

bf5xx-nand bf5xx-nand.0: data_width=8, wr_dly=3, rd_dly=3

NAND device: Manufacturer ID: 0xec, Chip ID: 0x75 (Samsung NAND 32MiB 3,3V 8-bit)

Creating 2 MTD partitions on "NAND 32MiB 3,3V 8-bit":

0x000000000000-0x000000400000 : "linux kernel(nand)"

0x000000400000-0x000002000000 : "file system(nand)"

bfin_mii_bus: probed

bfin_mac: attached PHY driver [Generic PHY] (mii_bus:phy_addr=0:01, irq=-1, mdc_clk=2500000Hz(mdc_div=8)@sclk=48MHz)

bfin_mac bfin_mac.0: Blackfin on-chip Ethernet MAC driver, Version 1.1

rtc-bfin rtc-bfin: rtc core: registered rtc-bfin as rtc0

bfin-wdt: initialized: timeout=20 sec (nowayout=0)

TCP cubic registered

NET: Registered protocol family 17

rtc-bfin rtc-bfin: setting system clock to 1970-01-01 00:00:00 UTC (0)

dma_alloc_init: dma_page @ 0x013ba000 - 256 pages at 0x01f00000

Freeing unused kernel memory: 3804k freed

_____________________________________

a8888b. / Welcome to the uClinux distribution \

d888888b. / _ _ \

8P"YP"Y88 / | | |_| __ __ (TM) |

8|o||o|88 _____/ | | _ ____ _ _ \ \/ / |

8' .88 \ | | | | _ \| | | | \ / |

8`._.' Y8. \ | |__ | | | | | |_| | / \ |

d/ `8b. \ \____||_|_| |_|\____|/_/\_\ |

dP . Y8b. \ For embedded processors including |

d8:' " `::88b \ the Analog Devices Blackfin /

d8" 'Y88b \___________________________________/

:8P ' :888

8a. : _a88P For further information, check out:

._/"Yaa_: .| 88P| -   blackfin.uclinux.org/

\ YP" `| 8P `. -   docs.blackfin.uclinux.org/

/ \.___.d| .' -   www.uclinux.org/

`--..__)8888P`._.' jgs/a:f -   www.analog.com/blackfin

 

Have a lot of fun...

 

 

powered by

____ _ _ _ _

| __ )| |_ _ ___| |_ ___ ___| |__ _ __ (_)_ __

| _ \| | | | |/ _ \ __/ _ \/ __| '_ \| '_ \| \ \/ /

| |_) | | |_| | __/ || __/ (__| | | | | | | |> <

|____/|_|\__,_|\___|\__\___|\___|_| |_|_| |_|_/_/\_\

 

www.bluetechnix.com

 

 

BusyBox v1.16.2 (2011-01-19 13:19:16 EET) hush - the humble shell

Enter 'help' for a list of built-in commands.

 

root: /> modprobe musb_hdrc

musb_hdrc: version 6.0, pio, host, debug=0

musb_hdrc: ConfigData=0x00 (UTMI-8)

musb_hdrc: HDRC RTL version 1.900

musb_hdrc musb_hdrc.0: MUSB HDRC host driver

musb_hdrc musb_hdrc.0: new USB bus registered, assigned bus number 1

usb usb1: default language 0x0409

usb usb1: udev 1, busnum 1, minor = 0

usb usb1: New USB device found, idVendor=1d6b, idProduct=0002

usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1

usb usb1: Product: MUSB HDRC host driver

usb usb1: Manufacturer: Linux 2.6.34.7-ADI-2010R1 musb-hcd

usb usb1: SerialNumber: musb_hdrc.0

usb usb1: usb_probe_device

usb usb1: configuration #1 chosen from 1 choice

usb usb1: adding 1-0:1.0 (config #1, interface 0)

hub 1-0:1.0: usb_probe_interface

hub 1-0:1.0: usb_probe_interface - got id

hub 1-0:1.0: USB hub found

hub 1-0:1.0: 1 port detected

hub 1-0:1.0: standalone hub

hub 1-0:1.0: individual port power switching

hub 1-0:1.0: no over-current protection

hub 1-0:1.0: power on to power good time: 10ms

hub 1-0:1.0: local power source is good

hub 1-0:1.0: enabling power on all ports

musb_hdrc musb_hdrc.0: USB Host mode controller at ffc03800 using PIO, IRQ 59

root: /> hub 1-0:1.0: state 7 ports 1 chg 0000 evt 0000

hub 1-0:1.0: state 7 ports 1 chg 0000 evt 0002

hub 1-0:1.0: port 1, status 0101, change 0001, 12 Mb/s

hub 1-0:1.0: debounce: port 1: total 100ms stable 100ms status 0x101

usb 1-1: new high speed USB device using musb_hdrc and address 2

usb 1-1: default language 0x0409

usb 1-1: udev 2, busnum 1, minor = 1

usb 1-1: New USB device found, idVendor=058f, idProduct=6387

usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3

usb 1-1: Product: Mass Storage Device

usb 1-1: Manufacturer: JetFlash

usb 1-1: SerialNumber: T6AU2K6E

usb 1-1: usb_probe_device

usb 1-1: configuration #1 chosen from 1 choice

usb 1-1: adding 1-1:1.0 (config #1, interface 0)

hub 1-0:1.0: state 7 ports 1 chg 0000 evt 0002

hub 1-0:1.0: port 1 enable change, status 00000503

 

root: /> hub 1-0:1.0: state 7 ports 1 chg 0000 evt 0002

hub 1-0:1.0: port 1, status 0100, change 0001, 12 Mb/s

usb 1-1: USB disconnect, address 2

usb 1-1: unregistering device

usb 1-1: usb_disable_device nuking all URBs

usb 1-1: unregistering interface 1-1:1.0

hub 1-0:1.0: debounce: port 1: total 100ms stable 100ms status 0x100

 

root: />

 

 

At this point the USB stick was connected again but no messages was displayed.

QuoteReplyEditDelete

 

 

2011-02-01 10:15:41     Re: BF527 USB devices enumeration problem.

Mike Frysinger (UNITED STATES)

Message: 97844   

 

post the output of `lsusb -t`.  make sure the usb device you're plugging in does not have any hubs built into it.

QuoteReplyEditDelete

 

 

2011-02-02 07:46:13     Re: BF527 USB devices enumeration problem.

Sergei Zenkevich (BELARUS)

Message: 97869   

 

Here the output of lsusb and cat /proc/bus/usb/devices. We use the simple USB stick without internal hub.

 

root: /> modprobe musb_hdrc

 

musb_hdrc: version 6.0, pio, host, debug=0 

musb_hdrc: ConfigData=0x00 (UTMI-8)

musb_hdrc: HDRC RTL version 1.900

musb_hdrc musb_hdrc.0: MUSB HDRC host driver

drivers/usb/core/inode.c: creating file 'devices'

drivers/usb/core/inode.c: creating file '001'

musb_hdrc musb_hdrc.0: new USB bus registered, assigned bus number 1

usb usb1: default language 0x0409

usb usb1: udev 1, busnum 1, minor = 0

usb usb1: New USB device found, idVendor=1d6b, idProduct=0002

usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1

usb usb1: Product: MUSB HDRC host driver

usb usb1: Manufacturer: Linux 2.6.34.7-ADI-2010R1 musb-hcd

usb usb1: SerialNumber: musb_hdrc.0

usb usb1: usb_probe_device

usb usb1: configuration #1 chosen from 1 choice

usb usb1: adding 1-0:1.0 (config #1, interface 0)

hub 1-0:1.0: usb_probe_interface

hub 1-0:1.0: usb_probe_interface - got id

hub 1-0:1.0: USB hub found

hub 1-0:1.0: 1 port detected

hub 1-0:1.0: standalone hub

hub 1-0:1.0: individual port power switching

hub 1-0:1.0: no over-current protection

hub 1-0:1.0: power on to power good time: 10ms

hub 1-0:1.0: local power source is good

hub 1-0:1.0: enabling power on all ports

drivers/usb/core/inode.c: creating file '001'

musb_hdrc musb_hdrc.0: USB Host mode controller at ffc03800 using PIO, IRQ 59

root: /> hub 1-0:1.0: state 7 ports 1 chg 0000 evt 0000

hub 1-0:1.0: state 7 ports 1 chg 0000 evt 0002

hub 1-0:1.0: port 1, status 0101, change 0001, 12 Mb/s

hub 1-0:1.0: debounce: port 1: total 100ms stable 100ms status 0x101

usb 1-1: new high speed USB device using musb_hdrc and address 2

usb 1-1: default language 0x0409

usb 1-1: udev 2, busnum 1, minor = 1

usb 1-1: New USB device found, idVendor=058f, idProduct=6387

usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3

usb 1-1: Product: Mass Storage Device

usb 1-1: Manufacturer: JetFlash

usb 1-1: SerialNumber: T6AU2K6E

usb 1-1: usb_probe_device

usb 1-1: configuration #1 chosen from 1 choice

usb 1-1: adding 1-1:1.0 (config #1, interface 0)

drivers/usb/core/inode.c: creating file '002'

hub 1-0:1.0: state 7 ports 1 chg 0000 evt 0002

hub 1-0:1.0: port 1 enable change, status 00000503

 

root: /> lsusb

Bus 001 Device 001: ID 1d6b:0002

Bus 001 Device 002: ID 058f:6387

root: /> lsusb -t

Bus 001 Device 001: ID 1d6b:0002

Bus 001 Device 002: ID 058f:6387

root: /> cat /proc/bus/usb/devices

 

T: Bus=01 Lev=00 Prnt=00 Port=00 Cnt=00 Dev#= 1 Spd=480 MxCh= 1

B: Alloc= 0/800 us ( 0%), #Int= 0, #Iso= 0

D: Ver= 2.00 Cls=09(hub ) Sub=00 Prot=00 MxPS=64 #Cfgs= 1

P: Vendor=1d6b ProdID=0002 Rev= 2.06

S: Manufacturer=Linux 2.6.34.7-ADI-2010R1 musb-hcd

S: Product=MUSB HDRC host driver

S: SerialNumber=musb_hdrc.0

C:* #Ifs= 1 Cfg#= 1 Atr=e0 MxPwr= 0mA

I:* If#= 0 Alt= 0 #EPs= 1 Cls=09(hub ) Sub=00 Prot=00 Driver=hub

E: Ad=81(I) Atr=03(Int.) MxPS= 4 Ivl=256ms

 

T: Bus=01 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#= 2 Spd=480 MxCh= 0

D: Ver= 2.00 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs= 1

P: Vendor=058f ProdID=6387 Rev= 1.41

S: Manufacturer=JetFlash

S: Product=Mass Storage Device

S: SerialNumber=T6AU2K6E

C:* #Ifs= 1 Cfg#= 1 Atr=80 MxPwr=100mA

I:* If#= 0 Alt= 0 #EPs= 2 Cls=08(stor.) Sub=06 Prot=50 Driver=(none)

E: Ad=01(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms

E: Ad=82(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms

root: /> hub 1-0:1.0: state 7 ports 1 chg 0000 evt 0002

hub 1-0:1.0: port 1, status 0100, change 0001, 12 Mb/s

usb 1-1: USB disconnect, address 2

usb 1-1: unregistering device

usb 1-1: usb_disable_device nuking all URBs

usb 1-1: unregistering interface 1-1:1.0

hub 1-0:1.0: debounce: port 1: total 100ms stable 100ms status 0x100

 

root: /> lsusb

Bus 001 Device 001: ID 1d6b:0002

root: /> cat /proc/bus/usb/devices

 

T: Bus=01 Lev=00 Prnt=00 Port=00 Cnt=00 Dev#= 1 Spd=480 MxCh= 1

B: Alloc= 0/800 us ( 0%), #Int= 0, #Iso= 0

D: Ver= 2.00 Cls=09(hub ) Sub=00 Prot=00 MxPS=64 #Cfgs= 1

P: Vendor=1d6b ProdID=0002 Rev= 2.06

S: Manufacturer=Linux 2.6.34.7-ADI-2010R1 musb-hcd

S: Product=MUSB HDRC host driver

S: SerialNumber=musb_hdrc.0

C:* #Ifs= 1 Cfg#= 1 Atr=e0 MxPwr= 0mA

I:* If#= 0 Alt= 0 #EPs= 1 Cls=09(hub ) Sub=00 Prot=00 Driver=hub

E: Ad=81(I) Atr=03(Int.) MxPS= 4 Ivl=256ms

 

 

/* At this point the USB stick was connected again.*/

 

root: /> lsusb

Bus 001 Device 001: ID 1d6b:0002

root: /> cat /proc/bus/usb/devices

 

T: Bus=01 Lev=00 Prnt=00 Port=00 Cnt=00 Dev#= 1 Spd=480 MxCh= 1

B: Alloc= 0/800 us ( 0%), #Int= 0, #Iso= 0

D: Ver= 2.00 Cls=09(hub ) Sub=00 Prot=00 MxPS=64 #Cfgs= 1

P: Vendor=1d6b ProdID=0002 Rev= 2.06

S: Manufacturer=Linux 2.6.34.7-ADI-2010R1 musb-hcd

S: Product=MUSB HDRC host driver

S: SerialNumber=musb_hdrc.0

C:* #Ifs= 1 Cfg#= 1 Atr=e0 MxPwr= 0mA

I:* If#= 0 Alt= 0 #EPs= 1 Cls=09(hub ) Sub=00 Prot=00 Driver=hub

E: Ad=81(I) Atr=03(Int.) MxPS= 4 Ivl=256ms

root: />

QuoteReplyEditDelete

 

 

2011-02-09 03:27:06     Re: BF527 USB devices enumeration problem.

Sonic Zhang (CHINA)

Message: 98017   

 

Have you tried the patch from Bob against 2010R1 in the other thead? Any difference?

 

What USB device do you use? Without the same device we can't help to debug.

QuoteReplyEditDelete

 

 

2011-02-10 07:30:32     Re: BF527 USB devices enumeration problem.

Sergei Zenkevich (BELARUS)

Message: 98075   

 

Changes from the patch is already present in the version 2010R1 RC5.

 

 

We tried with the following USB stick:

 

 

Kingston DataTraveler 512 MB (inscription on the stick: DTI/512; CN 020707; 04169-308.A00LF)

 

Vendor=0951 ProdID=1603 Rev= 2.00

Manufacturer=Kingston

Product=DataTraveler 2.00000000201

SerialNumber=0000000201

 

Apacer 4GB

 

Vendor=1005 ProdID=b113 Rev= 1.00

Manufacturer=

Product=USB FLASH DRIVE

SerialNumber=199C1583CCBA01CF

 

Transcend 1GB

 

Vendor=058f ProdID=6387 Rev= 1.41

Manufacturer=JetFlash

Product=Mass Storage Device

SerialNumber=T6AU2K6E

 

We can try to find a USB stick which you will recommend.

QuoteReplyEditDelete

 

 

2011-02-25 11:56:17     Re: BF527 USB devices enumeration problem.

Sergei Zenkevich (BELARUS)

Message: 98442   

 

We tested the issue with 2009R1.1-RC4. No issue with 2009R1.1-RC4. By stepping on svn revision, we found that after commit 8106 issue is occurs. For the test, we have partially reverted commit 8106 in 2010R1 RC5 and have received that the issue has disappeared.

QuoteReplyEditDelete

 

 

2011-02-27 21:59:51     Re: BF527 USB devices enumeration problem.

Sonic Zhang (CHINA)

Message: 98457   

 

The kernel commit 8106 is against arch/blackfin/kernel/kgdb.c . If you are not enable KGDB in your kernel, which is the default config, your USB issue has nothing to do with this patch.

QuoteReplyEditDelete

 

 

2011-02-27 22:30:14     Re: BF527 USB devices enumeration problem.

Bob Liu (CHINA)

Message: 98459   

 

Hi,

 

I can't repeat your issue. Below is my log, i am using a usb camera.

 

Maybe you need to wait about 3-5 seconds after your replug the usb device then it canbe recongnized.

 

root:/>

root:/>

root:/> modprobe musb_hdrc

musb_hdrc: version 6.0, pio, host, debug=0

musb_hdrc musb_hdrc.0: MUSB HDRC host driver

musb_hdrc musb_hdrc.0: new USB bus registered, assigned bus number 1

usb usb1: New USB device found, idVendor=1d6b, idProduct=0002

usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1

usb usb1: Product: MUSB HDRC host driver

usb usb1: Manufacturer: Linux 2.6.34.7-ADI-2010R1-svn9243 musb-hcd

usb usb1: SerialNumber: musb_hdrc.0

hub 1-0:1.0: USB hub found

hub 1-0:1.0: 1 port detected

musb_hdrc musb_hdrc.0: USB Host mode controller at ffc03c00 using PIO, IRQ 82

root:/>

root:/>

root:/>

root:/> usb 1-1: new high speed USB device using musb_hdrc and address 2

usb 1-1: New USB device found, idVendor=046d, idProduct=0990

usb 1-1: New USB device strings: Mfr=0, Product=0, SerialNumber=2

usb 1-1: SerialNumber: B272EE1E

uvcvideo: Found UVC 1.00 device <unnamed> (046d:0990)

input: UVC Camera (046d:0990) as /devices/platform/musb_hdrc.0/usb1/1-1/1-1:1.0/input/input2

usb 1-1: USB disconnect, address 2

usb 1-1: new high speed USB device using musb_hdrc and address 3

usb 1-1: New USB device found, idVendor=046d, idProduct=0990

usb 1-1: New USB device strings: Mfr=0, Product=0, SerialNumber=2

usb 1-1: SerialNumber: B272EE1E

uvcvideo: Found UVC 1.00 device <unnamed> (046d:0990)

input: UVC Camera (046d:0990) as /devices/platform/musb_hdrc.0/usb1/1-1/1-1:1.0/input/input3

 

root:/>

root:/> usb 1-1: USB disconnect, address 3

 

root:/> usb 1-1: new high speed USB device using musb_hdrc and address 4

usb 1-1: New USB device found, idVendor=046d, idProduct=0990

usb 1-1: New USB device strings: Mfr=0, Product=0, SerialNumber=2

usb 1-1: SerialNumber: B272EE1E

uvcvideo: Found UVC 1.00 device <unnamed> (046d:0990)

input: UVC Camera (046d:0990) as /devices/platform/musb_hdrc.0/usb1/1-1/1-1:1.0/input/input4

 

root:/>

root:/> version

kernel:    Linux release 2.6.34.7-ADI-2010R1-svn9243, build #1665 Mon Feb 28 11:32:47 CST 2011

toolchain: bfin-linux-uclibc-gcc release gcc version 4.3.5 (ADI-trunk/svn-4813)

user-dist: release svn-9856, build #741 Mon Feb 28 11:32:19 CST 2011

root:/>

QuoteReplyEditDelete

 

 

2011-02-28 04:05:56     Re: BF527 USB devices enumeration problem.

Sergei Zenkevich (BELARUS)

Message: 98464   

 

I'm sorry commit 8107 instead 8106.

Attachments

    Outcomes