USB-Stick stopped working in recent kernels: capacity change to 0

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



hi,

i have a type of usb-stick that works fine under older kernels (tested on
2.6.34 and 2.6.37) but stopped working for 3.0 and 3.1


this is a working insert:

[ 2983.692212] usb 1-5.1.1.4: new high speed USB device using ehci_hcd and
address 9
[ 2983.780096] usb 1-5.1.1.4: New USB device found, idVendor=1307,
idProduct=0163
[ 2983.780104] usb 1-5.1.1.4: New USB device strings: Mfr=1, Product=2,
SerialNumber=3
[ 2983.780110] usb 1-5.1.1.4: Product: USB Mass Storage Device
[ 2983.780115] usb 1-5.1.1.4: Manufacturer: USBest Technology
[ 2983.780119] usb 1-5.1.1.4: SerialNumber: 00000000000B8E
[ 2983.781017] scsi5 : usb-storage 1-5.1.1.4:1.0
[ 2984.782242] scsi 5:0:0:0: Direct-Access     UDISK    PDU01_1G 81I2.0
0.00 PQ: 0 ANSI: 2
[ 2984.782381] sd 5:0:0:0: Attached scsi generic sg4 type 0
[ 2984.785565] sd 5:0:0:0: [sdd] 1974271 512-byte logical blocks: (1.01
GB/963 MiB)
[ 2984.786562] sd 5:0:0:0: [sdd] Write Protect is off
[ 2984.786566] sd 5:0:0:0: [sdd] Mode Sense: 00 00 00 00
[ 2984.786568] sd 5:0:0:0: [sdd] Assuming drive cache: write through
[ 2984.790049] sd 5:0:0:0: [sdd] Assuming drive cache: write through
[ 2984.790053]  sdd: sdd1
[ 2984.849583] sd 5:0:0:0: [sdd] Assuming drive cache: write through
[ 2984.849591] sd 5:0:0:0: [sdd] Attached SCSI removable disk



but it seems that the reading of new sticks got a little stricter and now
under 3.0 and 3.1 it looks like this:


[80223.706240] usb 2-1.7.3: new high speed USB device number 10 using ehci_hcd
[80223.793713] usb 2-1.7.3: New USB device found, idVendor=1307, idProduct=0163
[80223.793722] usb 2-1.7.3: New USB device strings: Mfr=1, Product=2,
SerialNumber=3
[80223.793728] usb 2-1.7.3: Product: USB Mass Storage Device
[80223.793733] usb 2-1.7.3: Manufacturer: USBest Technology
[80223.793738] usb 2-1.7.3: SerialNumber: 00000000000B8E
[80223.794252] scsi12 : usb-storage 2-1.7.3:1.0
[80224.793717] scsi 12:0:0:0: Direct-Access     UDISK    PDU01_1G 81I2.0
0.00 PQ: 0 ANSI: 2
[80224.793965] sd 12:0:0:0: Attached scsi generic sg13 type 0
[80224.795276] sd 12:0:0:0: [sdl] 1974271 512-byte logical blocks: (1.01
GB/963 MiB)
[80224.796147] sd 12:0:0:0: [sdl] Write Protect is off
[80224.796150] sd 12:0:0:0: [sdl] Mode Sense: 00 00 00 00
[80224.797032] sd 12:0:0:0: [sdl] Asking for cache data failed
[80224.797037] sd 12:0:0:0: [sdl] Assuming drive cache: write through
[80224.801171] sd 12:0:0:0: [sdl] Asking for cache data failed
[80224.801177] sd 12:0:0:0: [sdl] Assuming drive cache: write through
[80224.858689]  sdl: sdl1
[80224.861985] sd 12:0:0:0: [sdl] Asking for cache data failed
[80224.861989] sd 12:0:0:0: [sdl] Assuming drive cache: write through
[80224.861991] sd 12:0:0:0: [sdl] Attached SCSI removable disk
[80231.450605] sdl: detected capacity change from 1010826752 to 0
[80231.451612] sd 12:0:0:0: [sdl] 1974271 512-byte logical blocks: (1.01
GB/963 MiB)
[80231.452603] sd 12:0:0:0: [sdl] Asking for cache data failed
[80231.452605] sd 12:0:0:0: [sdl] Assuming drive cache: write through
[80231.454230] sd 12:0:0:0: [sdl] Asking for cache data failed
[80231.454233] sd 12:0:0:0: [sdl] Assuming drive cache: write through
[80231.455871]  sdl: sdl1
[80233.455182] sdl: detected capacity change from 1010826752 to 0
[80233.456218] sd 12:0:0:0: [sdl] 1974271 512-byte logical blocks: (1.01
GB/963 MiB)


the detection and changing of capacity to 0 repeats over and over.

i have two sticks of the same type and they both show this behaviour.

when i lsusb -v it (see attachments), changing timeouts when reading
drescriptors/qualifiers happen on both kernel versions. (i tried multiple
sticks on multiple kernels and systems).

so there seems to be something wrong/different with the type of stick to
begin with, as it seems to be slow in answering to the requests sent by
lsusb. but apart from the timeouts on lsusb, the stick works fine under
older kernels.


in of of the lsusb outputs, it hangs for 1-2 seconds before outputting
anything and the output ends in:

          Usage Type               Data
        wMaxPacketSize     0x0040  1x 64 bytes
        bInterval               8
        bInterval               8
can't get device qualifier: Connection timed out
can't get debug descriptor: Connection timed out
cannot read device status, Connection timed out (110)



it looks like initialization got a little stricter in recent kernels and now
the kernel rejects this stick.

