Re: [PATCH v2 7/8] block/bdev: lift block size restrictions to 64k

Matthew Wilcox
2025-02-17T22:01:35Z

On Tue, Feb 04, 2025 at 03:12:08PM -0800, Luis Chamberlain wrote:
> We now can support blocksizes larger than PAGE_SIZE, so in theory
> we should be able to lift the restriction up to the max supported page
> cache order. However bound ourselves to what we can currently validate
> and test. Through blktests and fstest we can validate up to 64k today.
>
> Reviewed-by: Hannes Reinecke <hare@suse.de>
> Signed-off-by: Luis Chamberlain <mcgrof@kernel.org>

Reviewed-by: Matthew Wilcox (Oracle) <willy@infradead.org>

> diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h
> index 248416ecd01c..a89513302977 100644
> --- a/include/linux/blkdev.h
> +++ b/include/linux/blkdev.h
> @@ -26,6 +26,7 @@
> #include <linux/xarray.h>
> #include <linux/file.h>
> #include <linux/lockdep.h>
> +#include <linux/pagemap.h>

We can drop this until we actually use

> + * We should strive for 1 << (PAGE_SHIFT + MAX_PAGECACHE_ORDER)

right? I don't see anything else that needs this include.