Warning: Permanently added '10.128.1.153' (ECDSA) to the list of known hosts. executing program [ 40.786986] hfsplus: xattr searching failed [ 40.791691] [ 40.793302] ============================================ [ 40.798741] WARNING: possible recursive locking detected [ 40.804185] 4.19.211-syzkaller #0 Not tainted [ 40.808668] -------------------------------------------- [ 40.814114] syz-executor256/8113 is trying to acquire lock: [ 40.819823] 0000000039137ddd (&HFSPLUS_I(inode)->extents_lock){+.+.}, at: hfsplus_get_block+0x292/0x960 [ 40.829362] [ 40.829362] but task is already holding lock: [ 40.835315] 000000004e9aa832 (&HFSPLUS_I(inode)->extents_lock){+.+.}, at: hfsplus_file_truncate+0x1e2/0x1040 [ 40.845361] [ 40.845361] other info that might help us debug this: [ 40.852000] Possible unsafe locking scenario: [ 40.852000] [ 40.858029] CPU0 [ 40.860586] ---- [ 40.863142] lock(&HFSPLUS_I(inode)->extents_lock); [ 40.868216] lock(&HFSPLUS_I(inode)->extents_lock); [ 40.873294] [ 40.873294] *** DEADLOCK *** [ 40.873294] [ 40.879324] May be due to missing lock nesting notation [ 40.879324] [ 40.886244] 4 locks held by syz-executor256/8113: [ 40.891057] #0: 00000000b3686bc7 (sb_writers#11){.+.+}, at: mnt_want_write+0x3a/0xb0 [ 40.899010] #1: 0000000076042256 (&sb->s_type->i_mutex_key#17){+.+.}, at: do_truncate+0x125/0x1f0 [ 40.908093] #2: 000000004e9aa832 (&HFSPLUS_I(inode)->extents_lock){+.+.}, at: hfsplus_file_truncate+0x1e2/0x1040 [ 40.918485] #3: 00000000ed5eb466 (&sbi->alloc_mutex){+.+.}, at: hfsplus_block_free+0xdb/0x5d0 [ 40.927231] [ 40.927231] stack backtrace: [ 40.931727] CPU: 1 PID: 8113 Comm: syz-executor256 Not tainted 4.19.211-syzkaller #0 [ 40.939581] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/26/2022 [ 40.948921] Call Trace: [ 40.951500] dump_stack+0x1fc/0x2ef [ 40.955120] __lock_acquire.cold+0x121/0x57e [ 40.959538] ? mark_held_locks+0xf0/0xf0 [ 40.963581] ? add_lock_to_list.constprop.0+0x17d/0x330 [ 40.968920] ? save_trace+0xd6/0x290 [ 40.972698] ? __lock_acquire+0x22f9/0x3ff0 [ 40.976996] lock_acquire+0x170/0x3c0 [ 40.980772] ? hfsplus_get_block+0x292/0x960 [ 40.985157] ? hfsplus_get_block+0x292/0x960 [ 40.989539] __mutex_lock+0xd7/0x1190 [ 40.993325] ? hfsplus_get_block+0x292/0x960 [ 40.997713] ? check_preemption_disabled+0x41/0x280 [ 41.002707] ? hfsplus_get_block+0x292/0x960 [ 41.007092] ? mutex_trylock+0x1a0/0x1a0 [ 41.011147] ? create_page_buffers+0x212/0x350 [ 41.015704] ? alloc_page_buffers+0x2da/0x5c0 [ 41.020178] ? lock_downgrade+0x720/0x720 [ 41.024301] ? do_raw_spin_lock+0xcb/0x220 [ 41.028512] hfsplus_get_block+0x292/0x960 [ 41.032727] block_read_full_page+0x288/0xd10 [ 41.037200] ? hfsplus_file_extend+0xf40/0xf40 [ 41.041760] ? __bread_gfp+0x300/0x300 [ 41.045625] ? add_to_page_cache_locked+0x40/0x40 [ 41.050445] do_read_cache_page+0x533/0x1170 [ 41.054833] ? hfsplus_bmap+0x30/0x30 [ 41.058609] hfsplus_block_free+0x18b/0x5d0 [ 41.062906] ? __mutex_unlock_slowpath+0xea/0x610 [ 41.067724] hfsplus_free_extents+0x228/0x520 [ 41.072201] hfsplus_file_truncate+0xd96/0x1040 [ 41.076847] ? hfsplus_get_block+0x960/0x960 [ 41.081232] ? up_write+0x18/0x150 [ 41.084749] ? unmap_mapping_pages+0x121/0x2b0 [ 41.089306] ? inode_newsize_ok+0x121/0x1e0 [ 41.093605] hfsplus_setattr+0x1e7/0x310 [ 41.097650] ? hfsplus_file_open+0x140/0x140 [ 41.102036] notify_change+0x70b/0xfc0 [ 41.106945] do_truncate+0x134/0x1f0 [ 41.110635] ? dentry_open+0x1d0/0x1d0 [ 41.114501] ? apparmor_path_truncate+0x183/0x200 [ 41.119320] ? inode_permission+0x3d/0x140 [ 41.123532] path_openat+0x2308/0x2df0 [ 41.127398] ? path_lookupat+0x8d0/0x8d0 [ 41.131440] ? mark_held_locks+0xf0/0xf0 [ 41.135485] ? __lock_acquire+0x6de/0x3ff0 [ 41.139699] do_filp_open+0x18c/0x3f0 [ 41.143477] ? may_open_dev+0xf0/0xf0 [ 41.147252] ? lock_downgrade+0x720/0x720 [ 41.151376] ? lock_acquire+0x170/0x3c0 [ 41.155325] ? __alloc_fd+0x34/0x570 [ 41.159018] ? do_raw_spin_unlock+0x171/0x230 [ 41.163488] ? _raw_spin_unlock+0x29/0x40 [ 41.167611] ? __alloc_fd+0x28d/0x570 [ 41.171388] do_sys_open+0x3b3/0x520 [ 41.175081] ? filp_open+0x70/0x70 [ 41.178599] ? entry_SYSCALL_64_after_hwframe+0x3e/0xbe [ 41.183942] ? trace_hardirqs_off_caller+0x6e/0x210 [ 41.188936] ? do_syscall_64+0x21/0x620 [ 41.192885] do_syscall_64+0xf9/0x620 [ 41.196672] entry_SYSCALL_64_after_hwframe+0x49/0xbe [ 41.201836] RIP: 0033:0x7f041b9a5779 [ 41.205526] 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 [ 41.224401] RSP: 002b:00007ffd42c4f0d8 EFLAGS: 00000246 ORIG_RAX: 0000000000000055 [ 41.232086] RAX: ffffffffffffffda RBX: 0032656c69662f2e RCX: 00007f041b9a5779