Bug 5464 - Apacer usb storage devices cause scsi errors
Apacer usb storage devices cause scsi errors
Status: REJECTED INSUFFICIENT_DATA
Product: Drivers
Classification: Unclassified
Component: USB
i386 Linux
: P2 normal
Assigned To: Matthew Dharm
:
Depends on:
Blocks: USB
  Show dependency treegraph
 
Reported: 2005-10-18 20:25 UTC by patrick
Modified: 2006-03-06 10:41 UTC (History)
1 user (show)

See Also:
Kernel Version: 2.6.8.1
Tree: Mainline
Regression: ---


Attachments
Same error, different brand USB pen drive (94.99 KB, text/plain)
2005-10-19 17:58 UTC, Andrew Perrin
Details

Description patrick 2005-10-18 20:25:57 UTC
Distribution:uClinux

Problem Description:
Inserting a  Apacer USB Storage device causes scsi errors on
plugging the device in USB socket.

I can see the messages about "sda:unknown partition table"
---------------------------------------------------------------------
usb 1-2: new high speed USB device using address 2
usb 1-2: Product: USB Flash Drive
usb 1-2: SerialNumber: 070200012791ED0
scsi0 : SCSI emulation for USB Mass Storage devices
  Vendor: USB       Model: Flash Drive       Rev: 1.12
  Type:   Direct-Access                      ANSI SCSI revision: 02
SCSI device sda: 253949 512-byte hdwr sectors (130 MB)
sda: assuming Write Enabled
sda: assuming drive cache: write through
 sda:<7>usb-storage: queuecommand called
 unknown partition table
Attached scsi removable disk sda at scsi0, channel 0, id 0, lun 0
Attached scsi generic sg0 at scsi0, channel 0, id 0, lun 0,  type 0
---------------------------------------------------------------------
/var/log/messages is below
---------------------------------------------------------------------
<15>Mar 18 11:02:39 klogd: usb-storage: scsi cmd done, result=0x2
<15>Mar 18 11:02:39 klogd: usb-storage: *** thread sleeping.
<14>Mar 18 19:02:39 klogd:  sda:<7>usb-storage: queuecommand called
<15>Mar 18 11:02:39 klogd: usb-storage: *** thread awakened.
<15>Mar 18 11:02:39 klogd: usb-storage: Command READ_10 (10 bytes)
<15>Mar 18 11:02:39 klogd: usb-storage:  28 00 00 00 00 00 00 00 08 00
<15>Mar 18 11:02:39 klogd: usb-storage: Bulk Command S 0x43425355 T 0x6 L 4096 F
<15>Mar 18 11:02:39 klogd: usb-storage: usb_stor_bulk_transfer_buf: xfer 31 byte
<15>Mar 18 19:02:39 klogd: usb-storage: Status code 0; transferred 31/31
<15>Mar 18 19:02:39 klogd: usb-storage: -- transfer complete
<15>Mar 18 19:02:39 klogd: usb-storage: Bulk command transfer result=0
<15>Mar 18 19:02:39 klogd: usb-storage: usb_stor_bulk_transfer_sglist: xfer 4096
<15>Mar 18 11:02:39 klogd: usb-storage: Status code 0; transferred 4096/4096
<15>Mar 18 11:02:39 klogd: usb-storage: -- transfer complete
<15>Mar 18 11:02:39 klogd: usb-storage: Bulk data transfer result 0x0
<15>Mar 18 11:02:39 klogd: usb-storage: Attempting to get CSW...
<15>Mar 18 11:02:39 klogd: usb-storage: usb_stor_bulk_transfer_buf: xfer 13 byte
<15>Mar 18 19:02:39 klogd: usb-storage: Status code 0; transferred 13/13
<15>Mar 18 19:02:39 klogd: usb-storage: -- transfer complete
<15>Mar 18 19:02:39 klogd: usb-storage: Bulk status result = 0
<15>Mar 18 19:02:39 klogd: usb-storage: Bulk Status S 0x53425355 T 0x6 R 0 Stat
<15>Mar 18 19:02:39 klogd: usb-storage: scsi cmd done, result=0x0
<15>Mar 18 19:02:39 klogd: usb-storage: *** thread sleeping.
<12>Mar 18 11:02:39 klogd:  unknown partition table
<13>Mar 18 11:02:39 klogd: Attached scsi removable disk sda at scsi0, channel 0,
<13>Mar 18 11:02:39 klogd: Attached scsi generic sg0 at scsi0, channel 0, id 0,
<15>Mar 18 11:02:39 klogd: usb-storage: queuecommand called
<15>Mar 18 19:02:39 klogd: usb-storage: *** thread awakened.
<15>Mar 18 19:02:39 klogd: usb-storage: Bad target number (1:0)
<15>Mar 18 19:02:39 klogd: usb-storage: scsi cmd done, result=0x40000
<15>Mar 18 19:02:39 klogd: usb-storage: *** thread sleeping.
<15>Mar 18 19:02:39 klogd: usb-storage: *** thread awakened.
<15>Mar 18 11:02:39 klogd: usb-storage: queuecommand called
<15>Mar 18 11:02:39 last message repeated 1 time(s)
<15>Mar 18 11:02:39 klogd: usb-storage: *** thread awakened.
<15>Mar 18 11:02:39 klogd: usb-storage: Bad target number (3:0)
<15>Mar 18 11:02:39 klogd: usb-storage: scsi cmd done, result=0x40000
<15>Mar 18 11:02:39 klogd: usb-storage: *** thread sleeping.
<15>Mar 18 19:02:39 klogd: usb-storage: Bad target number (2:0)
<15>Mar 18 19:02:39 klogd: usb-storage: scsi cmd done, result=0x40000
<15>Mar 18 19:02:39 klogd: usb-storage: *** thread sleeping.
<15>Mar 18 19:02:39 klogd: usb-storage: queuecommand called
<15>Mar 18 11:02:39 klogd: usb-storage: *** thread awakened.
<15>Mar 18 11:02:39 klogd: usb-storage: Bad target number (4:0)
<15>Mar 18 11:02:39 klogd: usb-storage: scsi cmd done, result=0x40000
<15>Mar 18 11:02:39 klogd: usb-storage: *** thread sleeping.
<15>Mar 18 19:02:39 klogd: usb-storage: queuecommand called
<15>Mar 18 11:02:39 klogd: usb-storage: *** thread awakened.
<15>Mar 18 11:02:39 klogd: usb-storage: Bad target number (5:0)
<15>Mar 18 11:02:39 klogd: usb-storage: scsi cmd done, result=0x40000
<15>Mar 18 11:02:39 klogd: usb-storage: *** thread sleeping.
<15>Mar 18 19:02:39 klogd: usb-storage: queuecommand called
<15>Mar 18 11:02:39 klogd: usb-storage: *** thread awakened.
<15>Mar 18 11:02:39 klogd: usb-storage: Bad target number (6:0)
<15>Mar 18 11:02:39 klogd: usb-storage: scsi cmd done, result=0x40000
<15>Mar 18 11:02:39 klogd: usb-storage: *** thread sleeping.
<15>Mar 18 19:02:39 klogd: usb-storage: queuecommand called
<15>Mar 18 11:02:39 klogd: usb-storage: *** thread awakened.
<15>Mar 18 11:02:39 klogd: usb-storage: Bad target number (7:0)
<15>Mar 18 11:02:39 klogd: usb-storage: scsi cmd done, result=0x40000
<15>Mar 18 11:02:39 klogd: usb-storage: *** thread sleeping.
<15>Mar 18 19:02:39 klogd: USB Mass Storage device found at 2
---------------------------------------------------------------------

