./strace-static-x86_64 -e \!wait4,clock_nanosleep,nanosleep -s 100 -x -f ./syz-executor1983712380 <...> Warning: Permanently added '10.128.1.188' (ED25519) to the list of known hosts. execve("./syz-executor1983712380", ["./syz-executor1983712380"], 0x7ffce2785700 /* 10 vars */) = 0 brk(NULL) = 0x555556368000 brk(0x555556368d00) = 0x555556368d00 arch_prctl(ARCH_SET_FS, 0x555556368380) = 0 set_tid_address(0x555556368650) = 5037 set_robust_list(0x555556368660, 24) = 0 rseq(0x555556368ca0, 0x20, 0, 0x53053053) = 0 prlimit64(0, RLIMIT_STACK, NULL, {rlim_cur=8192*1024, rlim_max=RLIM64_INFINITY}) = 0 readlink("/proc/self/exe", "/root/syz-executor1983712380", 4096) = 28 getrandom("\x3c\x54\x13\x7f\x9e\x27\x94\x27", 8, GRND_NONBLOCK) = 8 brk(NULL) = 0x555556368d00 brk(0x555556389d00) = 0x555556389d00 brk(0x55555638a000) = 0x55555638a000 mprotect(0x7fb3e6dbd000, 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) = 0x7fb3de90d000 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(0x7fb3de90d000, 138412032) = 0 openat(AT_FDCWD, "/dev/loop0", O_RDWR) = 4 ioctl(4, LOOP_SET_FD, 3) = 0 close(3) = 0 mkdir("./file1", 0777) = 0 [ 74.902337][ T5037] syz-executor198[5037]: memfd_create() called without MFD_EXEC or MFD_NOEXEC_SEAL set [ 74.923761][ T5037] loop0: detected capacity change from 0 to 1024 [ 74.933876][ T5037] ======================================================= [ 74.933876][ T5037] WARNING: The mand mount option has been deprecated and mount("/dev/loop0", "./file1", "hfsplus", MS_SYNCHRONOUS|MS_MANDLOCK, "") = 0 openat(AT_FDCWD, "./file1", O_RDONLY|O_DIRECTORY) = 3 chdir("./file1") = 0 ioctl(4, LOOP_CLR_FD) = 0 close(4) = 0 [ 74.933876][ T5037] and is ignored by this kernel. Remove the mand [ 74.933876][ T5037] option from the mount to silence this warning. [ 74.933876][ T5037] ======================================================= [ 74.994114][ T5037] [ 74.996511][ T5037] ====================================================== [ 75.003560][ T5037] WARNING: possible circular locking dependency detected [ 75.010613][ T5037] 6.6.0-rc7-syzkaller-00018-gd88520ad73b7 #0 Not tainted [ 75.017655][ T5037] ------------------------------------------------------ [ 75.024700][ T5037] syz-executor198/5037 is trying to acquire lock: [ 75.031226][ T5037] ffff8880784d40b0 (&tree->tree_lock){+.+.}-{3:3}, at: hfsplus_file_truncate+0x811/0xb40 [ 75.041113][ T5037] [ 75.041113][ T5037] but task is already holding lock: [ 75.048513][ T5037] ffff88801fd707c8 (&HFSPLUS_I(inode)->extents_lock){+.+.}-{3:3}, at: hfsplus_file_truncate+0x2da/0xb40 [ 75.059720][ T5037] [ 75.059720][ T5037] which lock already depends on the new lock. [ 75.059720][ T5037] [ 75.070142][ T5037] [ 75.070142][ T5037] the existing dependency chain (in reverse order) is: [ 75.079178][ T5037] [ 75.079178][ T5037] -> #1 (&HFSPLUS_I(inode)->extents_lock){+.+.}-{3:3}: [ 75.088322][ T5037] __mutex_lock+0x136/0xd60 [ 75.093360][ T5037] hfsplus_file_extend+0x21b/0x1b70 [ 75.099086][ T5037] hfsplus_bmap_reserve+0x105/0x4e0 [ 75.104814][ T5037] hfsplus_create_cat+0x1b0/0x1b90 [ 75.110471][ T5037] hfsplus_fill_super+0x13ea/0x1c90 [ 75.116208][ T5037] mount_bdev+0x237/0x300 [ 75.121088][ T5037] legacy_get_tree+0xef/0x190 [ 75.126312][ T5037] vfs_get_tree+0x8c/0x280 [ 75.131271][ T5037] do_new_mount+0x28f/0xae0 [ 75.136318][ T5037] __se_sys_mount+0x2d9/0x3c0 [ 75.141571][ T5037] do_syscall_64+0x41/0xc0 [ 75.146518][ T5037] entry_SYSCALL_64_after_hwframe+0x63/0xcd [ 75.152936][ T5037] [ 75.152936][ T5037] -> #0 (&tree->tree_lock){+.+.}-{3:3}: [ 75.160682][ T5037] __lock_acquire+0x39ff/0x7f70 [ 75.166234][ T5037] lock_acquire+0x1e3/0x520 [ 75.171271][ T5037] __mutex_lock+0x136/0xd60 [ 75.176320][ T5037] hfsplus_file_truncate+0x811/0xb40 [ 75.182131][ T5037] hfsplus_setattr+0x1b9/0x260 [ 75.187459][ T5037] notify_change+0xb99/0xe60 [ 75.192583][ T5037] do_truncate+0x220/0x300 [ 75.197521][ T5037] vfs_truncate+0x2e1/0x3a0 [ 75.202547][ T5037] do_sys_truncate+0xde/0x190 [ 75.207745][ T5037] do_syscall_64+0x41/0xc0 [ 75.212683][ T5037] entry_SYSCALL_64_after_hwframe+0x63/0xcd [ 75.219201][ T5037] [ 75.219201][ T5037] other info that might help us debug this: [ 75.219201][ T5037] [ 75.229423][ T5037] Possible unsafe locking scenario: [ 75.229423][ T5037] [ 75.236866][ T5037] CPU0 CPU1 [ 75.242224][ T5037] ---- ---- [ 75.247587][ T5037] lock(&HFSPLUS_I(inode)->extents_lock); [ 75.253392][ T5037] lock(&tree->tree_lock); [ 75.260411][ T5037] lock(&HFSPLUS_I(inode)->extents_lock); [ 75.268735][ T5037] lock(&tree->tree_lock); [ 75.273238][ T5037] [ 75.273238][ T5037] *** DEADLOCK *** [ 75.273238][ T5037] [ 75.281453][ T5037] 3 locks held by syz-executor198/5037: [ 75.287011][ T5037] #0: ffff8880784d2410 (sb_writers#9){.+.+}-{0:0}, at: mnt_want_write+0x3f/0x90 [ 75.296190][ T5037] #1: ffff88801fd709c0 (&sb->s_type->i_mutex_key#14){+.+.}-{3:3}, at: do_truncate+0x20c/0x300 [ 75.306605][ T5037] #2: ffff88801fd707c8 (&HFSPLUS_I(inode)->extents_lock){+.+.}-{3:3}, at: hfsplus_file_truncate+0x2da/0xb40 [ 75.318207][ T5037] [ 75.318207][ T5037] stack backtrace: [ 75.324106][ T5037] CPU: 1 PID: 5037 Comm: syz-executor198 Not tainted 6.6.0-rc7-syzkaller-00018-gd88520ad73b7 #0 [ 75.334973][ T5037] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/06/2023 [ 75.345050][ T5037] Call Trace: [ 75.348366][ T5037] [ 75.351403][ T5037] dump_stack_lvl+0x1e7/0x2d0 [ 75.356106][ T5037] ? nf_tcp_handle_invalid+0x650/0x650 [ 75.361612][ T5037] ? print_circular_bug+0x12b/0x1a0 [ 75.366821][ T5037] check_noncircular+0x375/0x4a0 [ 75.371767][ T5037] ? print_deadlock_bug+0x600/0x600 [ 75.376970][ T5037] ? lockdep_lock+0x123/0x2b0 [ 75.381649][ T5037] ? mark_lock+0x9a/0x340 [ 75.385994][ T5037] ? _find_first_zero_bit+0xd4/0x100 [ 75.391344][ T5037] __lock_acquire+0x39ff/0x7f70 [ 75.396235][ T5037] ? verify_lock_unused+0x140/0x140 [ 75.401454][ T5037] ? verify_lock_unused+0x140/0x140 [ 75.406688][ T5037] ? folio_memcg_lock+0x89/0x390 [ 75.411656][ T5037] lock_acquire+0x1e3/0x520 [ 75.416164][ T5037] ? hfsplus_file_truncate+0x811/0xb40 [ 75.421684][ T5037] ? read_lock_is_recursive+0x20/0x20 [ 75.427244][ T5037] ? __might_sleep+0xc0/0xc0 [ 75.431887][ T5037] ? __mutex_unlock_slowpath+0x21c/0x750 [ 75.437573][ T5037] ? hfsplus_block_free+0x3da/0x4d0 [ 75.442786][ T5037] __mutex_lock+0x136/0xd60 [ 75.447315][ T5037] ? hfsplus_file_truncate+0x811/0xb40 [ 75.452820][ T5037] ? hfsplus_file_truncate+0x811/0xb40 [ 75.458303][ T5037] ? mutex_lock_nested+0x20/0x20 [ 75.463257][ T5037] ? hfsplus_free_extents+0x47e/0xae0 [ 75.468673][ T5037] hfsplus_file_truncate+0x811/0xb40 [ 75.473976][ T5037] ? hfsplus_add_extent+0x880/0x880 [ 75.479209][ T5037] ? unmap_mapping_range+0xf8/0x290 [ 75.484438][ T5037] ? unmap_mapping_pages+0x180/0x180 [ 75.489741][ T5037] ? current_time+0x1e0/0x2b0 [ 75.494430][ T5037] ? truncate_setsize+0xcf/0xf0 [ 75.499303][ T5037] hfsplus_setattr+0x1b9/0x260 [ 75.504092][ T5037] ? hfsplus_fileattr_set+0x2f0/0x2f0 [ 75.509603][ T5037] notify_change+0xb99/0xe60 [ 75.514219][ T5037] do_truncate+0x220/0x300 [ 75.519254][ T5037] ? put_page_bootmem+0x2e0/0x2e0 [ 75.524306][ T5037] ? bpf_lsm_path_truncate+0x9/0x10 [ 75.529535][ T5037] vfs_truncate+0x2e1/0x3a0 [ 75.534096][ T5037] do_sys_truncate+0xde/0x190 [ 75.538780][ T5037] ? break_lease+0xd0/0xd0 [ 75.543197][ T5037] ? syscall_enter_from_user_mode+0x32/0x230 [ 75.549184][ T5037] ? syscall_enter_from_user_mode+0x8c/0x230 [ 75.555192][ T5037] do_syscall_64+0x41/0xc0 [ 75.559635][ T5037] entry_SYSCALL_64_after_hwframe+0x63/0xcd [ 75.565539][ T5037] RIP: 0033:0x7fb3e6d4a5f9 [ 75.569963][ T5037] 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 truncate("./file1", 0) = 0 exit_group(0) = ? +++ exited with 0 +++ [ 75.589570][ T5037] RSP: 002b:00007fff76d42098 EFLAGS: 00000246 ORIG_RAX: 0000000000