./strace-static-x86_64 -e \!wait4,clock_nanosleep,nanosleep -s 100 -x -f ./syz-executor722927442 <...> Warning: Permanently added '10.128.0.93' (ECDSA) to the list of known hosts. execve("./syz-executor722927442", ["./syz-executor722927442"], 0x7ffc62427590 /* 10 vars */) = 0 brk(NULL) = 0x555556021000 brk(0x555556021c40) = 0x555556021c40 arch_prctl(ARCH_SET_FS, 0x555556021300) = 0 uname({sysname="Linux", nodename="syzkaller", ...}) = 0 readlink("/proc/self/exe", "/root/syz-executor722927442", 4096) = 27 brk(0x555556042c40) = 0x555556042c40 brk(0x555556043000) = 0x555556043000 mprotect(0x7f4e22f0f000, 16384, PROT_READ) = 0 mmap(0x1ffff000, 4096, PROT_NONE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x1ffff000 mmap(0x20000000, 16777216, PROT_READ|PROT_WRITE|PROT_EXEC, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x20000000 mmap(0x21000000, 4096, PROT_NONE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x21000000 memfd_create("syzkaller", 0) = 3 mmap(NULL, 138412032, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f4e1aa56000 write(3, "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00"..., 524288) = 524288 munmap(0x7f4e1aa56000, 524288) = 0 openat(AT_FDCWD, "/dev/loop0", O_RDWR) = 4 ioctl(4, LOOP_SET_FD, 3) = 0 close(3) = 0 mkdir("./bus", 0777) = 0 mount("/dev/loop0", "./bus", "hfsplus", MS_SYNCHRONOUS|MS_NOATIME|MS_POSIXACL, "") = 0 openat(AT_FDCWD, "./bus", O_RDONLY|O_DIRECTORY) = 3 chdir("./bus") = 0 ioctl(4, LOOP_CLR_FD) = 0 close(4) = 0 openat(AT_FDCWD, "./bus", O_RDWR|O_CREAT|O_NONBLOCK|O_SYNC|O_NOATIME, 000) = 4 [ 65.992298][ T4997] memfd_create() without MFD_EXEC nor MFD_NOEXEC_SEAL, pid=4997 'syz-executor722' [ 66.013543][ T4997] loop0: detected capacity change from 0 to 1024 [ 66.043056][ T4997] [ 66.045435][ T4997] ============================================ [ 66.051605][ T4997] WARNING: possible recursive locking detected [ 66.057765][ T4997] 6.4.0-rc4-syzkaller-00268-g51f269a6ecc7 #0 Not tainted [ 66.064798][ T4997] -------------------------------------------- [ 66.070971][ T4997] syz-executor722/4997 is trying to acquire lock: [ 66.077392][ T4997] ffff888076ab80b0 (&tree->tree_lock/1){+.+.}-{3:3}, at: hfsplus_find_init+0x14a/0x1c0 [ 66.087072][ T4997] [ 66.087072][ T4997] but task is already holding lock: [ 66.094430][ T4997] ffff888076ab80b0 (&tree->tree_lock/1){+.+.}-{3:3}, at: hfsplus_find_init+0x14a/0x1c0 [ 66.104087][ T4997] [ 66.104087][ T4997] other info that might help us debug this: [ 66.112134][ T4997] Possible unsafe locking scenario: [ 66.112134][ T4997] [ 66.119570][ T4997] CPU0 [ 66.122839][ T4997] ---- [ 66.126111][ T4997] lock(&tree->tree_lock/1); [ 66.130788][ T4997] lock(&tree->tree_lock/1); [ 66.135468][ T4997] [ 66.135468][ T4997] *** DEADLOCK *** [ 66.135468][ T4997] [ 66.143601][ T4997] May be due to missing lock nesting notation [ 66.143601][ T4997] [ 66.151905][ T4997] 5 locks held by syz-executor722/4997: [ 66.157436][ T4997] #0: ffff88807e236460 (sb_writers#9){.+.+}-{0:0}, at: vfs_write+0x223/0xb20 [ 66.166322][ T4997] #1: ffff888076a924c0 (&sb->s_type->i_mutex_key#14){+.+.}-{3:3}, at: generic_file_write_iter+0x83/0x310 [ 66.177629][ T4997] #2: ffff888076a922c8 (&hip->extents_lock){+.+.}-{3:3}, at: hfsplus_file_extend+0x1d6/0x1b10 [ 66.187989][ T4997] #3: ffff888076ab80b0 (&tree->tree_lock/1){+.+.}-{3:3}, at: hfsplus_find_init+0x14a/0x1c0 [ 66.198095][ T4997] #4: ffff888076a90108 (&HFSPLUS_I(inode)->extents_lock){+.+.}-{3:3}, at: hfsplus_file_extend+0x1d6/0x1b10 [ 66.209575][ T4997] [ 66.209575][ T4997] stack backtrace: [ 66.215450][ T4997] CPU: 0 PID: 4997 Comm: syz-executor722 Not tainted 6.4.0-rc4-syzkaller-00268-g51f269a6ecc7 #0 [ 66.225848][ T4997] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/25/2023 [ 66.235900][ T4997] Call Trace: [ 66.239168][ T4997] [ 66.242089][ T4997] dump_stack_lvl+0x1e7/0x2d0 [ 66.246784][ T4997] ? nf_tcp_handle_invalid+0x650/0x650 [ 66.252247][ T4997] ? panic+0x770/0x770 [ 66.256314][ T4997] validate_chain+0x473a/0x58f0 [ 66.261172][ T4997] ? reacquire_held_locks+0x660/0x660 [ 66.266552][ T4997] ? mark_lock+0x9a/0x340 [ 66.270882][ T4997] ? lockdep_hardirqs_on_prepare+0x43c/0x7a0 [ 66.276861][ T4997] ? mark_lock+0x9a/0x340 [ 66.281192][ T4997] __lock_acquire+0x1316/0x2070 [ 66.286048][ T4997] lock_acquire+0x1e3/0x520 [ 66.290548][ T4997] ? hfsplus_find_init+0x14a/0x1c0 [ 66.295662][ T4997] ? read_lock_is_recursive+0x20/0x20 [ 66.301031][ T4997] ? hfsplus_bmap_reserve+0x105/0x4e0 [ 66.306398][ T4997] ? __hfsplus_ext_write_extent+0x2a4/0x5b0 [ 66.312285][ T4997] ? __might_sleep+0xc0/0xc0 [ 66.316874][ T4997] ? block_write_begin+0x9c/0x1f0 [ 66.321899][ T4997] ? cont_write_begin+0x643/0x880 [ 66.326920][ T4997] ? hfsplus_write_begin+0x8a/0xd0 [ 66.332032][ T4997] ? generic_perform_write+0x300/0x5e0 [ 66.337483][ T4997] ? __generic_file_write_iter+0x17a/0x400 [ 66.343281][ T4997] ? generic_file_write_iter+0xaf/0x310 [ 66.348835][ T4997] ? vfs_write+0x790/0xb20 [ 66.353248][ T4997] ? ksys_write+0x1a0/0x2c0 [ 66.357742][ T4997] ? do_syscall_64+0x41/0xc0 [ 66.362331][ T4997] __mutex_lock_common+0x1d8/0x2530 [ 66.367547][ T4997] ? hfsplus_find_init+0x14a/0x1c0 [ 66.372658][ T4997] ? hfsplus_find_init+0x14a/0x1c0 [ 66.377765][ T4997] ? mutex_lock_io_nested+0x60/0x60 [ 66.382965][ T4997] ? hfsplus_find_init+0x85/0x1c0 [ 66.387984][ T4997] ? rcu_is_watching+0x15/0xb0 [ 66.392741][ T4997] ? hfsplus_find_init+0x85/0x1c0 [ 66.397762][ T4997] ? __kmalloc+0xe6/0x230 [ 66.402088][ T4997] mutex_lock_nested+0x1b/0x20 [ 66.406852][ T4997] hfsplus_find_init+0x14a/0x1c0 [ 66.411789][ T4997] hfsplus_file_extend+0x40e/0x1b10 [ 66.416983][ T4997] ? hfsplus_get_block+0x14e0/0x14e0 [ 66.422262][ T4997] ? __mutex_trylock_common+0x182/0x2e0 [ 66.427825][ T4997] ? __might_sleep+0xc0/0xc0 [ 66.432432][ T4997] ? trace_raw_output_contention_end+0xd0/0xd0 [ 66.438590][ T4997] ? rcu_is_watching+0x15/0xb0 [ 66.443349][ T4997] ? trace_contention_end+0x3c/0xf0 [ 66.448539][ T4997] ? hfsplus_brec_find+0x19d/0x570 [ 66.453653][ T4997] hfsplus_bmap_reserve+0x105/0x4e0 [ 66.458847][ T4997] __hfsplus_ext_write_extent+0x2a4/0x5b0 [ 66.464561][ T4997] __hfsplus_ext_cache_extent+0x84/0xe00 [ 66.470183][ T4997] ? mutex_lock_nested+0x1b/0x20 [ 66.475122][ T4997] hfsplus_file_extend+0x439/0x1b10 [ 66.480329][ T4997] ? xas_find+0x37c/0xaa0 [ 66.484663][ T4997] ? hfsplus_get_block+0x14e0/0x14e0 [ 66.489940][ T4997] ? find_lock_entries+0x10f0/0x10f0 [ 66.495224][ T4997] ? clean_bdev_aliases+0x7f9/0x920 [ 66.500413][ T4997] hfsplus_get_block+0x406/0x14e0 [ 66.505436][ T4997] ? hfsplus_ext_write_extent+0x1f0/0x1f0 [ 66.511150][ T4997] ? _raw_spin_unlock+0x28/0x40 [ 66.515993][ T4997] ? folio_create_buffers+0x132/0x250 [ 66.521354][ T4997] __block_write_begin_int+0x548/0x1a50 [ 66.526891][ T4997] ? folio_add_lru+0x353/0x6f0 [ 66.531652][ T4997] ? hfsplus_ext_write_extent+0x1f0/0x1f0 [ 66.537363][ T4997] ? PageUptodate+0x290/0x290 [ 66.542032][ T4997] ? folio_test_hugetlb+0xa0/0x1d0 [ 66.547149][ T4997] ? pagecache_get_page+0xeb/0x220 [ 66.552250][ T4997] ? hfsplus_ext_write_extent+0x1f0/0x1f0 [ 66.557960][ T4997] block_write_begin+0x9c/0x1f0 [ 66.562802][ T4997] ? cont_write_begin+0x626/0x880 [ 66.567837][ T4997] cont_write_begin+0x643/0x880 [ 66.572684][ T4997] ? fault_in_readable+0x165/0x2b0 [ 66.577791][ T4997] ? generic_cont_expand_simple+0x2a0/0x2a0 [ 66.583679][ T4997] ? fault_in_readable+0x1a6/0x2b0 [ 66.588792][ T4997] ? fault_in_safe_writeable+0x260/0x260 [ 66.594450][ T4997] hfsplus_write_begin+0x8a/0xd0 [ 66.599390][ T4997] ? hfsplus_ext_write_extent+0x1f0/0x1f0 [ 66.605103][ T4997] generic_perform_write+0x300/0x5e0 [ 66.610388][ T4997] ? generic_file_direct_write+0x460/0x460 [ 66.616191][ T4997] ? __file_remove_privs+0x640/0x640 [ 66.621472][ T4997] ? generic_write_checks+0x160/0x1c0 [ 66.626844][ T4997] __generic_file_write_iter+0x17a/0x400 [ 66.632475][ T4997] generic_file_write_iter+0xaf/0x310 [ 66.637851][ T4997] vfs_write+0x790/0xb20 [ 66.642095][ T4997] ? file_end_write+0x250/0x250 [ 66.646952][ T4997] ? lockdep_hardirqs_on+0x98/0x140 [ 66.652145][ T4997] ? __fdget_pos+0x265/0x2f0 [ 66.656726][ T4997] ksys_write+0x1a0/0x2c0 [ 66.661056][ T4997] ? __ia32_sys_read+0x90/0x90 [ 66.665818][ T4997] ? syscall_enter_from_user_mode+0x32/0x230 [ 66.671794][ T4997] ? syscall_enter_from_user_mode+0x8c/0x230 [ 66.677772][ T4997] do_syscall_64+0x41/0xc0 [ 66.682187][ T4997] entry_SYSCALL_64_after_hwframe+0x63/0xcd [ 66.688074][ T4997] RIP: 0033:0x7f4e22ea27d9 [ 66.692486][ T4997] 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 [ 66.712105][ T4997] RSP: 002b:00007fffd2f08ec8 EFLAGS: 00000246 ORIG_RAX: 0000000000000001 [ 66.720511][ T4997] RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007f4e22ea27d9 [ 66.728473][ T4997] RDX: 00000000fffffff0 RSI: 0000000020004200 RDI: 0000000000000004 [ 66.736448][ T4997] RBP: 00007f4e22e62070 R08: 0000000000000000 R09: 0000000000000000 [ 66.744411][ T4997] R10: 0000000000000647 R11: 0000000000000246 R12: 00007f4e22e62100 [ 66.752374][ T4997] R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000 [ 66.760341][ T4997]