On Fri, Jun 15, 2012 at 09:19:23AM +0000, Arnd Bergmann wrote:
>
> The trouble is that detecting the erase block size requires us to
> write specific patterns to the device, which is generally a bad
> idea after the file system has been created.
How much space do you need? It's not hard to allocate a bunch of
space, in a file, use FIEMAP ioctl to verify that you have a
contiguous range of blocks, and then do direct I/O into that region.
> I think the best we can do is
>
> * default to "unspecified" as before
> * if "unspecified", make the file system ask the block device. in
> case of eMMC, that will usually be reliable
> * Add an option to mkfs and tunefs to hardcode a specific size for
> users that know the size and can't rely on the blockdev reporting
> it correctly to the file system.
> * Add an option to mkfs to autodetect the size for the drive it's
> run on.
Well, I think we can do better; the question is whether or not it's
worth the effort. It may not be....
- Ted
--
To unsubscribe from this list: send the line "unsubscribe linux-mmc" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html