loop0: detected capacity change from 0 to 1024 ============================================ WARNING: possible recursive locking detected syzkaller #0 Not tainted -------------------------------------------- syz.0.17/4413 is trying to acquire lock: ffff888077e48e88 (&HFSPLUS_I(inode)->extents_lock){+.+.}-{3:3}, at: hfsplus_get_block+0x3a1/0x15a0 fs/hfsplus/extents.c:260 but task is already holding lock: ffff888077e4a2c8 (&HFSPLUS_I(inode)->extents_lock){+.+.}-{3:3}, at: hfsplus_file_truncate+0x2b7/0xb60 fs/hfsplus/extents.c:574 other info that might help us debug this: Possible unsafe locking scenario: CPU0 ---- lock(&HFSPLUS_I(inode)->extents_lock); lock(&HFSPLUS_I(inode)->extents_lock); *** DEADLOCK *** May be due to missing lock nesting notation 4 locks held by syz.0.17/4413: #0: ffff88807d9da460 (sb_writers#13){.+.+}-{0:0}, at: mnt_want_write+0x3d/0x90 fs/namespace.c:402 #1: ffff888077e4a4c0 (&sb->s_type->i_mutex_key#21){+.+.}-{3:3}, at: inode_lock include/linux/fs.h:758 [inline] #1: ffff888077e4a4c0 (&sb->s_type->i_mutex_key#21){+.+.}-{3:3}, at: do_truncate+0x198/0x240 fs/open.c:63 #2: ffff888077e4a2c8 (&HFSPLUS_I(inode)->extents_lock){+.+.}-{3:3}, at: hfsplus_file_truncate+0x2b7/0xb60 fs/hfsplus/extents.c:574 #3: ffff8880291010f8 (&sbi->alloc_mutex){+.+.}-{3:3}, at: hfsplus_block_free+0xbf/0x4b0 fs/hfsplus/bitmap.c:182 stack backtrace: CPU: 0 PID: 4413 Comm: syz.0.17 Not tainted syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/18/2026 Call Trace: dump_stack_lvl+0x188/0x24e lib/dump_stack.c:106 __lock_acquire+0x123e/0x7d10 kernel/locking/lockdep.c:-1 lock_acquire+0x1bb/0x4a0 kernel/locking/lockdep.c:5662 __mutex_lock_common kernel/locking/mutex.c:603 [inline] __mutex_lock+0x12d/0xaf0 kernel/locking/mutex.c:747 hfsplus_get_block+0x3a1/0x15a0 fs/hfsplus/extents.c:260 block_read_full_folio+0x3e6/0xf00 fs/buffer.c:2271 filemap_read_folio+0x16b/0x770 mm/filemap.c:2490 do_read_cache_folio+0x2a0/0x760 mm/filemap.c:3659 do_read_cache_page+0x32/0x220 mm/filemap.c:3701 read_mapping_page include/linux/pagemap.h:793 [inline] hfsplus_block_free+0x128/0x4b0 fs/hfsplus/bitmap.c:185 hfsplus_free_extents+0x10d/0xa50 fs/hfsplus/extents.c:360 hfsplus_file_truncate+0x765/0xb60 fs/hfsplus/extents.c:589 hfsplus_setattr+0x1c0/0x280 fs/hfsplus/inode.c:289 notify_change+0xc74/0xf40 fs/attr.c:499 do_truncate+0x1ac/0x240 fs/open.c:65 handle_truncate fs/namei.c:3293 [inline] do_open fs/namei.c:3638 [inline] path_openat+0x2861/0x2ee0 fs/namei.c:3791 do_filp_open+0x1f1/0x430 fs/namei.c:3818 do_sys_openat2+0x150/0x4b0 fs/open.c:1320 do_sys_open fs/open.c:1336 [inline] __do_sys_creat fs/open.c:1414 [inline] __se_sys_creat fs/open.c:1408 [inline] __x64_sys_creat+0x8c/0xb0 fs/open.c:1408 do_syscall_x64 arch/x86/entry/common.c:46 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:76 entry_SYSCALL_64_after_hwframe+0x68/0xd2 RIP: 0033:0x7f7e7b59c819 Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 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 e8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007ffc303715e8 EFLAGS: 00000246 ORIG_RAX: 0000000000000055 RAX: ffffffffffffffda RBX: 00007f7e7b815fa0 RCX: 00007f7e7b59c819 RDX: 0000000000000000 RSI: 0000000000000016 RDI: 00002000000000c0 RBP: 00007f7e7b632c91 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 00007f7e7b815fac R14: 00007f7e7b815fa0 R15: 00007f7e7b815fa0 hfsplus: unable to mark blocks free: error -5 hfsplus: can't free extent