ebian GNU/Linux 9 syzkaller ttyS0 Warning: Permanently added '10.128.0.204' (ECDSA) to the list of known hosts. executing program syzkaller login: [ 33.800172] hfsplus: xattr searching failed [ 33.805181] audit: type=1800 audit(1672670430.063:2): pid=7987 uid=0 auid=4294967295 ses=4294967295 op="collect_data" cause="failed(directio)" comm="syz-executor294" name="file2" dev="loop0" ino=21 res=0 [ 33.824645] hfsplus: xattr searching failed [ 33.830425] [ 33.832070] ============================================ [ 33.837534] WARNING: possible recursive locking detected [ 33.845251] 4.14.302-syzkaller #0 Not tainted [ 33.849741] -------------------------------------------- [ 33.855212] syz-executor294/7987 is trying to acquire lock: [ 33.861063] (&HFSPLUS_I(inode)->extents_lock){+.+.}, at: [] hfsplus_get_block+0x1f9/0x820 [ 33.871165] [ 33.871165] but task is already holding lock: [ 33.877263] (&HFSPLUS_I(inode)->extents_lock){+.+.}, at: [] hfsplus_file_truncate+0x1ba/0xe80 [ 33.887689] [ 33.887689] other info that might help us debug this: [ 33.895841] Possible unsafe locking scenario: [ 33.895841] [ 33.901893] CPU0 [ 33.904469] ---- [ 33.907085] lock(&HFSPLUS_I(inode)->extents_lock); [ 33.912195] lock(&HFSPLUS_I(inode)->extents_lock); [ 33.917287] [ 33.917287] *** DEADLOCK *** [ 33.917287] [ 33.923513] May be due to missing lock nesting notation [ 33.923513] [ 33.930616] 5 locks held by syz-executor294/7987: [ 33.935439] #0: (sb_writers#10){.+.+}, at: [] mnt_want_write+0x3a/0xb0 [ 33.943859] #1: (&sb->s_type->i_mutex_key#17){+.+.}, at: [] do_truncate+0xf0/0x1a0 [ 33.953515] #2: (&HFSPLUS_I(inode)->extents_lock){+.+.}, at: [] hfsplus_file_truncate+0x1ba/0xe80 [ 33.965252] #3: (&tree->tree_lock/1){+.+.}, at: [] hfsplus_find_init+0x161/0x220 [ 33.974538] #4: (&sbi->alloc_mutex){+.+.}, at: [] hfsplus_block_free+0xc7/0x560 [ 33.983815] [ 33.983815] stack backtrace: [ 33.988435] CPU: 1 PID: 7987 Comm: syz-executor294 Not tainted 4.14.302-syzkaller #0 [ 33.996487] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/26/2022 [ 34.005925] Call Trace: [ 34.008519] dump_stack+0x1b2/0x281 [ 34.012134] __lock_acquire.cold+0x180/0x97c [ 34.016645] ? register_lock_class+0x1d0/0x1180 [ 34.021330] ? trace_hardirqs_on+0x10/0x10 [ 34.025703] ? add_lock_to_list.constprop.0+0x17d/0x330 [ 34.031077] ? save_trace+0xd6/0x290 [ 34.034782] ? __lock_acquire+0x2190/0x3f20 [ 34.039091] lock_acquire+0x170/0x3f0 [ 34.042909] ? hfsplus_get_block+0x1f9/0x820 [ 34.047646] ? hfsplus_get_block+0x1f9/0x820 [ 34.052155] __mutex_lock+0xc4/0x1310 [ 34.055946] ? hfsplus_get_block+0x1f9/0x820 [ 34.060439] ? hfsplus_get_block+0x1f9/0x820 [ 34.064891] ? __ww_mutex_wakeup_for_backoff+0x210/0x210 [ 34.070349] ? lock_acquire+0x170/0x3f0 [ 34.074334] ? create_page_buffers+0x14d/0x1c0 [ 34.078908] hfsplus_get_block+0x1f9/0x820 [ 34.083254] ? _raw_spin_unlock+0x29/0x40 [ 34.087518] ? create_page_buffers+0xce/0x1c0 [ 34.092032] block_read_full_page+0x25e/0x8d0 [ 34.096614] ? hfsplus_file_extend+0xef0/0xef0 [ 34.101222] ? __lru_cache_add+0x178/0x250 [ 34.105553] ? __bread_gfp+0x2e0/0x2e0 [ 34.109468] ? add_to_page_cache_lru+0x136/0x2b0 [ 34.114234] ? add_to_page_cache_locked+0x40/0x40 [ 34.119116] ? alloc_pages_current+0x15d/0x260 [ 34.123721] do_read_cache_page+0x38e/0xc10 [ 34.128309] ? hfsplus_bmap+0x30/0x30 [ 34.132141] ? __ww_mutex_wakeup_for_backoff+0x210/0x210 [ 34.137797] hfsplus_block_free+0x177/0x560 [ 34.142130] hfsplus_free_extents+0x170/0x440 [ 34.146739] hfsplus_file_truncate+0xbc0/0xe80 [ 34.151448] ? hfsplus_get_block+0x820/0x820 [ 34.156123] ? up_write+0x17/0x60 [ 34.159861] ? unmap_mapping_range+0xe9/0x250 [ 34.164498] ? inode_newsize_ok+0x145/0x1c0 [ 34.168829] hfsplus_setattr+0x182/0x310 [ 34.172957] ? hfsplus_file_fsync+0x4a0/0x4a0 [ 34.177532] notify_change+0x56b/0xd10 [ 34.181450] do_truncate+0xff/0x1a0 [ 34.185177] ? finish_open+0x170/0x170 [ 34.189068] ? apparmor_path_truncate+0x163/0x1d0 [ 34.194125] path_openat+0x1dcc/0x2970 [ 34.198161] ? path_lookupat+0x780/0x780 [ 34.202331] ? trace_hardirqs_on+0x10/0x10 [ 34.206667] ? trace_hardirqs_on+0x10/0x10 [ 34.210894] do_filp_open+0x179/0x3c0 [ 34.214695] ? may_open_dev+0xe0/0xe0 [ 34.218501] ? lock_downgrade+0x740/0x740 [ 34.222655] ? do_raw_spin_unlock+0x164/0x220 [ 34.227168] ? _raw_spin_unlock+0x29/0x40 [ 34.231320] ? __alloc_fd+0x1be/0x490 [ 34.235113] ? _raw_spin_unlock_irq+0x24/0x80 [ 34.239691] do_sys_open+0x296/0x410 [ 34.243399] ? filp_open+0x60/0x60 [ 34.247167] ? do_syscall_64+0x4c/0x640 [ 34.251134] ? do_sys_open+0x410/0x410 [ 34.255110] do_syscall_64+0x1d5/0x640 [ 34.259006] entry_SYSCALL_64_after_hwframe+0x5e/0xd3 [ 34.264272] RIP: 0033:0x7f2332fbc789 [ 34.267969] RSP: 002b:00007fff0c8c27f8 EFLAGS: 00000246 ORIG_RAX: 0000000000000002 [ 34.276063] RAX: ffffffffffffffda RBX: 0032656c69662f2e RCX: 00007f2332fbc789 [ 34.283328] RDX: 0000000000000160 RSI: 00000000001a5602 RDI: 00000000200013c0 [ 34.290604] RBP: 00007f2332f7c020 R08: 00000000000005e1 R09: 0000000000000000 [ 34.297954] R10: 00007fff0c8c26c0 R11: 0000000000000246 R12: 00007f2332f7c0b0 [ 34.305350] R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000