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

Re: FAT and Stores




On Wed, 13 Jun 2001, Roland McGrath wrote:

> > When mounting a floppy drive, however, I get:
> > bytes_per_sector = 512
> > store->block_size = 1024
> 
> This is odd.  Please try storeinfo and storeread on the floppy device.
> (I presume you are using /dev/fd0 with the usual /hurd/storeio translator.)
> See what that shows you, and with storeread you can actually try to read 
> 512 bytes from offset 512 and that just won't work if the block size is
> really 1024.  You can also try the same with dd on /dev/fd0.


here is my result from storeinfo:

hurd:~# storeinfo /dev/fd0
device (h_ro,enf): fd0: 1024: 1440: 1474560: 0+1440


If that's not weird enough (block size 1024), storeread works for
--block-size=1024, but this is my output for --block-size=512:

hurd:~# storeread --block-size=512 /dev/fd0 1 512
storeread: ../../libstore/rdwr.c:188: store_read: Assertion `(amount &
(store->block_size - 1)) == 0' failed.

this is pretty much the same error as in the case when trying to mount
with fatfs it seems.  perhaps this is just a weird disk -- I think it is a
copy of a rescue disk distributed with a new PC, so perhaps there is some
weirdness there.  I will try a different fat12 disk and see what
happens.  Like I said, it works fine on hard drive partitions of bytes per
sector=512.  

> 
> All the floppy drivers I can find use a block size of 512, so I am
> confused.  It might be that storeinfo will show you that you are really
> using a file on your ext2fs filesystem (that happens to use 1k filesystem
> blocks), meaning your storeio translator is not set up right, which would
> make it all make sense.

The device seems to work ok.  dd gets an image of the floppy OK.  If it
works on "normal" disks, maybe I will put this bug on the backburner and
work on r/w support.


Thanks for the help,
Tom



Reply to: