Partition type isn't available to fs driver. Think about mounting
floppy/loopback/etc.
Seems you guys are discussing non-problem here. What really needs to be done
is to add more sanity checks to FAT superblock detection/validation code:
* signatures like 55AA at end of 1st sector
* sane values for various superblock data (if you see "FAT copies: 146"
it is more than enough to tell it's not a FAT, right?)
If anyone feels so inclined, please go to fs/fat/inode.c:fat_read_super()
and hack on it. Send your patches to Alexander Viro <viro@math.psu.edu>
and tighten your seatbelt ;-)
> While mounting a partition, the vfs layer tries to determine the partition
> type, and passes that info to the filesystem driver, which checks whether
> that partition type can be mounted by the driver. If no partition type is
> provided by the vfs layer (for the partition type is not available in the
> used partition table, or whatever), the fs driver must try to find out
> itself.
-- vda - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/