Subject: Re: mass storage usb camera
To: None <netbsd-users@netbsd.org>
From: David Laight <David.Laight@btinternet.com>
List: netbsd-users
Date: 12/15/2001 16:18:39
> On Sat, Dec 15, 2001 at 12:31:04AM +0100, Wojciech Puchar wrote:
> > > sd0 at scsibus0 target 1 lun 0: <OLYMPUS, C-1, 1062> SCSI2 0/direct
> > >      removable
> > > sd0: mode sense (4) returned nonsense; using fictitious geometry
> > > sd0: 16000 KB, 15 cyl, 64 head, 32 sec, 512 bytes/sect x 32000 sectors
> >
> > why it's 16000 not 16384?
> 
> probably because some flash card vendors (like disk vendors) use 1000
> instead of 1024 for MB, so "16MB" == "16000 KB" ?

At least that one is (in some sense) the size that it says on the tin.
Some card are considerably smaller!

I believe that the reason for the discrepency is that the cards have some
form of 'FTL' to allow single 512 byte sector to be written to a device
where the chip erase sector is (probably) 128k bytes.

This also means that they inherently do 'wear leveling' - at least to some
degree.

I also suspect that performance would be improved if the filesystem code
sent 'erase sector' requests when deleting a file.

    David