2009-06-22 12:45:47     USB Disconnect

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

2009-06-22 12:45:47     USB Disconnect

Chris Brissette (UNITED STATES)

Message: 76137   

 

Just updated to 2009R1.

 

kernel:    Linux release 2.6.28.10-ADI-2009R1-svn6785, build #53 Mon Jun 22 11:52:15 EDT 2009

toolchain: bfin-uclinux-gcc release gcc version 4.1.2 (ADI svn)

user-dist: release svn-8325, build #24 Mon Jun 22 11:51:11 EDT 2009

 

I have a custom board that has been running 2008R1.5-RC3 for quite a while with no real issues. I updated to 2009R1 and the only thing that I cannot seem to get working correctly is USB disconnects. I have SL811 host support, which will detect insertion of USB stick, automount it Vfat no problem.

 

But when it is removed, the usb device never seems to be detected as removed. So the next time I insert the device it doesn't even detect an insertion. (Note) This also happens with a USB keyboard.

 

Any help would be appreciated.

QuoteReplyEditDelete

 

 

2009-06-22 12:52:11     Re: USB Disconnect

Chris Brissette (UNITED STATES)

Message: 76138   

 

BF537 based board

QuoteReplyEditDelete

 

 

2009-06-22 13:20:46     Re: USB Disconnect

Mike Frysinger (UNITED STATES)

Message: 76140   

 

how exactly are you handling the dynamic events ?

QuoteReplyEditDelete

 

 

2009-06-22 14:29:55     Re: USB Disconnect

Chris Brissette (UNITED STATES)

Message: 76143   

 

Are you refering to the dynamic events for usb insertion removal we are using hotplug. The hotplug script never gets run because it never seems to get an disconnect event.

 

I can plug a USB keyboard in, unplug it and then when I plug in a USB stick (hotplug) doens't run, and /dev/sda device doesn't show up.

 

Here's the kernel output

 

Jun 22 15:40:45 EPA40344 user.debug kernel: hub 1-0:1.0: state 7 ports 1 chg 0000 evt 0002

Jun 22 15:40:45 EPA40344 user.debug kernel: sl811: GetPortStatus 00010101

Jun 22 15:40:45 EPA40344 user.debug kernel: hub 1-0:1.0: port 1, status 0101, change 0001, 12 Mb/s

Jun 22 15:40:45 EPA40344 user.debug kernel: hub 1-0:1.0: debounce: port 1: total 100ms stable 100ms status 0x101

Jun 22 15:40:45 EPA40344 user.debug kernel: sl811: end reset

Jun 22 15:40:45 EPA40344 user.debug kernel: sl811: GetPortStatus 00100303

Jun 22 15:40:45 EPA40344 user.info kernel: usb 1-1: new low speed USB device using sl811-hcd and address 2

Jun 22 15:40:45 EPA40344 user.debug kernel: sl811: end reset

Jun 22 15:40:45 EPA40344 user.debug kernel: sl811: GetPortStatus 00100303

Jun 22 15:40:45 EPA40344 user.debug kernel: usb 1-1: skipped 1 descriptor after interface

Jun 22 15:40:45 EPA40344 user.debug kernel: usb 1-1: skipped 1 descriptor after interface

Jun 22 15:40:45 EPA40344 user.debug kernel: usb 1-1: default language 0x0409

Jun 22 15:40:45 EPA40344 user.debug kernel: usb 1-1: uevent

Jun 22 15:40:45 EPA40344 user.debug kernel: usb 1-1: usb_probe_device

Jun 22 15:40:45 EPA40344 user.info kernel: usb 1-1: configuration #1 chosen from 1 choice

