Debian GNU/Linux 9 syzkaller ttyS0 Warning: Permanently added '10.128.0.7' (ECDSA) to the list of known hosts. executing program syzkaller login: [ 33.292074] hfsplus: xattr searching failed [ 33.297172] [ 33.298798] ============================================ [ 33.304225] WARNING: possible recursive locking detected [ 33.309648] 4.19.211-syzkaller #0 Not tainted [ 33.314121] -------------------------------------------- [ 33.319543] syz-executor399/8115 is trying to acquire lock: [ 33.325225] 00000000d3074a6d (&HFSPLUS_I(inode)->extents_lock){+.+.}, at: hfsplus_get_block+0x292/0x960 [ 33.334739] [ 33.334739] but task is already holding lock: [ 33.340685] 00000000821d49a6 (&HFSPLUS_I(inode)->extents_lock){+.+.}, at: hfsplus_file_truncate+0x1e2/0x1040 [ 33.350634] [ 33.350634] other info that might help us debug this: [ 33.357273] Possible unsafe locking scenario: [ 33.357273] [ 33.363326] CPU0 [ 33.365881] ---- [ 33.368556] lock(&HFSPLUS_I(inode)->extents_lock); [ 33.373715] lock(&HFSPLUS_I(inode)->extents_lock); [ 33.378790] [ 33.378790] *** DEADLOCK *** [ 33.378790] [ 33.384820] May be due to missing lock nesting notation [ 33.384820] [ 33.391723] 4 locks held by syz-executor399/8115: [ 33.396535] #0: 000000000c985c21 (sb_writers#11){.+.+}, at: mnt_want_write+0x3a/0xb0 [ 33.404488] #1: 0000000064d84674 (&sb->s_type->i_mutex_key#17){+.+.}, at: do_truncate+0x125/0x1f0 [ 33.413565] #2: 00000000821d49a6 (&HFSPLUS_I(inode)->extents_lock){+.+.}, at: hfsplus_file_truncate+0x1e2/0x1040 [ 33.423943] #3: 000000000b2ed311 (&sbi->alloc_mutex){+.+.}, at: hfsplus_block_free+0xdb/0x5d0 [ 33.432677] [ 33.432677] stack backtrace: [ 33.437158] CPU: 0 PID: 8115 Comm: syz-executor399 Not tainted 4.19.211-syzkaller #0 [ 33.445010] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/26/2022 [ 33.454336] Call Trace: [ 33.456905] dump_stack+0x1fc/0x2ef [ 33.460511] __lock_acquire.cold+0x121/0x57e [ 33.464897] ? mark_held_locks+0xf0/0xf0 [ 33.468932] ? add_lock_to_list.constprop.0+0x17d/0x330 [ 33.474268] ? save_trace+0xd6/0x290 [ 33.477969] ? __lock_acquire+0x22f9/0x3ff0 [ 33.482266] lock_acquire+0x170/0x3c0 [ 33.486051] ? hfsplus_get_block+0x292/0x960 [ 33.490435] ? hfsplus_get_block+0x292/0x960 [ 33.494818] __mutex_lock+0xd7/0x1190 [ 33.498593] ? hfsplus_get_block+0x292/0x960 [ 33.502979] ? check_preemption_disabled+0x41/0x280 [ 33.507972] ? hfsplus_get_block+0x292/0x960 [ 33.512365] ? mutex_trylock+0x1a0/0x1a0 [ 33.516402] ? create_page_buffers+0x212/0x350 [ 33.520960] ? alloc_page_buffers+0x2da/0x5c0 [ 33.525763] ? lock_downgrade+0x720/0x720 [ 33.529891] ? do_raw_spin_lock+0xcb/0x220 [ 33.534111] hfsplus_get_block+0x292/0x960 [ 33.538333] block_read_full_page+0x288/0xd10 [ 33.542825] ? hfsplus_file_extend+0xf40/0xf40 [ 33.547387] ? __bread_gfp+0x300/0x300 [ 33.551266] ? add_to_page_cache_locked+0x40/0x40 [ 33.556204] do_read_cache_page+0x533/0x1170 [ 33.560591] ? hfsplus_bmap+0x30/0x30 [ 33.564369] hfsplus_block_free+0x18b/0x5d0 [ 33.568667] ? __mutex_unlock_slowpath+0xea/0x610 [ 33.573488] hfsplus_free_extents+0x228/0x520 [ 33.577960] hfsplus_file_truncate+0xd96/0x1040 [ 33.582623] ? hfsplus_get_block+0x960/0x960 [ 33.587012] ? up_write+0x18/0x150 [ 33.590528] ? unmap_mapping_pages+0x121/0x2b0 [ 33.595094] ? inode_newsize_ok+0x121/0x1e0 [ 33.599394] hfsplus_setattr+0x1e7/0x310 [ 33.603433] ? hfsplus_file_open+0x140/0x140 [ 33.607815] notify_change+0x70b/0xfc0 [ 33.611685] do_truncate+0x134/0x1f0 [ 33.615373] ? dentry_open+0x1d0/0x1d0 [ 33.619240] ? apparmor_path_truncate+0x183/0x200 [ 33.624060] ? inode_permission+0x3d/0x140 [ 33.628270] path_openat+0x2308/0x2df0 [ 33.632134] ? path_lookupat+0x8d0/0x8d0 [ 33.636173] ? mark_held_locks+0xf0/0xf0 [ 33.640212] ? __lock_acquire+0x6de/0x3ff0 [ 33.644424] do_filp_open+0x18c/0x3f0 [ 33.648203] ? may_open_dev+0xf0/0xf0 [ 33.651981] ? lock_downgrade+0x720/0x720 [ 33.656115] ? lock_acquire+0x170/0x3c0 [ 33.660068] ? __alloc_fd+0x34/0x570 [ 33.663757] ? do_raw_spin_unlock+0x171/0x230 [ 33.668231] ? _raw_spin_unlock+0x29/0x40 [ 33.672356] ? __alloc_fd+0x28d/0x570 [ 33.676134] do_sys_open+0x3b3/0x520 [ 33.679822] ? filp_open+0x70/0x70 [ 33.683340] ? entry_SYSCALL_64_after_hwframe+0x3e/0xbe [ 33.688683] ? trace_hardirqs_off_caller+0x6e/0x210 [ 33.693675] ? do_syscall_64+0x21/0x620 [ 33.697626] do_syscall_64+0xf9/0x620 [ 33.701401] entry_SYSCALL_64_after_hwframe+0x49/0xbe [ 33.706569] RIP: 0033:0x7fbc4b9cd779 [ 33.710259] 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 [ 33.729138] RSP: 002b:00007ffed072aab8 EFLAGS: 00000246 ORIG_RAX: 0000000000000055 [ 33.736839] RAX: ffffffffffffffda RBX: 0032656c69662f2e RCX: 00007fbc4b9cd779 [