]> www.infradead.org Git - users/hch/misc.git/commit
erofs: fix blksize < PAGE_SIZE for file-backed mounts
authorHongzhen Luo <hongzhen@linux.alibaba.com>
Tue, 15 Oct 2024 10:38:36 +0000 (18:38 +0800)
committerGao Xiang <hsiangkao@linux.alibaba.com>
Mon, 18 Nov 2024 10:50:14 +0000 (18:50 +0800)
commitbae0854160939a64a092516ff1b2f221402b843b
tree32ca31717517c131f2d596ca8ea8f783b1d6d4b1
parentec4f59d1a99de86e5c14cf97946e94d5cef98ab0
erofs: fix blksize < PAGE_SIZE for file-backed mounts

Adjust sb->s_blocksize{,_bits} directly for file-backed
mounts when the fs block size is smaller than PAGE_SIZE.

Previously, EROFS used sb_set_blocksize(), which caused
a panic if bdev-backed mounts is not used.

Fixes: fb176750266a ("erofs: add file-backed mount support")
Signed-off-by: Hongzhen Luo <hongzhen@linux.alibaba.com>
Link: https://lore.kernel.org/r/20241015103836.3757438-1-hongzhen@linux.alibaba.com
Signed-off-by: Gao Xiang <hsiangkao@linux.alibaba.com>
fs/erofs/super.c