Jun 22 15:40:45 EPA40344 user.debug kernel: usb 1-1: adding 1-1:1.0 (config #1, interface 0)

Jun 22 15:40:45 EPA40344 user.debug kernel: usb 1-1:1.0: uevent

Jun 22 15:40:45 EPA40344 user.debug kernel: usbserial_generic 1-1:1.0: usb_probe_interface

Jun 22 15:40:45 EPA40344 user.debug kernel: usbserial_generic 1-1:1.0: usb_probe_interface - got id

Jun 22 15:40:45 EPA40344 user.debug kernel: usb 1-1: adding 1-1:1.1 (config #1, interface 1)

Jun 22 15:40:45 EPA40344 user.debug kernel: usb 1-1:1.1: uevent

Jun 22 15:40:45 EPA40344 user.debug kernel: usbserial_generic 1-1:1.1: usb_probe_interface

Jun 22 15:40:45 EPA40344 user.debug kernel: usbserial_generic 1-1:1.1: usb_probe_interface - got id

Jun 22 15:40:45 EPA40344 user.debug kernel: drivers/usb/core/inode.c: creating file '002'

Jun 22 15:40:45 EPA40344 user.info kernel: usb 1-1: New USB device found, idVendor=046d, idProduct=c317

Jun 22 15:40:45 EPA40344 user.info kernel: usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=0

Jun 22 15:40:45 EPA40344 user.info kernel: usb 1-1: Product: USB Multimedia Keyboard

Jun 22 15:40:45 EPA40344 user.info kernel: usb 1-1: Manufacturer: Logitech

Jun 22 15:41:01 EPA40344 user.debug kernel: hub 1-0:1.0: state 7 ports 1 chg 0000 evt 0002

Jun 22 15:41:01 EPA40344 user.debug kernel: sl811: GetPortStatus 00010303

Jun 22 15:41:01 EPA40344 user.debug kernel: hub 1-0:1.0: port 1, status 0303, change 0001, 1.5 Mb/s

Jun 22 15:43:03 EPA40344 user.debug kernel: hub 1-0:1.0: state 7 ports 1 chg 0000 evt 0002

Jun 22 15:43:03 EPA40344 user.debug kernel: sl811: GetPortStatus 00010303

Jun 22 15:43:03 EPA40344 user.debug kernel: hub 1-0:1.0: port 1, status 0303, change 0001, 1.5 Mb/s

 

 

 

The last few events happen each time I plug a device in.

QuoteReplyEditDelete

 

 

2009-06-22 14:34:37     Re: USB Disconnect

Mike Frysinger (UNITED STATES)

Message: 76144   

 

doesnt sound like a hotplug/event issue.  sounds like the SL811 driver itself isnt detecting the device removal.

QuoteReplyEditDelete

 

 

2009-06-22 14:43:07     Re: USB Disconnect

Chris Brissette (UNITED STATES)

Message: 76145   

 

That sounds right. Anything I can do to look into it, there has only been tons of code changes for USB. We have been tring to go through the USB routines but it's pretty tough going.

QuoteReplyEditDelete

 

 

2009-06-22 15:36:40     Re: USB Disconnect

Mike Frysinger (UNITED STATES)

Message: 76148   

 

our USB guy is currently on vacation, but he will take a look when he gets back ...

QuoteReplyEditDelete

 

 

2009-06-22 15:57:25     Re: USB Disconnect

Chris Brissette (UNITED STATES)

Message: 76150   

 

Alittle more info after looking into USB debug info. The driver seems to be seeing the insert/removal. in the /proc/driver/sl811h

 

root:/proc/driver> cat sl811h

SL811HS v1.5

sl811-hcd version 19 May 2005

portstatus[1] = 00000303

insert/remove: 3

current session:  done_a 0 done_b 0 wake 0 sof 0 overrun 0 lost 0

 

ctrl1 00

irq_enable 20 ins/rmv

irq_status 80 dp

frame clocks remaining:  4800

A: qh00000000 ctl 42 sts 09

B: qh00000000 ctl e0 sts 00

 

periodic size= 32

 

 

The insert/remove is moving up each time it's inserted or removed.

QuoteReplyEditDelete

 

 

2009-07-20 14:07:19     Re: USB Disconnect

Chris Brissette (UNITED STATES)

Message: 77752   

 

Did anyone get a chance to look at this usb issue? I just wanted to confirm where the problem is.

 

Thanks

QuoteReplyEditDelete

 

 

2009-07-22 07:41:20     Re: USB Disconnect

Michael Hennerich (GERMANY)

Message: 77863   

 

Hi Cris,

 

I opend this bug item for you -

 

  blackfin.uclinux.org/gf/project/uclinux-dist/tracker/?action=TrackerItemEdit&tracker_item_id=5381

 

-Michael

QuoteReplyEditDelete

 

 

2009-07-22 09:40:29     Re: USB Disconnect

Chris Brissette (UNITED STATES)

Message: 77868   

 

Thanks,

 

Chris

QuoteReplyEditDelete

 

 

2009-07-22 10:21:53     Re: USB Disconnect

Michael Hennerich (GERMANY)

Message: 77876    >Chris,

 

I checked a fix into our 2009R1 release branch.

 

-Michael

Attachments

    Outcomes