From: Hillf Danton <hdanton@sina.com>
To: syzbot <syzbot+3ca210b2c10e57015b3c@syzkaller.appspotmail.com>
Cc: linux-kernel@vger.kernel.org, syzkaller-bugs@googlegroups.com
Subject: Re: [syzbot] [ext4?] WARNING: locking bug in ext4_xattr_inode_update_ref (3)
Date: Thu, 11 Apr 2024 19:39:39 +0800 [thread overview]
Message-ID: <20240411113939.749-1-hdanton@sina.com> (raw)
In-Reply-To: <0000000000009adc640615cf0ef7@google.com>
On Thu, 11 Apr 2024 02:48:27 -0700
> syzbot found the following issue on:
>
> HEAD commit: f2f80ac80987 Merge tag 'nfsd-6.9-2' of git://git.kernel.or..
> git tree: upstream
> C reproducer: https://syzkaller.appspot.com/x/repro.c?x=1614c105180000
#syz test https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git f2f80ac80987
--- x/fs/ext4/xattr.c
+++ y/fs/ext4/xattr.c
@@ -119,11 +119,12 @@ ext4_expand_inode_array(struct ext4_xatt
struct inode *inode);
#ifdef CONFIG_LOCKDEP
+static struct lock_class_key ea_i_rwsem_key;
void ext4_xattr_inode_set_class(struct inode *ea_inode)
{
struct ext4_inode_info *ei = EXT4_I(ea_inode);
- lockdep_set_subclass(&ea_inode->i_rwsem, 1);
+ lockdep_set_class(&ea_inode->i_rwsem, &ea_i_rwsem_key);
(void) ei; /* shut up clang warning if !CONFIG_LOCKDEP */
lockdep_set_subclass(&ei->i_data_sem, I_DATA_SEM_EA);
}
--
next prev parent reply other threads:[~2024-04-11 11:39 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-04-11 9:48 syzbot
2024-04-11 11:39 ` Hillf Danton [this message]
2024-04-11 12:02 ` syzbot
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240411113939.749-1-hdanton@sina.com \
--to=hdanton@sina.com \
--cc=linux-kernel@vger.kernel.org \
--cc=syzbot+3ca210b2c10e57015b3c@syzkaller.appspotmail.com \
--cc=syzkaller-bugs@googlegroups.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®