USB SDCardReader hangs
Jalil Karimov
jukarimov at gmail.com
Sat Dec 3 01:56:57 EST 2011
Hi All,
Here lsusb -v output:
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 2.00
bDeviceClass 9 Hub
bDeviceSubClass 0 Unused
bDeviceProtocol 0 Full speed (or root) hub
bMaxPacketSize0 64
idVendor 0x1d6b Linux Foundation
idProduct 0x0002 2.0 root hub
bcdDevice 3.00
iManufacturer 3 Linux 3.0.0-13-generic ehci_hcd
iProduct 2 EHCI Host Controller
iSerial 1 0000:00:1d.7
bNumConfigurations 1
Configuration Descriptor:
bLength 9
bDescriptorType 2
wTotalLength 25
bNumInterfaces 1
bConfigurationValue 1
iConfiguration 0
bmAttributes 0xe0
Self Powered
Remote Wakeup
MaxPower 0mA
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 0
bNumEndpoints 1
bInterfaceClass 9 Hub
bInterfaceSubClass 0 Unused
bInterfaceProtocol 0 Full speed (or root) hub
iInterface 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x81 EP 1 IN
bmAttributes 3
Transfer Type Interrupt
Synch Type None
Usage Type Data
wMaxPacketSize 0x0004 1x 4 bytes
bInterval 12
Hub Descriptor:
bLength 9
bDescriptorType 41
nNbrPorts 6
wHubCharacteristic 0x000a
No power switching (usb 1.0)
Per-port overcurrent protection
bPwrOn2PwrGood 10 * 2 milli seconds
bHubContrCurrent 0 milli Ampere
DeviceRemovable 0x00
PortPwrCtrlMask 0xff
Hub Port Status:
Port 1: 0000.0100 power
Port 2: 0000.0100 power
Port 3: 0000.0100 power
Port 4: 0000.0100 power
Port 5: 0000.0100 power
Port 6: 0000.0100 power
Device Status: 0x0003
Self Powered
Remote Wakeup Enabled
Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 1.10
bDeviceClass 9 Hub
bDeviceSubClass 0 Unused
bDeviceProtocol 0 Full speed (or root) hub
bMaxPacketSize0 64
idVendor 0x1d6b Linux Foundation
idProduct 0x0001 1.1 root hub
bcdDevice 3.00
iManufacturer 3 Linux 3.0.0-13-generic uhci_hcd
iProduct 2 UHCI Host Controller
iSerial 1 0000:00:1d.0
bNumConfigurations 1
Configuration Descriptor:
bLength 9
bDescriptorType 2
wTotalLength 25
bNumInterfaces 1
bConfigurationValue 1
iConfiguration 0
bmAttributes 0xe0
Self Powered
Remote Wakeup
MaxPower 0mA
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 0
bNumEndpoints 1
bInterfaceClass 9 Hub
bInterfaceSubClass 0 Unused
bInterfaceProtocol 0 Full speed (or root) hub
iInterface 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x81 EP 1 IN
bmAttributes 3
Transfer Type Interrupt
Synch Type None
Usage Type Data
wMaxPacketSize 0x0002 1x 2 bytes
bInterval 255
Hub Descriptor:
bLength 9
bDescriptorType 41
nNbrPorts 2
wHubCharacteristic 0x000a
No power switching (usb 1.0)
Per-port overcurrent protection
bPwrOn2PwrGood 1 * 2 milli seconds
bHubContrCurrent 0 milli Ampere
DeviceRemovable 0x00
PortPwrCtrlMask 0xff
Hub Port Status:
Port 1: 0000.0100 power
Port 2: 0000.0100 power
Device Status: 0x0003
Self Powered
Remote Wakeup Enabled
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 1.10
bDeviceClass 9 Hub
bDeviceSubClass 0 Unused
bDeviceProtocol 0 Full speed (or root) hub
bMaxPacketSize0 64
idVendor 0x1d6b Linux Foundation
idProduct 0x0001 1.1 root hub
bcdDevice 3.00
iManufacturer 3 Linux 3.0.0-13-generic uhci_hcd
iProduct 2 UHCI Host Controller
iSerial 1 0000:00:1d.1
bNumConfigurations 1
Configuration Descriptor:
bLength 9
bDescriptorType 2
wTotalLength 25
bNumInterfaces 1
bConfigurationValue 1
iConfiguration 0
bmAttributes 0xe0
Self Powered
Remote Wakeup
MaxPower 0mA
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 0
bNumEndpoints 1
bInterfaceClass 9 Hub
bInterfaceSubClass 0 Unused
bInterfaceProtocol 0 Full speed (or root) hub
iInterface 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x81 EP 1 IN
bmAttributes 3
Transfer Type Interrupt
Synch Type None
Usage Type Data
wMaxPacketSize 0x0002 1x 2 bytes
bInterval 255
Hub Descriptor:
bLength 9
bDescriptorType 41
nNbrPorts 2
wHubCharacteristic 0x000a
No power switching (usb 1.0)
Per-port overcurrent protection
bPwrOn2PwrGood 1 * 2 milli seconds
bHubContrCurrent 0 milli Ampere
DeviceRemovable 0x00
PortPwrCtrlMask 0xff
Hub Port Status:
Port 1: 0000.0100 power
Port 2: 0000.0100 power
Device Status: 0x0003
Self Powered
Remote Wakeup Enabled
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 1.10
bDeviceClass 9 Hub
bDeviceSubClass 0 Unused
bDeviceProtocol 0 Full speed (or root) hub
bMaxPacketSize0 64
idVendor 0x1d6b Linux Foundation
idProduct 0x0001 1.1 root hub
bcdDevice 3.00
iManufacturer 3 Linux 3.0.0-13-generic uhci_hcd
iProduct 2 UHCI Host Controller
iSerial 1 0000:00:1d.2
bNumConfigurations 1
Configuration Descriptor:
bLength 9
bDescriptorType 2
wTotalLength 25
bNumInterfaces 1
bConfigurationValue 1
iConfiguration 0
bmAttributes 0xe0
Self Powered
Remote Wakeup
MaxPower 0mA
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 0
bNumEndpoints 1
bInterfaceClass 9 Hub
bInterfaceSubClass 0 Unused
bInterfaceProtocol 0 Full speed (or root) hub
iInterface 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x81 EP 1 IN
bmAttributes 3
Transfer Type Interrupt
Synch Type None
Usage Type Data
wMaxPacketSize 0x0002 1x 2 bytes
bInterval 255
Hub Descriptor:
bLength 9
bDescriptorType 41
nNbrPorts 2
wHubCharacteristic 0x000a
No power switching (usb 1.0)
Per-port overcurrent protection
bPwrOn2PwrGood 1 * 2 milli seconds
bHubContrCurrent 0 milli Ampere
DeviceRemovable 0x00
PortPwrCtrlMask 0xff
Hub Port Status:
Port 1: 0000.0100 power
Port 2: 0000.0103 power enable connect
Device Status: 0x0003
Self Powered
Remote Wakeup Enabled
Bus 004 Device 002: ID 0cf2:6220 ENE Technology, Inc. SD Card Reader
(SG361)
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 1.00
bDeviceClass 0 (Defined at Interface level)
bDeviceSubClass 0
bDeviceProtocol 0
bMaxPacketSize0 64
idVendor 0x0cf2 ENE Technology, Inc.
idProduct 0x6220 SD Card Reader (SG361)
bcdDevice 1.00
iManufacturer 1 ENE
iProduct 2 UB6220
iSerial 4 606569746801
bNumConfigurations 1
Configuration Descriptor:
bLength 9
bDescriptorType 2
wTotalLength 32
bNumInterfaces 1
bConfigurationValue 1
iConfiguration 0
bmAttributes 0x80
(Bus Powered)
MaxPower 498mA
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 0
bNumEndpoints 2
bInterfaceClass 8 Mass Storage
bInterfaceSubClass 6 SCSI
bInterfaceProtocol 80 Bulk (Zip)
iInterface 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x01 EP 1 OUT
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0040 1x 64 bytes
bInterval 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x82 EP 2 IN
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0040 1x 64 bytes
bInterval 0
Device Status: 0x0000
(Bus Powered)
* * *
Device works fine on OSwintXP and DSL Linux (2.4.31) 52 MB RAM
I didn't find 2.4 kernel to build and test myself.
After sticking the device's led is blinking and any operations
(mount,fdisk,eject) will hang.
dmesg outputs (on linux 2.6 and 3.0 same thing)
* * *
[ 101.868018] usb 1-6: new high speed USB device using ehci_hcd and
address 2
[ 101.936241] hub 1-0:1.0: unable to enumerate USB device on port 6
[ 102.204027] usb 4-2: new full speed USB device using uhci_hcd and
address 2
[ 102.543218] usbcore: registered new interface driver uas
[ 102.583332] Initializing USB Mass Storage driver...
[ 102.583535] scsi2 : usb-storage 4-2:1.0
[ 102.585561] usbcore: registered new interface driver usb-storage
[ 102.585568] USB Mass Storage support registered.
[ 103.596815] scsi 2:0:0:0: Direct-Access USB2.0 CardReader SD
0100 PQ: 0 ANSI: 0
[ 103.603436] sd 2:0:0:0: Attached scsi generic sg3 type 0
[ 103.695769] sd 2:0:0:0: [sdc] 994304 512-byte logical blocks: (509
MB/485 MiB)
[ 103.698770] sd 2:0:0:0: [sdc] Write Protect is off
[ 103.698778] sd 2:0:0:0: [sdc] Mode Sense: 03 00 00 00
[ 103.698782] sd 2:0:0:0: [sdc] Assuming drive cache: write through
[ 103.711757] sd 2:0:0:0: [sdc] Assuming drive cache: write through
[ 103.717889] sdc: sdc1
[ 103.727830] sd 2:0:0:0: [sdc] Assuming drive cache: write through
[ 103.727841] sd 2:0:0:0: [sdc] Attached SCSI removable disk
[ 283.802708] sd 2:0:0:0: timing out command, waited 180s
[ 283.802729] sd 2:0:0:0: [sdc] Unhandled sense code
[ 283.802733] sd 2:0:0:0: [sdc] Result: hostbyte=DID_OK
driverbyte=DRIVER_SENSE
[ 283.802739] sd 2:0:0:0: [sdc] Sense Key : Hardware Error [current]
[ 283.802746] sd 2:0:0:0: [sdc] Add. Sense: Unrecovered read error
[ 283.802753] sd 2:0:0:0: [sdc] CDB: Read(10): 28 00 00 0f 2b f0 00 00 08
00
[ 283.802765] end_request: I/O error, dev sdc, sector 994288
[ 283.802773] Buffer I/O error on device sdc, logical block 124286
[ 463.818656] sd 2:0:0:0: timing out command, waited 180s
[ 463.818673] sd 2:0:0:0: [sdc] Unhandled sense code
[ 463.818677] sd 2:0:0:0: [sdc] Result: hostbyte=DID_OK
driverbyte=DRIVER_SENSE
[ 463.818683] sd 2:0:0:0: [sdc] Sense Key : Hardware Error [current]
[ 463.818690] sd 2:0:0:0: [sdc] Add. Sense: Unrecovered read error
[ 463.818698] sd 2:0:0:0: [sdc] CDB: Read(10): 28 00 00 0f 2b f0 00 00 08
00
[ 463.818711] end_request: I/O error, dev sdc, sector 994288
[ 463.818719] Buffer I/O error on device sdc1, logical block 124030
[ 480.168080] INFO: task udisks-part-id:1945 blocked for more than 120
seconds.
[ 480.168087] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables
this message.
[ 480.168092] udisks-part-id D 00000000 0 1945 518 0x00000004
[ 480.168100] c0081d9c 00000086 00000000 00000000 ffffffff 00000040
ca73e78c c183a8c0
[ 480.168109] 890837a7 00000050 ca73e788 c183a8c0 c183a8c0 de8068c0
ca73e500 c1731f60
[ 480.168117] 00000246 c1784140 c1784140 00000001 c0081d90 00000246
de25e150 cd208060
[ 480.168126] Call Trace:
[ 480.168141] [<c1272d12>] ? kobject_get+0x12/0x20
[ 480.168149] [<c1263888>] ? get_disk+0x48/0xa0
[ 480.168159] [<c1509096>] __mutex_lock_slowpath+0xd6/0x140
[ 480.168164] [<c1508c05>] mutex_lock+0x25/0x40
[ 480.168171] [<c1154e87>] __blkdev_get+0x47/0x360
[ 480.168176] [<c11551e9>] blkdev_get+0x49/0x250
[ 480.168181] [<c11547ae>] ? bd_acquire+0x3e/0xd0
[ 480.168185] [<c1155448>] blkdev_open+0x58/0x70
[ 480.168191] [<c11253c1>] __dentry_open+0xc1/0x280
[ 480.168196] [<c112672e>] nameidata_to_filp+0x6e/0x80
[ 480.168201] [<c11553f0>] ? blkdev_open+0x0/0x70
[ 480.168207] [<c1133bdf>] finish_open+0xaf/0x1a0
[ 480.168211] [<c1133488>] ? do_path_lookup+0x68/0x120
[ 480.168217] [<c1134227>] do_filp_open+0x207/0x6e0
[ 480.168223] [<c1126796>] do_sys_open+0x56/0x120
[ 480.168231] [<c13222d0>] ? write_null+0x0/0x10
[ 480.168236] [<c112688e>] sys_open+0x2e/0x40
[ 480.168241] [<c150a4a4>] syscall_call+0x7/0xb
[ 600.168074] INFO: task udisks-daemon:1597 blocked for more than 120
seconds.
[ 600.168081] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables
this message.
[ 600.168085] udisks-daemon D fe1248b5 0 1597 1 0x00000000
[ 600.168093] ca401ca4 00000086 0000006b fe1248b5 0000006b d8e01f16
cd3d9bcc c183a8c0
[ 600.168102] fe126839 0000006b cd3d9bc8 c183a8c0 c183a8c0 de8068c0
cd3d9940 d0eb25e0
[ 600.168110] de806920 de806904 d0eb260c d0eb260c ca401c9c 003d0f91
d90a9ef1 cd3d996c
[ 600.168119] Call Trace:
[ 600.168137] [<c15088dd>] schedule_timeout+0x1ed/0x260
[ 600.168144] [<c150a07d>] ? _raw_spin_lock+0xd/0x10
[ 600.168152] [<c103de37>] ? task_rq_lock+0x47/0x80
[ 600.168158] [<c1049f53>] ? try_to_wake_up+0x223/0x3c0
[ 600.168164] [<c1508460>] wait_for_common+0xa0/0x130
[ 600.168169] [<c104a124>] ? wake_up_process+0x14/0x20
[ 600.168173] [<c104a0f0>] ? default_wake_function+0x0/0x20
[ 600.168179] [<c15085c7>] wait_for_completion+0x17/0x20
[ 600.168186] [<c1068100>] flush_work+0x30/0x40
[ 600.168192] [<c10666d0>] ? wq_barrier_func+0x0/0x20
[ 600.168197] [<c10697eb>] flush_delayed_work+0x3b/0x40
[ 600.168203] [<c12650a5>] disk_clear_events+0x75/0x120
[ 600.168210] [<c1153c0d>] check_disk_change+0x2d/0x70
[ 600.168218] [<c1362d80>] sd_open+0xa0/0x1d0
[ 600.168224] [<c1272cad>] ? kobject_put+0x1d/0x50
[ 600.168230] [<c1155162>] __blkdev_get+0x322/0x360
[ 600.168236] [<c11551e9>] blkdev_get+0x49/0x250
[ 600.168240] [<c11547ae>] ? bd_acquire+0x3e/0xd0
[ 600.168245] [<c1155448>] blkdev_open+0x58/0x70
[ 600.168251] [<c11253c1>] __dentry_open+0xc1/0x280
[ 600.168256] [<c112672e>] nameidata_to_filp+0x6e/0x80
[ 600.168260] [<c11553f0>] ? blkdev_open+0x0/0x70
[ 600.168266] [<c1133bdf>] finish_open+0xaf/0x1a0
[ 600.168271] [<c1133488>] ? do_path_lookup+0x68/0x120
[ 600.168276] [<c1134227>] do_filp_open+0x207/0x6e0
[ 600.168284] [<c113ff79>] ? vfsmount_lock_local_unlock+0x19/0x20
[ 600.168290] [<c1126796>] do_sys_open+0x56/0x120
[ 600.168295] [<c112859d>] ? fput+0x1d/0x30
[ 600.168299] [<c112688e>] sys_open+0x2e/0x40
[ 600.168305] [<c150a4a4>] syscall_call+0x7/0xb
[ 600.168317] INFO: task udisks-part-id:1945 blocked for more than 120
seconds.
[ 600.168320] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables
this message.
[ 600.168324] udisks-part-id D 00000000 0 1945 518 0x00000004
[ 600.168330] c0081d9c 00000086 00000000 00000000 ffffffff 00000040
ca73e78c c183a8c0
[ 600.168338] 890837a7 00000050 ca73e788 c183a8c0 c183a8c0 de8068c0
ca73e500 c1731f60
[ 600.168347] 00000246 c1784140 c1784140 00000001 c0081d90 00000246
de25e150 cd208060
[ 600.168355] Call Trace:
[ 600.168361] [<c1272d12>] ? kobject_get+0x12/0x20
[ 600.168368] [<c1263888>] ? get_disk+0x48/0xa0
[ 600.168374] [<c1509096>] __mutex_lock_slowpath+0xd6/0x140
[ 600.168380] [<c1508c05>] mutex_lock+0x25/0x40
[ 600.168385] [<c1154e87>] __blkdev_get+0x47/0x360
[ 600.168390] [<c11551e9>] blkdev_get+0x49/0x250
[ 600.168395] [<c11547ae>] ? bd_acquire+0x3e/0xd0
[ 600.168400] [<c1155448>] blkdev_open+0x58/0x70
[ 600.168404] [<c11253c1>] __dentry_open+0xc1/0x280
[ 600.168409] [<c112672e>] nameidata_to_filp+0x6e/0x80
[ 600.168414] [<c11553f0>] ? blkdev_open+0x0/0x70
[ 600.168419] [<c1133bdf>] finish_open+0xaf/0x1a0
[ 600.168424] [<c1133488>] ? do_path_lookup+0x68/0x120
[ 600.168429] [<c1134227>] do_filp_open+0x207/0x6e0
[ 600.168435] [<c1126796>] do_sys_open+0x56/0x120
[ 600.168442] [<c13222d0>] ? write_null+0x0/0x10
[ 600.168447] [<c112688e>] sys_open+0x2e/0x40
[ 600.168452] [<c150a4a4>] syscall_call+0x7/0xb
[ 643.826626] sd 2:0:0:0: timing out command, waited 180s
[ 643.826645] sd 2:0:0:0: [sdc] Unhandled sense code
[ 643.826649] sd 2:0:0:0: [sdc] Result: hostbyte=DID_OK
driverbyte=DRIVER_SENSE
[ 643.826655] sd 2:0:0:0: [sdc] Sense Key : Hardware Error [current]
[ 643.826662] sd 2:0:0:0: [sdc] Add. Sense: Unrecovered read error
[ 643.826669] sd 2:0:0:0: [sdc] CDB: Read(10): 28 00 00 0f 2b f0 00 00 08
00
[ 643.826682] end_request: I/O error, dev sdc, sector 994288
[ 643.826690] Buffer I/O error on device sdc1, logical block 124030
Cheers,
Jalil
More information about the Kernelnewbies
mailing list