Since gdsize_total is known to be a multiple of blksz, there is no need to recompute the value later in the function. Just use the variable, to avoid what might look like an overflow.
Signed-off-by: Simon Glass <s...@chromium.org> --- (no changes since v1) fs/ext4/ext4_write.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/ext4/ext4_write.c b/fs/ext4/ext4_write.c index f9d5eccb2ca..e77fb383a90 100644 --- a/fs/ext4/ext4_write.c +++ b/fs/ext4/ext4_write.c @@ -125,7 +125,7 @@ int ext4fs_get_bgdtable(void) return -ENOMEM; /* read the group descriptor table */ status = ext4fs_devread((lbaint_t)fs->gdtable_blkno * fs->sect_perblk, - 0, fs->blksz * fs->no_blk_pergdt, fs->gdtable); + 0, gdsize_total, fs->gdtable); if (status == 0) goto fail; -- 2.43.0