Warning: Permanently added '10.128.1.26' (ECDSA) to the list of known hosts. executing program syzkaller login: [ 52.388717][ T3498] loop0: detected capacity change from 0 to 8192 [ 52.398899][ T3498] REISERFS (device loop0): found reiserfs format "3.5" with non-standard journal [ 52.408608][ T3498] REISERFS (device loop0): using ordered data mode [ 52.415290][ T3498] reiserfs: using flush barriers [ 52.421348][ T3498] REISERFS (device loop0): journal params: device loop0, size 512, journal first block 18, max trans len 256, max batch 225, max commit age 30, max trans age 30 [ 52.438188][ T3498] REISERFS (device loop0): checking transaction log (loop0) [ 52.495316][ T3498] REISERFS (device loop0): Using r5 hash to sort names [ 52.502628][ T3498] REISERFS (device loop0): using 3.5.x disk format [ 52.510180][ T3498] REISERFS (device loop0): Created .reiserfs_priv - reserved for xattr storage. [ 52.525054][ T3498] [ 52.527406][ T3498] ====================================================== [ 52.534425][ T3498] WARNING: possible circular locking dependency detected [ 52.541443][ T3498] 5.15.113-syzkaller #0 Not tainted [ 52.546676][ T3498] ------------------------------------------------------ [ 52.553704][ T3498] syz-executor151/3498 is trying to acquire lock: [ 52.560103][ T3498] ffff888015982460 (sb_writers#9){.+.+}-{0:0}, at: mnt_want_write_file+0x5a/0x1f0 [ 52.569334][ T3498] [ 52.569334][ T3498] but task is already holding lock: [ 52.576685][ T3498] ffff888146c20090 (&sbi->lock){+.+.}-{3:3}, at: reiserfs_write_lock+0x76/0xd0 [ 52.585632][ T3498] [ 52.585632][ T3498] which lock already depends on the new lock. [ 52.585632][ T3498] [ 52.596010][ T3498] [ 52.596010][ T3498] the existing dependency chain (in reverse order) is: [ 52.605002][ T3498] [ 52.605002][ T3498] -> #2 (&sbi->lock){+.+.}-{3:3}: [ 52.612338][ T3498] lock_acquire+0x1db/0x4f0 [ 52.617378][ T3498] __mutex_lock_common+0x1da/0x25a0 [ 52.623094][ T3498] mutex_lock_nested+0x17/0x20 [ 52.628373][ T3498] reiserfs_write_lock+0x76/0xd0 [ 52.633828][ T3498] reiserfs_lookup+0x15c/0x4b0 [ 52.639104][ T3498] __lookup_slow+0x275/0x3d0 [ 52.644200][ T3498] lookup_one_len+0x187/0x2d0 [ 52.649385][ T3498] reiserfs_lookup_privroot+0x85/0x1e0 [ 52.655375][ T3498] reiserfs_fill_super+0x2224/0x2690 [ 52.661182][ T3498] mount_bdev+0x26d/0x3a0 [ 52.666019][ T3498] legacy_get_tree+0xeb/0x180 [ 52.671205][ T3498] vfs_get_tree+0x88/0x270 [ 52.676127][ T3498] do_new_mount+0x28b/0xad0 [ 52.681138][ T3498] __se_sys_mount+0x2d5/0x3c0 [ 52.686327][ T3498] do_syscall_64+0x3d/0xb0 [ 52.691252][ T3498] entry_SYSCALL_64_after_hwframe+0x61/0xcb [ 52.697649][ T3498] [ 52.697649][ T3498] -> #1 (&type->i_mutex_dir_key#6){+.+.}-{3:3}: [ 52.706062][ T3498] lock_acquire+0x1db/0x4f0 [ 52.711088][ T3498] down_write+0x97/0x170 [ 52.715838][ T3498] path_openat+0x824/0x2f20 [ 52.720942][ T3498] do_filp_open+0x21c/0x460 [ 52.725973][ T3498] do_sys_openat2+0x13b/0x500 [ 52.731167][ T3498] __x64_sys_openat+0x243/0x290 [ 52.736620][ T3498] do_syscall_64+0x3d/0xb0 [ 52.741560][ T3498] entry_SYSCALL_64_after_hwframe+0x61/0xcb [ 52.747976][ T3498] [ 52.747976][ T3498] -> #0 (sb_writers#9){.+.+}-{0:0}: [ 52.755353][ T3498] validate_chain+0x1646/0x58b0 [ 52.760713][ T3498] __lock_acquire+0x1295/0x1ff0 [ 52.766075][ T3498] lock_acquire+0x1db/0x4f0 [ 52.771104][ T3498] sb_start_write+0x4f/0x1c0 [ 52.776200][ T3498] mnt_want_write_file+0x5a/0x1f0 [ 52.781731][ T3498] reiserfs_ioctl+0x170/0x340 [ 52.786912][ T3498] __se_sys_ioctl+0xf1/0x160 [ 52.792009][ T3498] do_syscall_64+0x3d/0xb0 [ 52.796952][ T3498] entry_SYSCALL_64_after_hwframe+0x61/0xcb [ 52.803352][ T3498] [ 52.803352][ T3498] other info that might help us debug this: [ 52.803352][ T3498] [ 52.813659][ T3498] Chain exists of: [ 52.813659][ T3498] sb_writers#9 --> &type->i_mutex_dir_key#6 --> &sbi->lock [ 52.813659][ T3498] [ 52.826780][ T3498] Possible unsafe locking scenario: [ 52.826780][ T3498] [ 52.834244][ T3498] CPU0 CPU1 [ 52.839594][ T3498] ---- ---- [ 52.844949][ T3498] lock(&sbi->lock); [ 52.848916][ T3498] lock(&type->i_mutex_dir_key#6); [ 52.856632][ T3498] lock(&sbi->lock); [ 52.863116][ T3498] lock(sb_writers#9); [ 52.867264][ T3498] [ 52.867264][ T3498] *** DEADLOCK *** [ 52.867264][ T3498] [ 52.875385][ T3498] 1 lock held by syz-executor151/3498: [ 52.880822][ T3498] #0: ffff888146c20090 (&sbi->lock){+.+.}-{3:3}, at: reiserfs_write_lock+0x76/0xd0 [ 52.890300][ T3498] [ 52.890300][ T3498] stack backtrace: [ 52.896260][ T3498] CPU: 0 PID: 3498 Comm: syz-executor151 Not tainted 5.15.113-syzkaller #0 [ 52.905016][ T3498] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/25/2023 [ 52.915057][ T3498] Call Trace: [ 52.918325][ T3498] [ 52.921245][ T3498] dump_stack_lvl+0x1e3/0x2cb [ 52.925918][ T3498] ? io_uring_drop_tctx_refs+0x19d/0x19d [ 52.931542][ T3498] ? print_circular_bug+0x12b/0x1a0 [ 52.936747][ T3498] check_noncircular+0x2f8/0x3b0 [ 52.941672][ T3498] ? add_chain_block+0x850/0x850 [ 52.946597][ T3498] ? lockdep_lock+0x11f/0x2a0 [ 52.951261][ T3498] ? kasan_set_free_info+0x1f/0x40 [ 52.956361][ T3498] ? ____kasan_slab_free+0xd8/0x120 [ 52.961545][ T3498] ? slab_free_freelist_hook+0xdd/0x160 [ 52.967073][ T3498] ? kfree+0xf1/0x270 [ 52.971040][ T3498] ? tomoyo_path_number_perm+0x648/0x810 [ 52.976658][ T3498] ? reacquire_held_locks+0x660/0x660 [ 52.982015][ T3498] ? entry_SYSCALL_64_after_hwframe+0x61/0xcb [ 52.988070][ T3498] validate_chain+0x1646/0x58b0 [ 52.992915][ T3498] ? lockdep_hardirqs_on_prepare+0x438/0x7a0 [ 52.998884][ T3498] ? reacquire_held_locks+0x660/0x660 [ 53.004243][ T3498] ? __lock_acquire+0x1295/0x1ff0 [ 53.009265][ T3498] ? mark_lock+0x98/0x340 [ 53.013583][ T3498] __lock_acquire+0x1295/0x1ff0 [ 53.018426][ T3498] lock_acquire+0x1db/0x4f0 [ 53.022922][ T3498] ? mnt_want_write_file+0x5a/0x1f0 [ 53.028109][ T3498] ? read_lock_is_recursive+0x10/0x10 [ 53.033469][ T3498] ? __might_sleep+0xc0/0xc0 [ 53.038046][ T3498] ? mutex_lock_io_nested+0x60/0x60 [ 53.043235][ T3498] ? lockdep_hardirqs_on_prepare+0x438/0x7a0 [ 53.049203][ T3498] sb_start_write+0x4f/0x1c0 [ 53.053778][ T3498] ? mnt_want_write_file+0x5a/0x1f0 [ 53.059053][ T3498] mnt_want_write_file+0x5a/0x1f0 [ 53.064064][ T3498] reiserfs_ioctl+0x170/0x340 [ 53.068727][ T3498] ? __se_sys_ioctl+0xe6/0x160 [ 53.073475][ T3498] ? reiserfs_unpack+0x5a0/0x5a0 [ 53.078408][ T3498] __se_sys_ioctl+0xf1/0x160 [ 53.082989][ T3498] do_syscall_64+0x3d/0xb0 [ 53.087400][ T3498] entry_SYSCALL_64_after_hwframe+0x61/0xcb [ 53.093280][ T3498] RIP: 0033:0x7f5de24ee809 [ 53.097682][ T3498] Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 51 14 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 c0 ff ff ff f7 d8 64 89 01 48 [ 53.117273][ T3498] RSP: 002b:00007ffe2e5da438 EFLAGS: 00000246 ORIG_RAX: 0000000000000010 [ 53.125673][ T3498] RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007f5de24ee809 [ 53.133633][ T3498] RDX: 0000000000000000 RSI: 0000000040087602 RDI: 0000000000000005 [ 53.141589][ T3498] RBP: 00007f5de24ae0a0 R08: 0000000000000000 R09: 0000000