This is a note to let you know that I've just added the patch titled ext4: fix ext4_error_err save negative errno into superblock to the 5.10-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-ext4_error_err-save-negative-errno-into-superblock.patch and it can be found in the queue-5.10 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let <stable@xxxxxxxxxxxxxxx> know about it. >From 6810fad956df9e5467e8e8a5ac66fda0836c71fa Mon Sep 17 00:00:00 2001 From: Ye Bin <yebin10@xxxxxxxxxx> Date: Tue, 6 Apr 2021 10:53:31 +0800 Subject: ext4: fix ext4_error_err save negative errno into superblock From: Ye Bin <yebin10@xxxxxxxxxx> commit 6810fad956df9e5467e8e8a5ac66fda0836c71fa upstream. Fix As write_mmp_block() so that it returns -EIO instead of 1, so that the correct error gets saved into the superblock. Cc: stable@xxxxxxxxxx Fixes: 54d3adbc29f0 ("ext4: save all error info in save_error_info() and drop ext4_set_errno()") Reported-by: Liu Zhi Qiang <liuzhiqiang26@xxxxxxxxxx> Signed-off-by: Ye Bin <yebin10@xxxxxxxxxx> Reviewed-by: Andreas Dilger <adilger@xxxxxxxxx> Link: https://lore.kernel.org/r/20210406025331.148343-1-yebin10@xxxxxxxxxx Signed-off-by: Theodore Ts'o <tytso@xxxxxxx> Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx> --- fs/ext4/mmp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/fs/ext4/mmp.c +++ b/fs/ext4/mmp.c @@ -56,7 +56,7 @@ static int write_mmp_block(struct super_ wait_on_buffer(bh); sb_end_write(sb); if (unlikely(!buffer_uptodate(bh))) - return 1; + return -EIO; return 0; } Patches currently in stable-queue which might be from yebin10@xxxxxxxxxx are queue-5.10/ext4-fix-ext4_error_err-save-negative-errno-into-superblock.patch