[PATCH v1 1/2] Remove hardcoded block size shifts
Gao Xiang
hsiangkao at linux.alibaba.com
Wed May 31 09:51:01 AEST 2023
On 2023/5/31 04:24, Kelvin Zhang wrote:
> This improves support for non 4K block sizes
>
> Signed-off-by: Kelvin Zhang <zhangkelvin at google.com>
Reviewed-by: Gao Xiang <hsiangkao at linux.alibaba.com>
Thanks,
Gao Xiang
> ---
> lib/compress.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/lib/compress.c b/lib/compress.c
> index 06bacdb..ae0838c 100644
> --- a/lib/compress.c
> +++ b/lib/compress.c
> @@ -766,7 +766,7 @@ static void z_erofs_write_mapheader(struct erofs_inode *inode,
> .h_algorithmtype = inode->z_algorithmtype[1] << 4 |
> inode->z_algorithmtype[0],
> /* lclustersize */
> - .h_clusterbits = inode->z_logical_clusterbits - 12,
> + .h_clusterbits = inode->z_logical_clusterbits - sbi.blkszbits,
> };
>
> if (inode->z_advise & Z_EROFS_ADVISE_FRAGMENT_PCLUSTER)
More information about the Linux-erofs
mailing list