On Sat, 29 Sep 2007, Stefan Richter wrote:

> Hi list,
> 
> I've got the mentioned MP3 player with 4GB built-in flash memory and an
> SD/SDHC card slot.  The player worked under Linux with the shipped
> firmware, but in order to make its card slot SDHC compatible I installed
> their current firmware v2.50.  The USB mass storage driver of that
> firmware still seems to work on Windows (shows built-in flash and card
> slot as two separate drive letters), became a bit quirkier on OS X (is
> shown as invalid volume upon connection, is then quickly recognized as
> it should and can be accessed, immediately reinserts itself when it was
> "ejected"), but hardly works under Linux.
> 
> With card slot empty:
...
> sd 71:0:0:0: [sdd] 1 512-byte hardware sectors (0 MB)
...
> Can't do much with that.

Indeed.  Without a card in the slot you can't do much with it, no
matter what shows up in the log.

(It might be worth mentioning that the firmware's behavior in this case 
was not correct.  It should have returned an error code indicating no 
card was present, instead of pretending there was a 0-MB card.)

> With an 8GB SDHC card inserted:
> 
> usb 1-8: new high speed USB device using ehci_hcd and address 24
> usb 1-8: configuration #1 chosen from 1 choice
> scsi72 : SCSI emulation for USB Mass Storage devices
> usb-storage: device found at 24
> usb-storage: waiting for device to settle before scanning
> scsi 72:0:0:0: Direct-Access     COWON    D2               0100 PQ: 0
> ANSI: 0
> sd 72:0:0:0: [sdd] 15728160 512-byte hardware sectors (8053 MB)
> sd 72:0:0:0: [sdd] Write Protect is off
> sd 72:0:0:0: [sdd] Mode Sense: 37 00 00 08
> sd 72:0:0:0: [sdd] Assuming drive cache: write through
> sd 72:0:0:0: [sdd] 15728160 512-byte hardware sectors (8053 MB)
> sd 72:0:0:0: [sdd] Write Protect is off
> sd 72:0:0:0: [sdd] Mode Sense: 37 00 00 08
> sd 72:0:0:0: [sdd] Assuming drive cache: write through
>  sdd: sdd1
>  sdd: p1 exceeds device capacity
> sd 72:0:0:0: [sdd] Attached SCSI removable disk
> sd 72:0:0:0: Attached scsi generic sg4 type 0
> usb-storage: device scan complete
> attempt to access beyond end of device
> sdd: rw=0, want=15758216, limit=15728160
> Buffer I/O error on device sdd1, logical block 1968752
> [repeated]
> attempt to access beyond end of device
> sdd: rw=0, want=15758280, limit=15728160
> [repeated]
> 
> Then I can at least access the SDHC card.

What makes you think there's a problem?  Evidently the partition table 
is goofy, but you can easily repartition the card.  It sure looks like 
everything is working correctly.

> $ ls /sys/bus/usb/devices/1-8*/
> /sys/bus/usb/devices/1-8/:
> 1-8:1.0              bNumConfigurations  dev           maxchild   uevent
> bConfigurationValue  bNumInterfaces      devnum        power
> usb_endpoint
> bDeviceClass         bcdDevice           driver        product    version
> bDeviceProtocol      bmAttributes        ep_00         quirks
> bDeviceSubClass      busnum              idProduct     serial
> bMaxPacketSize0      configuration       idVendor      speed
> bMaxPower            descriptors         manufacturer  subsystem
> 
> /sys/bus/usb/devices/1-8:1.0/:
> bAlternateSetting  bInterfaceProtocol  driver  ep_83     power
> usb_endpoint
> bInterfaceClass    bInterfaceSubClass  ep_02   host72    subsystem
> bInterfaceNumber   bNumEndpoints       ep_81   modalias  uevent

There's not much point in these directory listings.  The names of the 
files don't convey any useful information; what matters is their 
contents.

> The initial successful tests with the old firmware and what you see
> above is with Linux 2.6.23-rc6.
> 
> Questions:
>   - Are there usb-storage or scsi-mod workarounds which are good
>     candidates to make it work?

As far as I can see, it's working already.

>   - Is there a way to specify quirks to usb-storage at runtime?

No.

Alan Stern


-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Linux-usb-users@lists.sourceforge.net
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-users

Reply via email to