is this the case?

does my interpretation make sense?


if yes, are there any settings that control timeouts/retries that i could
change to tune the initialization behaviour?


since the stick works fine on other systems, it would be nice if it worked
under recent linux kernels as well.


i recorded some usbmon logs, if those would help.


i can do more tests with other kernels, but i thought i'd ask what kind of
information would be helpful before i do more debugging.


tty, axel



Bus 001 Device 017: ID 1307:0163 Transcend Information, Inc. 512MB/1GB Flash Drive
Device Descriptor:
  bLength                18
  bDescriptorType         1
  bcdUSB               2.00
  bDeviceClass            0 (Defined at Interface level)
  bDeviceSubClass         0 
  bDeviceProtocol         0 
  bMaxPacketSize0        64
  idVendor           0x1307 Transcend Information, Inc.
  idProduct          0x0163 512MB/1GB Flash Drive
  bcdDevice            1.00
  iManufacturer           1 
  iProduct                2 
  iSerial                 3 
  bNumConfigurations      1
  Configuration Descriptor:
    bLength                 9
    bDescriptorType         2
    wTotalLength           39
    bNumInterfaces          1
    bConfigurationValue     1
    iConfiguration          0 
    bmAttributes         0x80
      (Bus Powered)
    MaxPower               80mA
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        0
      bAlternateSetting       0
      bNumEndpoints           3
      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     0x0200  1x 512 bytes
        bInterval               1
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x82  EP 2 IN
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0200  1x 512 bytes
        bInterval               1
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x83  EP 3 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0040  1x 64 bytes
        bInterval               8
can't get device qualifier: Connection timed out
can't get debug descriptor: Connection timed out
cannot read device status, Connection timed out (110)

merceile:~ # lsusb -v -d 1307:0163

Bus 001 Device 007: ID 1307:0163 Transcend Information, Inc. 256MB/512MB/1GB Flash Drive
Device Descriptor:
  bLength                18
  bDescriptorType         1
  bcdUSB               2.00
  bDeviceClass            0 (Defined at Interface level)
  bDeviceSubClass         0 
  bDeviceProtocol         0 
  bMaxPacketSize0        64
  idVendor           0x1307 Transcend Information, Inc.
  idProduct          0x0163 256MB/512MB/1GB Flash Drive
  bcdDevice            1.00
  iManufacturer           1 USBest Technology
  iProduct                2 USB Mass Storage Device                                                                                                                                                           
  iSerial                 3 000000000000F0                                                                                                                                                                    
  bNumConfigurations      1                                                                                                                                                                                   
  Configuration Descriptor:                                                                                                                                                                                   
    bLength                 9                                                                                                                                                                                 
    bDescriptorType         2                                                                                                                                                                                 
    wTotalLength           39                                                                                                                                                                                 
    bNumInterfaces          1                                                                                                                                                                                 
    bConfigurationValue     1                                                                                                                                                                                 
    iConfiguration          0                                                                                                                                                                                 
    bmAttributes         0x80                                                                                                                                                                                 
      (Bus Powered)                                                                                                                                                                                           
    MaxPower               80mA                                                                                                                                                                               
    Interface Descriptor:                                                                                                                                                                                     
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        0
      bAlternateSetting       0
      bNumEndpoints           3
      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     0x0200  1x 512 bytes
        bInterval               1
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x82  EP 2 IN
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0200  1x 512 bytes
        bInterval               1
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x83  EP 3 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0040  1x 64 bytes
        bInterval               8
Device Qualifier (for other device speed):
  bLength                10
  bDescriptorType         6
  bcdUSB               2.00
  bDeviceClass            0 (Defined at Interface level)
  bDeviceSubClass         0 
  bDeviceProtocol         0 
  bMaxPacketSize0        64
  bNumConfigurations      1
Device Status:     0x0001
  Self Powered

Provaia01:~ # lsusb -v -d 1307:0163 

Bus 002 Device 012: ID 1307:0163 Transcend Information, Inc. 512MB/1GB Flash Drive
Device Descriptor:
  bLength                18
  bDescriptorType         1
  bcdUSB               2.00
  bDeviceClass            0 (Defined at Interface level)
  bDeviceSubClass         0 
  bDeviceProtocol         0 
  bMaxPacketSize0        64
  idVendor           0x1307 Transcend Information, Inc.
  idProduct          0x0163 512MB/1GB Flash Drive
  bcdDevice            1.00
  iManufacturer           1 USBest Technology
  iProduct                2 USB Mass Storage Device
  iSerial                 3 000000000000F0
  bNumConfigurations      1
  Configuration Descriptor:
    bLength                 9
    bDescriptorType         2
    wTotalLength           39
    bNumInterfaces          1
    bConfigurationValue     1
    iConfiguration          0 
    bmAttributes         0x80
      (Bus Powered)
    MaxPower               80mA
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        0
      bAlternateSetting       0
      bNumEndpoints           3
      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     0x0200  1x 512 bytes
        bInterval               1
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x82  EP 2 IN
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0200  1x 512 bytes
        bInterval               1
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x83  EP 3 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0040  1x 64 bytes
        bInterval               8
Device Qualifier (for other device speed):
  bLength                10
  bDescriptorType         6
  bcdUSB               2.00
  bDeviceClass            0 (Defined at Interface level)
  bDeviceSubClass         0 
  bDeviceProtocol         0 
  bMaxPacketSize0        64
  bNumConfigurations      1
can't get debug descriptor: Numerical result out of range
Device Status:     0x0000
  (Bus Powered)


[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux