Warning: Permanently added '10.128.1.35' (ECDSA) to the list of known hosts. executing program [ 35.440281] hfsplus: xattr searching failed [ 35.445040] [ 35.446654] ============================================ [ 35.452082] WARNING: possible recursive locking detected [ 35.457517] 4.19.211-syzkaller #0 Not tainted [ 35.462005] -------------------------------------------- [ 35.467472] syz-executor211/8113 is trying to acquire lock: [ 35.473160] 0000000036323424 (&HFSPLUS_I(inode)->extents_lock){+.+.}, at: hfsplus_get_block+0x292/0x960 [ 35.482697] [ 35.482697] but task is already holding lock: [ 35.488647] 000000009d4337be (&HFSPLUS_I(inode)->extents_lock){+.+.}, at: hfsplus_file_truncate+0x1e2/0x1040 [ 35.498599] [ 35.498599] other info that might help us debug this: [ 35.505240] Possible unsafe locking scenario: [ 35.505240] [ 35.511286] CPU0 [ 35.513850] ---- [ 35.516408] lock(&HFSPLUS_I(inode)->extents_lock); [ 35.521484] lock(&HFSPLUS_I(inode)->extents_lock); [ 35.526565] [ 35.526565] *** DEADLOCK *** [ 35.526565] [ 35.532599] May be due to missing lock nesting notation [ 35.532599] [ 35.539504] 4 locks held by syz-executor211/8113: [ 35.544321] #0: 00000000ebd14cf7 (sb_writers#11){.+.+}, at: mnt_want_write+0x3a/0xb0 [ 35.552281] #1: 00000000683961a3 (&sb->s_type->i_mutex_key#17){+.+.}, at: do_truncate+0x125/0x1f0 [ 35.561384] #2: 000000009d4337be (&HFSPLUS_I(inode)->extents_lock){+.+.}, at: hfsplus_file_truncate+0x1e2/0x1040 [ 35.571765] #3: 0000000041cc1583 (&sbi->alloc_mutex){+.+.}, at: hfsplus_block_free+0xdb/0x5d0 [ 35.580497] [ 35.580497] stack backtrace: [ 35.584972] CPU: 1 PID: 8113 Comm: syz-executor211 Not tainted 4.19.211-syzkaller #0 [ 35.592855] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/26/2022 [ 35.602184] Call Trace: [ 35.604753] dump_stack+0x1fc/0x2ef [ 35.608368] __lock_acquire.cold+0x121/0x57e [ 35.612761] ? mark_held_locks+0xf0/0xf0 [ 35.616798] ? add_lock_to_list.constprop.0+0x17d/0x330 [ 35.622138] ? save_trace+0xd6/0x290 [ 35.625829] ? __lock_acquire+0x22f9/0x3ff0 [ 35.630127] lock_acquire+0x170/0x3c0 [ 35.633903] ? hfsplus_get_block+0x292/0x960 [ 35.638292] ? hfsplus_get_block+0x292/0x960 [ 35.642677] __mutex_lock+0xd7/0x1190 [ 35.646457] ? hfsplus_get_block+0x292/0x960 [ 35.650844] ? check_preemption_disabled+0x41/0x280 [ 35.655843] ? hfsplus_get_block+0x292/0x960 [ 35.660238] ? mutex_trylock+0x1a0/0x1a0 [ 35.664282] ? create_page_buffers+0x212/0x350 [ 35.668854] ? alloc_page_buffers+0x2da/0x5c0 [ 35.673329] ? lock_downgrade+0x720/0x720 [ 35.677454] ? do_raw_spin_lock+0xcb/0x220 [ 35.681669] hfsplus_get_block+0x292/0x960 [ 35.685890] block_read_full_page+0x288/0xd10 [ 35.690367] ? hfsplus_file_extend+0xf40/0xf40 [ 35.694925] ? __bread_gfp+0x300/0x300 [ 35.698793] ? add_to_page_cache_locked+0x40/0x40 [ 35.703612] do_read_cache_page+0x533/0x1170 [ 35.707997] ? hfsplus_bmap+0x30/0x30 [ 35.711774] hfsplus_block_free+0x18b/0x5d0 [ 35.716072] ? __mutex_unlock_slowpath+0xea/0x610 [ 35.720893] hfsplus_free_extents+0x228/0x520 [ 35.725376] hfsplus_file_truncate+0xd96/0x1040 [ 35.730033] ? hfsplus_get_block+0x960/0x960 [ 35.734422] ? up_write+0x18/0x150 [ 35.737940] ? unmap_mapping_pages+0x121/0x2b0 [ 35.742498] ? inode_newsize_ok+0x121/0x1e0 [ 35.746797] hfsplus_setattr+0x1e7/0x310 [ 35.750837] ? hfsplus_file_open+0x140/0x140 [ 35.755223] notify_change+0x70b/0xfc0 [ 35.759090] do_truncate+0x134/0x1f0 [ 35.762785] ? dentry_open+0x1d0/0x1d0 [ 35.766655] ? apparmor_path_truncate+0x183/0x200 [ 35.771476] ? inode_permission+0x3d/0x140 [ 35.775691] path_openat+0x2308/0x2df0 [ 35.779558] ? path_lookupat+0x8d0/0x8d0 [ 35.783596] ? mark_held_locks+0xf0/0xf0 [ 35.787631] ? __lock_acquire+0x6de/0x3ff0 [ 35.791842] do_filp_open+0x18c/0x3f0 [ 35.795615] ? may_open_dev+0xf0/0xf0 [ 35.799394] ? lock_downgrade+0x720/0x720 [ 35.803520] ? lock_acquire+0x170/0x3c0 [ 35.807479] ? __alloc_fd+0x34/0x570 [ 35.811168] ? do_raw_spin_unlock+0x171/0x230 [ 35.815641] ? _raw_spin_unlock+0x29/0x40 [ 35.819763] ? __alloc_fd+0x28d/0x570 [ 35.823540] do_sys_open+0x3b3/0x520 [ 35.827227] ? filp_open+0x70/0x70 [ 35.830746] ? entry_SYSCALL_64_after_hwframe+0x3e/0xbe [ 35.836094] ? trace_hardirqs_off_caller+0x6e/0x210 [ 35.841087] ? do_syscall_64+0x21/0x620 [ 35.845036] do_syscall_64+0xf9/0x620 [ 35.848811] entry_SYSCALL_64_after_hwframe+0x49/0xbe [ 35.853974] RIP: 0033:0x7f0ec8eb9789 [ 35.857663] 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 [ 35.876540] RSP: 002b:00007ffdf3e65b38 EFLAGS: 00000246 ORIG_RAX: 0000000000000055 [ 35.884222] RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007f0ec8eb9789 [ 35.8914