[syzbot] [f2fs?] WARNING: locking bug in f2fs_getxattr

3 views
Skip to first unread message

syzbot

unread,
May 18, 2024, 12:28:33 AMMay 18
to ch...@kernel.org, jae...@kernel.org, linux-f2...@lists.sourceforge.net, linux-...@vger.kernel.org, syzkall...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: a5131c3fdf26 Merge tag 'x86-shstk-2024-05-13' of git://git..
git tree: upstream
console output: https://syzkaller.appspot.com/x/log.txt?x=12cee100980000
kernel config: https://syzkaller.appspot.com/x/.config?x=e4f7e6f2d15a8e15
dashboard link: https://syzkaller.appspot.com/bug?extid=8f9e913ccc308e66c407
compiler: Debian clang version 15.0.6, GNU ld (GNU Binutils for Debian) 2.40

Unfortunately, I don't have any reproducer for this issue yet.

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/a81f43baa3cd/disk-a5131c3f.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/46b648092f89/vmlinux-a5131c3f.xz
kernel image: https://storage.googleapis.com/syzbot-assets/e6e6c1a3a7e3/bzImage-a5131c3f.xz

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+8f9e91...@syzkaller.appspotmail.com

F2FS-fs (loop2): Try to recover 1th superblock, ret: 0
F2FS-fs (loop2): Mounted with checkpoint version = 48b305e5
------------[ cut here ]------------
Looking for class "c->lock" with key init_kmem_cache_cpus.__key, but found a different class "&c->lock" with the same key
WARNING: CPU: 0 PID: 5944 at kernel/locking/lockdep.c:935 look_up_lock_class+0xdc/0x160 kernel/locking/lockdep.c:932
Modules linked in:
CPU: 0 PID: 5944 Comm: syz-executor.2 Not tainted 6.9.0-syzkaller-01768-ga5131c3fdf26 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 04/02/2024
RIP: 0010:look_up_lock_class+0xdc/0x160 kernel/locking/lockdep.c:932
Code: 01 0f 85 80 00 00 00 c6 05 1d 21 13 04 01 90 49 8b 16 49 8b 76 18 48 8b 8b b8 00 00 00 48 c7 c7 80 dd ca 8b e8 95 d8 d7 f5 90 <0f> 0b 90 90 eb 57 90 e8 78 23 2b f9 48 c7 c7 c0 dc ca 8b 89 de e8
RSP: 0018:ffffc9000455ee70 EFLAGS: 00010046
RAX: cedb96dd9fdb9000 RBX: ffffffff92c296e0 RCX: 0000000000040000
RDX: ffffc9000a9a0000 RSI: 000000000000ef17 RDI: 000000000000ef18
RBP: ffffc9000455ef80 R08: ffffffff81589ca2 R09: fffffbfff1c39d38
R10: dffffc0000000000 R11: fffffbfff1c39d38 R12: ffffe8ffffc76260
R13: ffffe8ffffc76260 R14: ffffe8ffffc76260 R15: ffffffff94791b10
FS: 00007f130db086c0(0000) GS:ffff8880b9400000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f130ce7ddf0 CR3: 000000023177c000 CR4: 0000000000350ef0
Call Trace:
<TASK>
register_lock_class+0x102/0x980 kernel/locking/lockdep.c:1284
__lock_acquire+0xda/0x1fd0 kernel/locking/lockdep.c:5014
lock_acquire+0x1ed/0x550 kernel/locking/lockdep.c:5754
local_lock_acquire+0x20/0x80 include/linux/local_lock_internal.h:29
___slab_alloc+0x1004/0x12e0 mm/slub.c:3641
__slab_alloc mm/slub.c:3682 [inline]
__slab_alloc_node mm/slub.c:3735 [inline]
slab_alloc_node mm/slub.c:3908 [inline]
kmem_cache_alloc+0x252/0x350 mm/slub.c:3925
f2fs_kmem_cache_alloc fs/f2fs/f2fs.h:2832 [inline]
xattr_alloc fs/f2fs/xattr.c:30 [inline]
lookup_all_xattrs fs/f2fs/xattr.c:333 [inline]
f2fs_getxattr+0x477/0x13b0 fs/f2fs/xattr.c:533
vfs_getxattr_alloc+0x474/0x5c0 fs/xattr.c:393
ima_read_xattr+0x38/0x60 security/integrity/ima/ima_appraise.c:229
process_measurement+0x11d5/0x1f60 security/integrity/ima/ima_main.c:340
ima_file_check+0xf2/0x170 security/integrity/ima/ima_main.c:559
security_file_post_open+0x6f/0xa0 security/security.c:2981
do_open fs/namei.c:3652 [inline]
path_openat+0x28b7/0x3240 fs/namei.c:3807
do_filp_open+0x235/0x490 fs/namei.c:3834
do_sys_openat2+0x13e/0x1d0 fs/open.c:1406
do_sys_open fs/open.c:1421 [inline]
__do_sys_openat fs/open.c:1437 [inline]
__se_sys_openat fs/open.c:1432 [inline]
__x64_sys_openat+0x247/0x2a0 fs/open.c:1432
do_syscall_x64 arch/x86/entry/common.c:52 [inline]
do_syscall_64+0xf5/0x240 arch/x86/entry/common.c:83
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f130ce7dd69
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 e1 20 00 00 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f130db080c8 EFLAGS: 00000246 ORIG_RAX: 0000000000000101
RAX: ffffffffffffffda RBX: 00007f130cfabf80 RCX: 00007f130ce7dd69
RDX: 000000000000275a RSI: 0000000020000040 RDI: ffffffffffffff9c
RBP: 00007f130ceca49e R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 000000000000000b R14: 00007f130cfabf80 R15: 00007ffe63d5a628
</TASK>


---
This report is generated by a bot. It may contain errors.
See https://goo.gl/tpsmEJ for more information about syzbot.
syzbot engineers can be reached at syzk...@googlegroups.com.

syzbot will keep track of this issue. See:
https://goo.gl/tpsmEJ#status for how to communicate with syzbot.

If the report is already addressed, let syzbot know by replying with:
#syz fix: exact-commit-title

If you want to overwrite report's subsystems, reply with:
#syz set subsystems: new-subsystem
(See the list of subsystem names on the web dashboard)

If the report is a duplicate of another one, reply with:
#syz dup: exact-subject-of-another-report

If you want to undo deduplication, reply with:
#syz undup
Reply all
Reply to author
Forward
0 new messages