ext4: return found group directly in ext4_mb_choose_next_group_p2_aligned
authorKemeng Shi <shikemeng@huaweicloud.com>
Tue, 1 Aug 2023 14:31:57 +0000 (22:31 +0800)
committerTheodore Ts'o <tytso@mit.edu>
Thu, 3 Aug 2023 14:47:30 +0000 (10:47 -0400)
commit919eb90cec4049cecf4a9f996afb0f14e3864fca
tree6a703d7c30d004ee6d1d80c00956aa5125f504e2
parent60c672b7f2d1e5dd1774f2399b355c9314e709f8
ext4: return found group directly in ext4_mb_choose_next_group_p2_aligned

Return good group when it's found in loop to remove unnecessary NULL
initialization of grp and futher check if good group is found after loop.

Signed-off-by: Kemeng Shi <shikemeng@huaweicloud.com>
Reviewed-by: Ritesh Harjani (IBM) <ritesh.list@gmail.com>
Link: https://lore.kernel.org/r/20230801143204.2284343-4-shikemeng@huaweicloud.com
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
fs/ext4/mballoc.c