REISERFS (device loop2): Created .reiserfs_priv - reserved for xattr storage. ====================================================== WARNING: possible circular locking dependency detected 5.15.189-syzkaller #0 Not tainted ------------------------------------------------------ syz.2.19/4417 is trying to acquire lock: ffff88805d5bd090 (&sbi->lock){+.+.}-{3:3}, at: reiserfs_write_lock+0x75/0xd0 fs/reiserfs/lock.c:27 but task is already holding lock: ffff888025482558 (sb_pagefaults#2){.+.+}-{0:0}, at: do_page_mkwrite+0x168/0x3c0 mm/memory.c:2922 which lock already depends on the new lock. the existing dependency chain (in reverse order) is: -> #2 (sb_pagefaults#2){.+.+}-{0:0}: percpu_down_read include/linux/percpu-rwsem.h:51 [inline] __sb_start_write include/linux/fs.h:1811 [inline] sb_start_pagefault include/linux/fs.h:1910 [inline] filemap_page_mkwrite+0x120/0x660 mm/filemap.c:3367 do_page_mkwrite+0x168/0x3c0 mm/memory.c:2922 do_shared_fault mm/memory.c:4328 [inline] do_fault mm/memory.c:4396 [inline] handle_pte_fault mm/memory.c:4650 [inline] __handle_mm_fault mm/memory.c:4785 [inline] handle_mm_fault+0x1d4b/0x43c0 mm/memory.c:4883 do_user_addr_fault+0x489/0xc80 arch/x86/mm/fault.c:1357 handle_page_fault arch/x86/mm/fault.c:1445 [inline] exc_page_fault+0x60/0x100 arch/x86/mm/fault.c:1501 asm_exc_page_fault+0x22/0x30 arch/x86/include/asm/idtentry.h:606 -> #1 (&mm->mmap_lock){++++}-{3:3}: __might_fault+0xb3/0x110 mm/memory.c:5357 reiserfs_ioctl+0x13b/0x330 fs/reiserfs/ioctl.c:96 vfs_ioctl fs/ioctl.c:51 [inline] __do_sys_ioctl fs/ioctl.c:874 [inline] __se_sys_ioctl+0xfa/0x170 fs/ioctl.c:860 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x66/0xd0 -> #0 (&sbi->lock){+.+.}-{3:3}: check_prev_add kernel/locking/lockdep.c:3053 [inline] check_prevs_add kernel/locking/lockdep.c:3172 [inline] validate_chain kernel/locking/lockdep.c:3788 [inline] __lock_acquire+0x2c33/0x7c60 kernel/locking/lockdep.c:5012 lock_acquire+0x197/0x3f0 kernel/locking/lockdep.c:5623 __mutex_lock_common+0x1eb/0x2390 kernel/locking/mutex.c:596 __mutex_lock kernel/locking/mutex.c:729 [inline] mutex_lock_nested+0x17/0x20 kernel/locking/mutex.c:743 reiserfs_write_lock+0x75/0xd0 fs/reiserfs/lock.c:27 reiserfs_dirty_inode+0xf0/0x240 fs/reiserfs/super.c:704 __mark_inode_dirty+0x2b0/0xc60 fs/fs-writeback.c:2464 generic_update_time+0x1cd/0x1f0 fs/inode.c:1881 inode_update_time fs/inode.c:1894 [inline] file_update_time+0x38b/0x400 fs/inode.c:2083 filemap_page_mkwrite+0x242/0x660 mm/filemap.c:3368 do_page_mkwrite+0x168/0x3c0 mm/memory.c:2922 do_shared_fault mm/memory.c:4328 [inline] do_fault mm/memory.c:4396 [inline] handle_pte_fault mm/memory.c:4650 [inline] __handle_mm_fault mm/memory.c:4785 [inline] handle_mm_fault+0x1d4b/0x43c0 mm/memory.c:4883 do_user_addr_fault+0x489/0xc80 arch/x86/mm/fault.c:1357 handle_page_fault arch/x86/mm/fault.c:1445 [inline] exc_page_fault+0x60/0x100 arch/x86/mm/fault.c:1501 asm_exc_page_fault+0x22/0x30 arch/x86/include/asm/idtentry.h:606 other info that might help us debug this: Chain exists of: &sbi->lock --> &mm->mmap_lock --> sb_pagefaults#2 Possible unsafe locking scenario: CPU0 CPU1 ---- ---- lock(sb_pagefaults#2); lock(&mm->mmap_lock); lock(sb_pagefaults#2); lock(&sbi->lock); *** DEADLOCK *** 2 locks held by syz.2.19/4417: #0: ffff88807b712428 (&mm->mmap_lock ){++++}-{3:3}, at: mmap_read_lock+0x1c/0x50 include/linux/mmap_lock.h:117 #1: ffff888025482558 (sb_pagefaults#2){.+.+}-{0:0} , at: do_page_mkwrite+0x168/0x3c0 mm/memory.c:2922 stack backtrace: CPU: 1 PID: 4417 Comm: syz.2.19 Not tainted 5.15.189-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/12/2025 Call Trace: dump_stack_lvl+0x168/0x230 lib/dump_stack.c:106 check_noncircular+0x274/0x310 kernel/locking/lockdep.c:2133 check_prev_add kernel/locking/lockdep.c:3053 [inline] check_prevs_add kernel/locking/lockdep.c:3172 [inline] validate_chain kernel/locking/lockdep.c:3788 [inline] __lock_acquire+0x2c33/0x7c60 kernel/locking/lockdep.c:5012 lock_acquire+0x197/0x3f0 kernel/locking/lockdep.c:5623 __mutex_lock_common+0x1eb/0x2390 kernel/locking/mutex.c:596 __mutex_lock kernel/locking/mutex.c:729 [inline] mutex_lock_nested+0x17/0x20 kernel/locking/mutex.c:743 reiserfs_write_lock+0x75/0xd0 fs/reiserfs/lock.c:27 reiserfs_dirty_inode+0xf0/0x240 fs/reiserfs/super.c:704 __mark_inode_dirty+0x2b0/0xc60 fs/fs-writeback.c:2464 generic_update_time+0x1cd/0x1f0 fs/inode.c:1881 inode_update_time fs/inode.c:1894 [inline] file_update_time+0x38b/0x400 fs/inode.c:2083 filemap_page_mkwrite+0x242/0x660 mm/filemap.c:3368 do_page_mkwrite+0x168/0x3c0 mm/memory.c:2922 do_shared_fault mm/memory.c:4328 [inline] do_fault mm/memory.c:4396 [inline] handle_pte_fault mm/memory.c:4650 [inline] __handle_mm_fault mm/memory.c:4785 [inline] handle_mm_fault+0x1d4b/0x43c0 mm/memory.c:4883 do_user_addr_fault+0x489/0xc80 arch/x86/mm/fault.c:1357 handle_page_fault arch/x86/mm/fault.c:1445 [inline] exc_page_fault+0x60/0x100 arch/x86/mm/fault.c:1501 asm_exc_page_fault+0x22/0x30 arch/x86/include/asm/idtentry.h:606 RIP: 0033:0x7fb6e42b292b Code: fa 10 73 2d 83 fa 08 73 46 83 fa 04 73 16 83 fa 01 7c 10 8a 0e 74 0a 0f b7 74 16 fe 66 89 74 17 fe 88 0f c3 8b 4c 16 fc 8b 36 <89> 4c 17 fc 89 37 c3 c5 fa 6f 06 c5 fa 6f 4c 16 f0 c5 fa 7f 07 c5 RSP: 002b:00007ffc5b6cbe58 EFLAGS: 00010202 RAX: 0000200000000400 RBX: 0000000000000004 RCX: 0000000000737562 RDX: 0000000000000006 RSI: 0000000075622f2e RDI: 0000200000000400 RBP: 0000000000000000 R08: 0000001b31720000 R09: 0000000000000001 R10: 0000000000000001 R11: 0000000000000009 R12: 00007fb6e4511fac R13: 00007fb6e4511fa0 R14: fffffffffffffffe R15: 0000000000000006