/>cat /proc/bus/usb/devices
---------------------------------------------------------------------
T:  Bus=03 Lev=00 Prnt=00 Port=00 Cnt=00 Dev#=  1 Spd=12  MxCh= 2
B:  Alloc=  0/900 us ( 0%), #Int=  0, #Iso=  0
D:  Ver= 1.10 Cls=09(hub  ) Sub=00 Prot=00 MxPS= 8 #Cfgs=  1
P:  Vendor=0000 ProdID=0000 Rev= 2.06
S:  Manufacturer=Linux 2.6.8.1 uhci_hcd
S:  Product=VIA Technologies, Inc. VT82xxxxx UHCI USB 1.1 Controller (#2)
S:  SerialNumber=0000:00:02.1
C:* #Ifs= 1 Cfg#= 1 Atr=c0 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=   2 Ivl=255ms

T:  Bus=02 Lev=00 Prnt=00 Port=00 Cnt=00 Dev#=  1 Spd=12  MxCh= 2
B:  Alloc=  0/900 us ( 0%), #Int=  0, #Iso=  0
D:  Ver= 1.10 Cls=09(hub  ) Sub=00 Prot=00 MxPS= 8 #Cfgs=  1
P:  Vendor=0000 ProdID=0000 Rev= 2.06
S:  Manufacturer=Linux 2.6.8.1 uhci_hcd
S:  Product=VIA Technologies, Inc. VT82xxxxx UHCI USB 1.1 Controller
S:  SerialNumber=0000:00:02.0
C:* #Ifs= 1 Cfg#= 1 Atr=c0 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=   2 Ivl=255ms

T:  Bus=01 Lev=00 Prnt=00 Port=00 Cnt=00 Dev#=  1 Spd=480 MxCh= 4
B:  Alloc=  0/800 us ( 0%), #Int=  0, #Iso=  0
D:  Ver= 2.00 Cls=09(hub  ) Sub=00 Prot=01 MxPS= 8 #Cfgs=  1
P:  Vendor=0000 ProdID=0000 Rev= 2.06
S:  Manufacturer=Linux 2.6.8.1 ehci_hcd
S:  Product=VIA Technologies, Inc. USB 2.0
S:  SerialNumber=0000:00:02.2
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=   2 Ivl=256ms

T:  Bus=01 Lev=01 Prnt=01 Port=01 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=1005 ProdID=b113 Rev= 1.00
S:  Product=USB Flash Drive
S:  SerialNumber=070200012791ED0
C:* #Ifs= 1 Cfg#= 1 Atr=80 MxPwr=500mA
I:  If#= 0 Alt= 0 #EPs= 2 Cls=08(stor.) Sub=06 Prot=50 Driver=usb-storage
E:  Ad=81(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E:  Ad=02(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
---------------------------------------------------------------------

/>cat /proc/scsi/scsi
---------------------------------------------------------------------
Attached devices:
Host: scsi0 Channel: 00 Id: 00 Lun: 00
  Vendor: USB      Model: Flash Drive      Rev: 1.12
  Type:   Direct-Access                    ANSI SCSI revision: 02
----------------------------------------------------------------------  

/>cat /proc/scsi/usb-storage/0
------------------------------------------------
   Host scsi0: usb-storage
       Vendor: Unknown
      Product: USB Flash Drive
Serial Number: 070200012791ED0
     Protocol: Transparent SCSI
    Transport: Bulk
       Quirks:  
------------------------------------------
I try to mount it
but it shows "mount: Mounting /dev/sda1 on /mnt failed: No such device or address"
and I use fdisk the messages is below

--------------------------------------------------------------------------
Command (m for help): n
Command action
   e   extended
   p   primary partition (1-4)
p
Partition number (1-4): 1
First cylinder (1-1023, default 1):
Using default value 1
Last cylinder or +size or +sizeM or +sizeK (1-47, default 47):
Using default value 47

Command (m for help): w
The partition table has been altered!

Calling ioctl() to re-read partition table.
SCSI error : <0 0 0 0> return code = 0x70000
end_request: I/O error, dev sda, sector 0
usb 1-2: reset high speed USB device using address 2
usb 1-2: control timeout on ep0in
usb 1-2: control timeout on ep0out
usb 1-2: device not accepting address 2, error -110
scsi: Device offlined - not ready after error recovery: host 0 channel 0 id 0 lun 0
usb 1-2: USB disconnect, address 2
scsi0 (0:0): rejecting I/O to dead device
scsi0 (0:0): rejecting I/O to dead device
scsi0 (0:0): rejecting I/O to dead device
sda : READ CAPACITY failed.
sda : status=0, message=00, host=5, driver=04
sda : sense not available.
sda: assuming Write Enabled
sda: assuming drive cache: write through
 sda:<3>scsi0 (0:0): rejecting I/O to dead device
Buffer I/O error on device sda, logical block 0
Buffer I/O error on device sda, logical block 1
Buffer I/O error on device sda, logical block 2
Buffer I/O error on device sda, logical block 3
Buffer I/O error on device sda, logical block 4
Buffer I/O error on device sda, logical block 5
Buffer I/O error on device sda, logical block 6
Buffer I/O error on device sda, logical block 7
usb 1-2: new high speed USB device using address 3
scsi0 (0:0): rejecting I/O to dead device
Buffer I/O error on device sda, logical block 0
Buffer I/O error on device sda, logical block 1
Buffer I/O error on device sda, logical block 2
Buffer I/O error on device sda, logical block 3
Buffer I/O error on device sda, logical block 4
Buffer I/O error on device sda, logical block 5
Buffer I/O error on device sda, logical block 6
Buffer I/O error on device sda, logical block 7
 unable to read partition table
Re-read table failed with error 5: Input/output error.
Reboot your system to ensure the partition table is updated.

WARNING: If you have created or modified any DOS 6.x
partitions, please see the fdisk manual page for additional
information.
Syncing disks.
/> usb 1-2: control timeout on ep0in
usb 1-2: control timeout on ep0out
usb 1-2: device not accepting address 3, error -110
usb 1-2: new high speed USB device using address 4
usb 1-2: control timeout on ep0in
usb 1-2: device not accepting address 4, error -71 
----------------------------------------------------------------------------

Thanks and Regards,
Patrick
Comment 1 Andrew Perrin 2005-10-19 17:58:42 UTC
Created attachment 6336 [details]
Same error, different brand USB pen drive

Corroboration of same error using a different pen drive, this time a "giveaway"
one. It mounts fine under 2.6.8 but by 2.6.12 these errors show up.
Comment 2 Matthew Dharm 2005-11-15 21:40:29 UTC
This looks like two separate bugs.  I'm only going to deal with the first one; 
please file a separate report for the second, which appears to be an OHCI HCD 
problem.

With the first USB flash device, have you tried mounting /dev/sda (notice no 
number) instead of /dev/sda1 ?  The provided logs show the device refusing to 
have a partition table written to (which is not uncommon for some USB flash 
devices), but otherwise communication appears to be working perfectly.  I 
suspect that if you mount /dev/sda it will work.
Comment 3 Greg Kroah-Hartman 2006-03-06 10:41:29 UTC
No response in 4 months, closing.  If this is still a problem, please reopen
with the requested information.

Note You need to log in before you can comment on or make changes to this bug.