]> www.infradead.org Git - users/dwmw2/linux.git/commit
block: hoist block size validation code to a separate function
authorDarrick J. Wong <djwong@kernel.org>
Wed, 23 Apr 2025 19:53:57 +0000 (12:53 -0700)
committerJens Axboe <axboe@kernel.dk>
Wed, 23 Apr 2025 19:58:06 +0000 (13:58 -0600)
commite03463d247ddac66e71143468373df3d74a3a6bd
treeccfa461bcf8fce4344aa3332801ce70f0df23fce
parentc0e473a0d226479e8e925d5ba93f751d8df628e9
block: hoist block size validation code to a separate function

Hoist the block size validation code to bdev_validate_blocksize so that
we can call it from filesystems that don't care about the bdev pagecache
manipulations of set_blocksize.

Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Luis Chamberlain <mcgrof@kernel.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Link: https://lore.kernel.org/r/174543795720.4139148.840349813093799165.stgit@frogsfrogsfrogs
Signed-off-by: Jens Axboe <axboe@kernel.dk>
block/bdev.c
include/linux/blkdev.h