[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[mtools] Mtools support for media with >512 byte sectors
From: |
Peter Jeremy |
Subject: |
[mtools] Mtools support for media with >512 byte sectors |
Date: |
Sat, 20 May 2006 15:07:16 +1000 |
User-agent: |
Mutt/1.5.11 |
My wife got a MP3 player for mother's day. Whilst I managed to
confirm that it was a standard USB mass storage device before buying
it, it doesn't have 512-byte sectors and as a result, mtools on
FreeBSD (6.1-RELEASE) doesn't like it. I did my testing on
mtools-3.9.9+mtools-3.9.9-20050228.diff but a visual check of the
changes in mtools-3.9.10+mtools-3.9.10-20060228b.diff shows the
problem is still present.
The player identifies as:
umass0: EM706S EM706S MP3 Player, rev 1.10/10.01, addr 2
umass0: SCSI over Bulk-Only; quirks = 0x0000
umass0:2:0:-1: Attached to scbus2
da0 at umass-sim0 bus 0 target 0 lun 0
da0: <EM706S MP3 Player 0100> Removable Direct Access SCSI-4 device
da0: 1.000MB/s transfers
da0: 491MB (251456 2048 byte sectors: 64H 32S/T 122C)
usbdevs reports:
port 3 addr 2: full speed, power 100 mA, config 1, EM706S MP3 Player(0x0706),
EM706S(0x067f), rev 10.01
The problem is the "2048 byte sectors". mtools is incompatible with
media with anything other than 512-byte sectors. Whilst there is a
"blocksize" configuration directive, it is over-ridden or ignored in a
number of places in the code. The first location I found was in
init.c::read_boot() where the read size is limited to 1KB. After
fixing that, I found that init.c::get_media_type() has 512 bytes
hard coded. At this point I decided it's not a trivial fix.
Has anyone else looked into fixing this problem?
--
Peter Jeremy
_______________________________________________
mtools mailing list
address@hidden
http://www.tux.org/mailman/listinfo/mtools
- [mtools] Mtools support for media with >512 byte sectors,
Peter Jeremy <=