aboutsummaryrefslogtreecommitdiffstats
path: root/net/switchdev/switchdev.c
diff options
context:
space:
mode:
authorBaokun Li <[email protected]>2024-01-04 14:20:37 +0000
committerTheodore Ts'o <[email protected]>2024-01-18 15:50:24 +0000
commit993bf0f4c393b3667830918f9247438a8f6fdb5b (patch)
treee5c9929fc1164ac0404405527dab201682e26801 /net/switchdev/switchdev.c
parentext4: avoid bb_free and bb_fragments inconsistency in mb_free_blocks() (diff)
downloadkernel-993bf0f4c393b3667830918f9247438a8f6fdb5b.tar.gz
kernel-993bf0f4c393b3667830918f9247438a8f6fdb5b.zip
ext4: avoid dividing by 0 in mb_update_avg_fragment_size() when block bitmap corrupt
Determine if bb_fragments is 0 instead of determining bb_free to eliminate the risk of dividing by zero when the block bitmap is corrupted. Signed-off-by: Baokun Li <[email protected]> Reviewed-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Theodore Ts'o <[email protected]>
Diffstat (limited to 'net/switchdev/switchdev.c')
0 files changed, 0 insertions, 0 deletions