This is a note to let you know that I've just added the patch titled ext4: fix leaking sysfs kobject after failed mount to the 4.9-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-leaking-sysfs-kobject-after-failed-mount.patch and it can be found in the queue-4.9 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let <stable@xxxxxxxxxxxxxxx> know about it. >From cb8d53d2c97369029cc638c9274ac7be0a316c75 Mon Sep 17 00:00:00 2001 From: Eric Biggers <ebiggers@xxxxxxxxxx> Date: Tue, 22 Sep 2020 09:24:56 -0700 Subject: ext4: fix leaking sysfs kobject after failed mount From: Eric Biggers <ebiggers@xxxxxxxxxx> commit cb8d53d2c97369029cc638c9274ac7be0a316c75 upstream. ext4_unregister_sysfs() only deletes the kobject. The reference to it needs to be put separately, like ext4_put_super() does. This addresses the syzbot report "memory leak in kobject_set_name_vargs (3)" (https://syzkaller.appspot.com/bug?extid=9f864abad79fae7c17e1). Reported-by: syzbot+9f864abad79fae7c17e1@xxxxxxxxxxxxxxxxxxxxxxxxx Fixes: 72ba74508b28 ("ext4: release sysfs kobject when failing to enable quotas on mount") Cc: stable@xxxxxxxxxxxxxxx Signed-off-by: Eric Biggers <ebiggers@xxxxxxxxxx> Link: https://lore.kernel.org/r/20200922162456.93657-1-ebiggers@xxxxxxxxxx Reviewed-by: Jan Kara <jack@xxxxxxx> Signed-off-by: Theodore Ts'o <tytso@xxxxxxx> [sudip: adjust context] Signed-off-by: Sudip Mukherjee <sudipm.mukherjee@xxxxxxxxx> Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx> --- fs/ext4/super.c | 1 + 1 file changed, 1 insertion(+) --- a/fs/ext4/super.c +++ b/fs/ext4/super.c @@ -4336,6 +4336,7 @@ cantfind_ext4: #ifdef CONFIG_QUOTA failed_mount8: ext4_unregister_sysfs(sb); + kobject_put(&sbi->s_kobj); #endif failed_mount7: ext4_unregister_li_request(sb); Patches currently in stable-queue which might be from ebiggers@xxxxxxxxxx are queue-4.9/ext4-fix-leaking-sysfs-kobject-after-failed-mount.patch