Re: [PATCH] fat: silence warning for 64KB PAGE_SIZE builds

From: OGAWA Hirofumi
Date: Wed Nov 07 2007 - 09:39:30 EST


Olof Johansson <olof@xxxxxxxxx> writes:

> logical_sector_size can never be more than 16 bits worth, but switching
> it to an int silences gcc. It's a sanity check that can never fail with
> 64KB PAGE_SIZE but it seems like it'd still be useful for other page
> sizes, so it's worth keeping:
>
> if (!is_power_of_2(logical_sector_size)
> || (logical_sector_size < 512)
> || (PAGE_CACHE_SIZE < logical_sector_size)) {
> if (!silent)
> printk(KERN_ERR "FAT: bogus logical sector size %u\n",
> logical_sector_size);
> brelse(bh);
> goto out_invalid;
> }

Please use 4096 instead of allowing it, at least for now.
--
OGAWA Hirofumi <hirofumi@xxxxxxxxxxxxxxxxxx>
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/