./strace-static-x86_64 -e \!wait4,clock_nanosleep,nanosleep -s 100 -x -f ./syz-executor1609323678 <...> Warning: Permanently added '10.128.0.183' (ED25519) to the list of known hosts. execve("./syz-executor1609323678", ["./syz-executor1609323678"], 0x7ffd76c5e860 /* 10 vars */) = 0 brk(NULL) = 0x55555a5f0000 brk(0x55555a5f0d00) = 0x55555a5f0d00 arch_prctl(ARCH_SET_FS, 0x55555a5f0380) = 0 set_tid_address(0x55555a5f0650) = 5094 set_robust_list(0x55555a5f0660, 24) = 0 rseq(0x55555a5f0ca0, 0x20, 0, 0x53053053) = 0 prlimit64(0, RLIMIT_STACK, NULL, {rlim_cur=8192*1024, rlim_max=RLIM64_INFINITY}) = 0 readlink("/proc/self/exe", "/root/syz-executor1609323678", 4096) = 28 getrandom("\xe7\x6e\xd1\x37\xe3\xe0\xec\x42", 8, GRND_NONBLOCK) = 8 brk(NULL) = 0x55555a5f0d00 brk(0x55555a611d00) = 0x55555a611d00 brk(0x55555a612000) = 0x55555a612000 mprotect(0x7fed6ca83000, 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) = 0x7fed64400000 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(0x7fed64400000, 138412032) = 0 openat(AT_FDCWD, "/dev/loop0", O_RDWR) = 4 ioctl(4, LOOP_SET_FD, 3) = 0 close(3) = 0 close(4) = 0 mkdir("./file1", 0777) = 0 mount("/dev/loop0", "./file1", "hfsplus", MS_NOATIME, "") = 0 openat(AT_FDCWD, "./file1", O_RDONLY|O_DIRECTORY) = 3 chdir("./file1") = 0 openat(AT_FDCWD, "/dev/loop0", O_RDWR) = -1 EBUSY (Device or resource busy) [ 72.767905][ T5094] loop0: detected capacity change from 0 to 1024 [ 72.827531][ T5094] [ 72.829899][ T5094] ============================================ [ 72.836042][ T5094] WARNING: possible recursive locking detected [ 72.842196][ T5094] 6.9.0-next-20240516-syzkaller #0 Not tainted [ 72.848373][ T5094] -------------------------------------------- [ 72.854527][ T5094] syz-executor160/5094 is trying to acquire lock: [ 72.860946][ T5094] ffff88807f861548 (&HFSPLUS_I(inode)->extents_lock){+.+.}-{3:3}, at: hfsplus_get_block+0x383/0x14f0 [ 72.871861][ T5094] [ 72.871861][ T5094] but task is already holding lock: [ 72.879240][ T5094] ffff88807f862988 (&HFSPLUS_I(inode)->extents_lock){+.+.}-{3:3}, at: hfsplus_file_truncate+0x2da/0xb50 [ 72.890576][ T5094] [ 72.890576][ T5094] other info that might help us debug this: [ 72.898638][ T5094] Possible unsafe locking scenario: [ 72.898638][ T5094] [ 72.906088][ T5094] CPU0 [ 72.909371][ T5094] ---- [ 72.912650][ T5094] lock(&HFSPLUS_I(inode)->extents_lock); [ 72.918465][ T5094] lock(&HFSPLUS_I(inode)->extents_lock); [ 72.924278][ T5094] [ 72.924278][ T5094] *** DEADLOCK *** [ 72.924278][ T5094] [ 72.932424][ T5094] May be due to missing lock nesting notation [ 72.932424][ T5094] [ 72.940745][ T5094] 4 locks held by syz-executor160/5094: [ 72.946288][ T5094] #0: ffff88807b8d8420 (sb_writers#9){.+.+}-{0:0}, at: mnt_want_write+0x3f/0x90 [ 72.955448][ T5094] #1: ffff88807f862b80 (&sb->s_type->i_mutex_key#15){+.+.}-{3:3}, at: do_truncate+0x20c/0x310 [ 72.965835][ T5094] #2: ffff88807f862988 (&HFSPLUS_I(inode)->extents_lock){+.+.}-{3:3}, at: hfsplus_file_truncate+0x2da/0xb50 [ 72.977431][ T5094] #3: ffff88802a37f8f8 (&sbi->alloc_mutex){+.+.}-{3:3}, at: hfsplus_block_free+0xbb/0x4e0 [ 72.987463][ T5094] [ 72.987463][ T5094] stack backtrace: [ 72.993369][ T5094] CPU: 0 PID: 5094 Comm: syz-executor160 Not tainted 6.9.0-next-20240516-syzkaller #0 [ 73.002932][ T5094] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 04/02/2024 [ 73.013024][ T5094] Call Trace: [ 73.016310][ T5094] [ 73.019244][ T5094] dump_stack_lvl+0x241/0x360 [ 73.023946][ T5094] ? __pfx_dump_stack_lvl+0x10/0x10 [ 73.029196][ T5094] ? print_deadlock_bug+0x479/0x620 [ 73.034412][ T5094] ? _find_first_zero_bit+0xd4/0x100 [ 73.039724][ T5094] validate_chain+0x15c1/0x58e0 [ 73.044597][ T5094] ? __pfx_stack_trace_save+0x10/0x10 [ 73.049975][ T5094] ? check_noncircular+0x259/0x4a0 [ 73.055097][ T5094] ? __pfx_validate_chain+0x10/0x10 [ 73.060309][ T5094] ? __pfx_check_noncircular+0x10/0x10 [ 73.065783][ T5094] ? lockdep_unlock+0x16a/0x300 [ 73.070678][ T5094] ? __pfx_lockdep_unlock+0x10/0x10 [ 73.075886][ T5094] ? add_lock_to_list+0x1de/0x2e0 [ 73.080922][ T5094] ? look_up_lock_class+0x77/0x160 [ 73.086041][ T5094] ? register_lock_class+0x102/0x980 [ 73.091340][ T5094] ? validate_chain+0x15a2/0x58e0 [ 73.096396][ T5094] ? is_bpf_text_address+0x26/0x2a0 [ 73.101603][ T5094] ? __pfx_register_lock_class+0x10/0x10 [ 73.107246][ T5094] ? mark_lock+0x9a/0x350 [ 73.111592][ T5094] __lock_acquire+0x1346/0x1fd0 [ 73.116464][ T5094] lock_acquire+0x1ed/0x550 [ 73.120972][ T5094] ? hfsplus_get_block+0x383/0x14f0 [ 73.126185][ T5094] ? __pfx_lock_acquire+0x10/0x10 [ 73.131218][ T5094] ? __pfx___might_resched+0x10/0x10 [ 73.136513][ T5094] ? filemap_read_folio+0x1a0/0x790 [ 73.141724][ T5094] ? __pfx_register_lock_class+0x10/0x10 [ 73.147360][ T5094] ? hfsplus_free_extents+0x17a/0xae0 [ 73.152749][ T5094] ? hfsplus_setattr+0x1ce/0x280 [ 73.157706][ T5094] ? notify_change+0xb9d/0xe70 [ 73.162490][ T5094] __mutex_lock+0x136/0xd70 [ 73.167026][ T5094] ? hfsplus_get_block+0x383/0x14f0 [ 73.172323][ T5094] ? hfsplus_get_block+0x383/0x14f0 [ 73.177530][ T5094] ? __pfx___mutex_lock+0x10/0x10 [ 73.182572][ T5094] hfsplus_get_block+0x383/0x14f0 [ 73.187611][ T5094] ? __pfx_hfsplus_get_block+0x10/0x10 [ 73.193085][ T5094] ? _raw_spin_unlock+0x28/0x50 [ 73.197944][ T5094] ? create_empty_buffers+0x53e/0x740 [ 73.203328][ T5094] block_read_full_folio+0x42e/0xe10 [ 73.208626][ T5094] ? __pfx_hfsplus_get_block+0x10/0x10 [ 73.214097][ T5094] ? __pfx_block_read_full_folio+0x10/0x10 [ 73.219914][ T5094] ? __pfx_lru_add_fn+0x10/0x10 [ 73.224771][ T5094] ? folio_add_lru+0x357/0xd70 [ 73.229538][ T5094] ? folio_add_lru+0x58f/0xd70 [ 73.234306][ T5094] filemap_read_folio+0x1a0/0x790 [ 73.239361][ T5094] ? __pfx_hfsplus_read_folio+0x10/0x10 [ 73.244915][ T5094] ? __pfx_filemap_read_folio+0x10/0x10 [ 73.250469][ T5094] ? __filemap_get_folio+0x92d/0xbb0 [ 73.255759][ T5094] ? hfsplus_block_free+0xbb/0x4e0 [ 73.260879][ T5094] do_read_cache_folio+0x134/0x820 [ 73.266009][ T5094] ? __pfx_hfsplus_read_folio+0x10/0x10 [ 73.271568][ T5094] do_read_cache_page+0x30/0x200 [ 73.276514][ T5094] hfsplus_block_free+0x128/0x4e0 [ 73.281546][ T5094] ? hfsplus_find_init+0x85/0x1c0 [ 73.286577][ T5094] hfsplus_free_extents+0x17a/0xae0 [ 73.291789][ T5094] hfsplus_file_truncate+0x7d0/0xb50 [ 73.297094][ T5094] ? __pfx_hfsplus_file_truncate+0x10/0x10 [ 73.302916][ T5094] ? unmap_mapping_range+0xf8/0x290 [ 73.308142][ T5094] ? __pfx_unmap_mapping_range+0x10/0x10 [ 73.313787][ T5094] ? setattr_prepare+0x1f5/0xb20 [ 73.318745][ T5094] ? truncate_setsize+0xcf/0xf0 [ 73.323607][ T5094] hfsplus_setattr+0x1ce/0x280 [ 73.328381][ T5094] ? __pfx_hfsplus_setattr+0x10/0x10 [ 73.333762][ T5094] notify_change+0xb9d/0xe70 [ 73.338368][ T5094] do_truncate+0x220/0x310 [ 73.342819][ T5094] ? __pfx_do_truncate+0x10/0x10 [ 73.347803][ T5094] ? bpf_lsm_path_truncate+0x9/0x10 [ 73.353102][ T5094] vfs_truncate+0x2e1/0x3b0 [ 73.357619][ T5094] do_sys_truncate+0xde/0x190 [ 73.362370][ T5094] ? __pfx_do_sys_truncate+0x10/0x10 [ 73.367666][ T5094] ? do_syscall_64+0x102/0x240 [ 73.372448][ T5094] do_syscall_64+0xf5/0x240 [ 73.376963][ T5094] ? clear_bhb_loop+0x35/0x90 [ 73.381652][ T5094] entry_SYSCALL_64_after_hwframe+0x77/0x7f [ 73.387557][ T5094] RIP: 0033:0x7fed6ca105f9 [ 73.391981][ T5094] Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 61 17 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 b8 ff ff ff f7 d8 64 89 01 48 [ 73.411604][ T5094] RSP: 002b:00007fffdb32db48 EFLAGS: 00000246 ORIG_RAX: 000000000000004c [ 73.420029][ T5094] RAX: ffffffffffffffda RBX: 0031656c69662f2e RCX: 00007fed6ca105f9 [ 73.428011][ T5094] RDX: 00007fed6ca0f691 RSI: 0008000000000000 RDI: 0000000020000080 [ 73.435998][ T5094] RBP: 00007fed6ca83610 R08: 000000000000068d R09: 0000000000000000 [ 73.443974][ T5094] R10: 00007fffdb32da10 R11: 0000000000000246 R12: 0000000000000001 [ 73.451950][ T5094] R13: 00007fffdb32dd18 R14: 0000000000000001 R15: 0000000000000001 [ 73.459938][ T5094] [ 73.463239][ T5094] hfsplus: request for non-existent node 16777216 in B*Tree [ 73.471003][ T5094] hfsplus: request for non-existent node 16777216 in B*Tree truncate("./file1", 2251799813685248) = 0 exit_group(0) = ? +++ exited with 0 +++ [ 73.478555][ T5094]