From: Zhang Yi yi.zhang@huawei.com
hulk inclusion category: bugfix bugzilla: https://gitee.com/openeuler/kernel/issues/I4VAQC?from=project-issue CVE: NA
--------------------------------
Fix a compile error on arm32 architecture.
build failed: arm, allmodconfig
ERROR: modpost: "__aeabi_ldivmod" [fs/ext4/ext4.ko] undefined! make[1]: *** [modules-only.symvers] Error 1 make[1]: *** Deleting file 'modules-only.symvers' make: *** [modules] Error 2
Fixes: 356efe60eb78 ("ext4: fix underflow in ext4_max_bitmap_size()") Signed-off-by: Zhang Yi yi.zhang@huawei.com Reviewed-by: Yang Erkun yangerkun@huawei.com Signed-off-by: Zheng Zengkai zhengzengkai@huawei.com --- fs/ext4/super.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/fs/ext4/super.c b/fs/ext4/super.c index 19539be45aec..f1a089ebe848 100644 --- a/fs/ext4/super.c +++ b/fs/ext4/super.c @@ -3274,15 +3274,15 @@ static loff_t ext4_max_bitmap_size(int bits, int has_huge_files) upper_limit -= ppb; /* double indirect blocks */ if (upper_limit < ppb * ppb) { - meta_blocks += 1 + DIV_ROUND_UP(upper_limit, ppb); + meta_blocks += 1 + DIV_ROUND_UP_ULL(upper_limit, ppb); res -= meta_blocks; goto check_lfs; } meta_blocks += 1 + ppb; upper_limit -= ppb * ppb; /* tripple indirect blocks for the rest */ - meta_blocks += 1 + DIV_ROUND_UP(upper_limit, ppb) + - DIV_ROUND_UP(upper_limit, ppb*ppb); + meta_blocks += 1 + DIV_ROUND_UP_ULL(upper_limit, ppb) + + DIV_ROUND_UP_ULL(upper_limit, ppb*ppb); res -= meta_blocks; check_lfs: res <<= bits;