Patch "ext4: fix wrong unit use in ext4_mb_new_blocks" has been added to the 6.1-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    ext4: fix wrong unit use in ext4_mb_new_blocks

to the 6.1-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     ext4-fix-wrong-unit-use-in-ext4_mb_new_blocks.patch
and it can be found in the queue-6.1 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.


>From 2ec6d0a5ea72689a79e6f725fd8b443a788ae279 Mon Sep 17 00:00:00 2001
From: Kemeng Shi <shikemeng@xxxxxxxxxxxxxxx>
Date: Sat, 3 Jun 2023 23:03:19 +0800
Subject: ext4: fix wrong unit use in ext4_mb_new_blocks

From: Kemeng Shi <shikemeng@xxxxxxxxxxxxxxx>

commit 2ec6d0a5ea72689a79e6f725fd8b443a788ae279 upstream.

Function ext4_free_blocks_simple needs count in cluster. Function
ext4_free_blocks accepts count in block. Convert count to cluster
to fix the mismatch.

Signed-off-by: Kemeng Shi <shikemeng@xxxxxxxxxxxxxxx>
Cc: stable@xxxxxxxxxx
Reviewed-by: Ojaswin Mujoo <ojaswin@xxxxxxxxxxxxx>
Link: https://lore.kernel.org/r/20230603150327.3596033-12-shikemeng@xxxxxxxxxxxxxxx
Signed-off-by: Theodore Ts'o <tytso@xxxxxxx>
Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>
---
 fs/ext4/mballoc.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/fs/ext4/mballoc.c
+++ b/fs/ext4/mballoc.c
@@ -6166,7 +6166,7 @@ void ext4_free_blocks(handle_t *handle,
 	}
 
 	if (sbi->s_mount_state & EXT4_FC_REPLAY) {
-		ext4_free_blocks_simple(inode, block, count);
+		ext4_free_blocks_simple(inode, block, EXT4_NUM_B2C(sbi, count));
 		return;
 	}
 


Patches currently in stable-queue which might be from shikemeng@xxxxxxxxxxxxxxx are

queue-6.1/ext4-fix-wrong-unit-use-in-ext4_mb_new_blocks.patch
queue-6.1/ext4-fix-wrong-unit-use-in-ext4_mb_clear_bb.patch
queue-6.1/ext4-get-block-from-bh-in-ext4_free_blocks-for-fast-commit-replay.patch



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux