[ OK ] Started Getty on tty2. [ OK ] Started Serial Getty on ttyS0. [ OK ] Started Getty on tty1. [ OK ] Reached target Login Prompts. [ OK ] Reached target Multi-User System. [ OK ] Reached target Graphical Interface. Starting Update UTMP about System Runlevel Changes... [ OK ] Started Update UTMP about System Runlevel Changes. Starting Load/Save RF Kill Switch Status... [ OK ] Started Load/Save RF Kill Switch Status. Debian GNU/Linux 9 syzkaller ttyS0 Warning: Permanently added '10.128.0.243' (ECDSA) to the list of known hosts. executing program syzkaller login: [ 27.473078] [ 27.474719] ============================================ [ 27.480151] WARNING: possible recursive locking detected [ 27.485595] 4.14.302-syzkaller #0 Not tainted [ 27.490066] -------------------------------------------- [ 27.495488] syz-executor170/7958 is trying to acquire lock: [ 27.501170] (&HFSPLUS_I(inode)->extents_lock){+.+.}, at: [] hfsplus_get_block+0x1f9/0x820 [ 27.511124] [ 27.511124] but task is already holding lock: [ 27.517067] (&HFSPLUS_I(inode)->extents_lock){+.+.}, at: [] hfsplus_file_truncate+0x1ba/0xe80 [ 27.527362] [ 27.527362] other info that might help us debug this: [ 27.534003] Possible unsafe locking scenario: [ 27.534003] [ 27.540033] CPU0 [ 27.542593] ---- [ 27.545147] lock(&HFSPLUS_I(inode)->extents_lock); [ 27.550219] lock(&HFSPLUS_I(inode)->extents_lock); [ 27.555292] [ 27.555292] *** DEADLOCK *** [ 27.555292] [ 27.561319] May be due to missing lock nesting notation [ 27.561319] [ 27.568217] 5 locks held by syz-executor170/7958: [ 27.573030] #0: (sb_writers#10){.+.+}, at: [] mnt_want_write+0x3a/0xb0 [ 27.581415] #1: (&sb->s_type->i_mutex_key#17){+.+.}, at: [] do_truncate+0xf0/0x1a0 [ 27.590857] #2: (&HFSPLUS_I(inode)->extents_lock){+.+.}, at: [] hfsplus_file_truncate+0x1ba/0xe80 [ 27.601581] #3: (&tree->tree_lock/1){+.+.}, at: [] hfsplus_find_init+0x161/0x220 [ 27.611012] #4: (&sbi->alloc_mutex){+.+.}, at: [] hfsplus_block_free+0xc7/0x560 [ 27.620256] [ 27.620256] stack backtrace: [ 27.624730] CPU: 1 PID: 7958 Comm: syz-executor170 Not tainted 4.14.302-syzkaller #0 [ 27.632577] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/26/2022 [ 27.641908] Call Trace: [ 27.644477] dump_stack+0x1b2/0x281 [ 27.648078] __lock_acquire.cold+0x180/0x97c [ 27.652460] ? register_lock_class+0x1d0/0x1180 [ 27.657098] ? trace_hardirqs_on+0x10/0x10 [ 27.661304] ? add_lock_to_list.constprop.0+0x17d/0x330 [ 27.666634] ? save_trace+0xd6/0x290 [ 27.670317] ? __lock_acquire+0x2190/0x3f20 [ 27.674608] lock_acquire+0x170/0x3f0 [ 27.678380] ? hfsplus_get_block+0x1f9/0x820 [ 27.682762] ? hfsplus_get_block+0x1f9/0x820 [ 27.687140] __mutex_lock+0xc4/0x1310 [ 27.690909] ? hfsplus_get_block+0x1f9/0x820 [ 27.695302] ? hfsplus_get_block+0x1f9/0x820 [ 27.699682] ? __ww_mutex_wakeup_for_backoff+0x210/0x210 [ 27.705119] ? lock_acquire+0x170/0x3f0 [ 27.709078] ? create_page_buffers+0x14d/0x1c0 [ 27.713740] hfsplus_get_block+0x1f9/0x820 [ 27.717956] ? _raw_spin_unlock+0x29/0x40 [ 27.722078] ? create_page_buffers+0xce/0x1c0 [ 27.726545] block_read_full_page+0x25e/0x8d0 [ 27.731012] ? hfsplus_file_extend+0xef0/0xef0 [ 27.735568] ? __lru_cache_add+0x178/0x250 [ 27.739773] ? __bread_gfp+0x2e0/0x2e0 [ 27.743632] ? add_to_page_cache_lru+0x136/0x2b0 [ 27.748355] ? add_to_page_cache_locked+0x40/0x40 [ 27.753168] ? alloc_pages_current+0x15d/0x260 [ 27.757719] do_read_cache_page+0x38e/0xc10 [ 27.762014] ? hfsplus_bmap+0x30/0x30 [ 27.765790] ? __ww_mutex_wakeup_for_backoff+0x210/0x210 [ 27.771211] hfsplus_block_free+0x177/0x560 [ 27.775508] hfsplus_free_extents+0x170/0x440 [ 27.779974] hfsplus_file_truncate+0xbc0/0xe80 [ 27.784528] ? hfsplus_get_block+0x820/0x820 [ 27.788907] ? up_write+0x17/0x60 [ 27.792333] ? unmap_mapping_range+0xe9/0x250 [ 27.796798] ? inode_newsize_ok+0x145/0x1c0 [ 27.801092] hfsplus_setattr+0x182/0x310 [ 27.805125] ? hfsplus_file_fsync+0x4a0/0x4a0 [ 27.809593] notify_change+0x56b/0xd10 [ 27.813452] do_truncate+0xff/0x1a0 [ 27.817052] ? finish_open+0x170/0x170 [ 27.820910] ? apparmor_path_truncate+0x163/0x1d0 [ 27.825727] path_openat+0x1dcc/0x2970 [ 27.829584] ? path_lookupat+0x780/0x780 [ 27.833614] ? trace_hardirqs_on+0x10/0x10 [ 27.837820] ? trace_hardirqs_on+0x10/0x10 [ 27.842036] do_filp_open+0x179/0x3c0 [ 27.845814] ? may_open_dev+0xe0/0xe0 [ 27.849594] ? lock_downgrade+0x740/0x740 [ 27.853890] ? do_raw_spin_unlock+0x164/0x220 [ 27.858358] ? _raw_spin_unlock+0x29/0x40 [ 27.862481] ? __alloc_fd+0x1be/0x490 [ 27.866253] ? _raw_spin_unlock_irq+0x24/0x80 [ 27.870730] do_sys_open+0x296/0x410 [ 27.874418] ? filp_open+0x60/0x60 [ 27.877927] ? do_syscall_64+0x4c/0x640 [ 27.881873] ? compat_SyS_openat+0x30/0x30 [ 27.886086] do_syscall_64+0x1d5/0x640 [ 27.889945] entry_SYSCALL_64_after_hwframe+0x5e/0xd3 [ 27.895104] RIP: 0033:0x7f6487fc3789 [ 27.898785] RSP: 002b:00007ffdeb55ded8 EFLAGS: 00000246 ORIG_RAX: 0000000000000055 [ 27.906464] RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007f6487fc3789 [ 27.913706] RDX: 00007f6487f81e03 RSI: 0000000000000000 RDI: 0000000020000000 [ 27.920946] RBP: 00007f6487f83020 R08: 0000000000000609 R09: 0000000000000000 [ 27.928187] R10: 00007ffdeb55dda0 R11: 0000000000000246 R12: 00007f6487f830b0 [ 27.935425] R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000