IPVS: ftp: loaded support on port[0] = 21 IPVS: ftp: loaded support on port[0] = 21 hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB ============================================ WARNING: possible recursive locking detected 5.7.0-rc1-syzkaller #0 Not tainted -------------------------------------------- syz-executor2/4123 is trying to acquire lock: ffff8881c795e0b0 (&tree->tree_lock){+.+.}-{3:3}, at: hfs_find_init+0x110/0x180 fs/hfs/bfind.c:28 but task is already holding lock: ffff8881c79160b0 (&tree->tree_lock){+.+.}-{3:3}, at: hfs_find_init+0x110/0x180 fs/hfs/bfind.c:28 other info that might help us debug this: Possible unsafe locking scenario: CPU0 ---- lock(&tree->tree_lock); lock(&tree->tree_lock); *** DEADLOCK *** May be due to missing lock nesting notation 3 locks held by syz-executor2/4123: #0: ffff8881c6f500e0 (&type->s_umount_key#48/1){+.+.}-{3:3}, at: alloc_super+0x1a1/0x9b0 fs/super.c:229 #1: ffff8881c79160b0 (&tree->tree_lock){+.+.}-{3:3}, at: hfs_find_init+0x110/0x180 fs/hfs/bfind.c:28 #2: ffff8881c7905338 (&HFS_I(tree->inode)->extents_lock){+.+.}-{3:3}, at: hfs_get_block+0x484/0x850 fs/hfs/extent.c:365 stack backtrace: CPU: 0 PID: 4123 Comm: syz-executor2 Not tainted 5.7.0-rc1-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:77 [inline] dump_stack+0x12f/0x187 lib/dump_stack.c:118 print_deadlock_bug kernel/locking/lockdep.c:2410 [inline] check_deadlock kernel/locking/lockdep.c:2451 [inline] validate_chain kernel/locking/lockdep.c:3221 [inline] __lock_acquire.cold.67+0x21f/0x3eb kernel/locking/lockdep.c:4355 lock_acquire+0x200/0x9b0 kernel/locking/lockdep.c:4934 __mutex_lock_common kernel/locking/mutex.c:956 [inline] __mutex_lock+0x160/0x1400 kernel/locking/mutex.c:1103 mutex_lock_nested+0x16/0x20 kernel/locking/mutex.c:1118 hfs_find_init+0x110/0x180 fs/hfs/bfind.c:28 hfs_ext_read_extent+0x17e/0xcc0 fs/hfs/extent.c:200 hfs_get_block+0x490/0x850 fs/hfs/extent.c:366 block_read_full_page+0x290/0x9b0 fs/buffer.c:2279 hfs_readpage+0x13/0x20 fs/hfs/inode.c:38 do_read_cache_page+0x65c/0x1380 mm/filemap.c:2768 read_cache_page+0x45/0x70 mm/filemap.c:2867 read_mapping_page include/linux/pagemap.h:397 [inline] __hfs_bnode_create+0x54a/0x7b0 fs/hfs/bnode.c:281 hfs_bnode_find+0x1bc/0xa20 fs/hfs/bnode.c:330 hfs_brec_find+0x27e/0x490 fs/hfs/bfind.c:114 hfs_brec_read+0x1d/0xe0 fs/hfs/bfind.c:153 hfs_cat_find_brec+0x142/0x310 fs/hfs/catalog.c:194 hfs_fill_super+0xabd/0x12a0 fs/hfs/super.c:420 mount_bdev+0x27b/0x340 fs/super.c:1417 hfs_mount+0x10/0x20 fs/hfs/super.c:457 legacy_get_tree+0x103/0x1f0 fs/fs_context.c:622 vfs_get_tree+0x8b/0x2d0 fs/super.c:1547 do_new_mount fs/namespace.c:2816 [inline] do_mount+0x1287/0x1c30 fs/namespace.c:3141 __do_sys_mount fs/namespace.c:3350 [inline] __se_sys_mount fs/namespace.c:3327 [inline] __x64_sys_mount+0x169/0x1c0 fs/namespace.c:3327 do_syscall_64+0xd0/0x630 arch/x86/entry/common.c:295 entry_SYSCALL_64_after_hwframe+0x49/0xb3 RIP: 0033:0x457efa Code: b8 a6 00 00 00 0f 05 48 3d 01 f0 ff ff 0f 83 dd 8f fb ff c3 66 2e 0f 1f 84 00 00 00 00 00 66 90 49 89 ca b8 a5 00 00 00 0f 05 <48> 3d 01 f0 ff ff 0f 83 ba 8f fb ff c3 66 0f 1f 84 00 00 00 00 00 RSP: 002b:00007f7e5f9aaba8 EFLAGS: 00000246 ORIG_RAX: 00000000000000a5 RAX: ffffffffffffffda RBX: 0000000020000000 RCX: 0000000000457efa RDX: 0000000020000000 RSI: 0000000020000100 RDI: 00007f7e5f9aabf0 RBP: 0000000000000003 R08: 00000000200002c0 R09: 0000000020000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000003 R13: 0000000000000003 R14: 00000000006fcbb0 R15: 0000000000000000 hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: get root inode failed hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: unable to locate alternate MDB hfs: get root inode failed hfs: continuing without an alternate MDB hfs: get root inode failed hfs: get root inode failed hfs: get root inode failed hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: get root inode failed hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: get root inode failed hfs: unable to locate alternate MDB hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: get root inode failed hfs: continuing without an alternate MDB hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: get root inode failed hfs: get root inode failed hfs: get root inode failed hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: get root inode failed hfs: get root inode failed hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: get root inode failed hfs: get root inode failed hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: get root inode failed hfs: get root inode failed hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: get root inode failed hfs: get root inode failed hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: get root inode failed hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: get root inode failed hfs: get root inode failed hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: unable to locate alternate MDB hfs: get root inode failed hfs: continuing without an alternate MDB hfs: get root inode failed hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: get root inode failed hfs: unable to locate alternate MDB hfs: get root inode failed hfs: continuing without an alternate MDB hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: get root inode failed hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: get root inode failed hfs: get root inode failed hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: get root inode failed hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: get root inode failed hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: get root inode failed hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: unable to locate alternate MDB hfs: continuing without an alternate MDB hfs: get root inode failed hfs: get root inode failed hfs: unable to locate alternate MDB hfs: get root inode failed hfs: continuing without an alternate MDB ================================================================== BUG: KASAN: out-of-bounds in memcpy include/linux/string.h:381 [inline] BUG: KASAN: out-of-bounds in hfs_bnode_read+0xbf/0xf0 fs/hfs/bnode.c:26 Read of size 2 at addr ffff8881b4d2cffe by task syz-executor/4289 CPU: 1 PID: 4289 Comm: syz-executor Not tainted 5.7.0-rc1-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:77 [inline] dump_stack+0x12f/0x187 lib/dump_stack.c:118 hfs: get root inode failed print_address_description.constprop.8+0x3b/0x60 mm/kasan/report.c:382 __kasan_report.cold.11+0x37/0x4e mm/kasan/report.c:511 kasan_report+0x38/0x50 mm/kasan/common.c:625 check_memory_region_inline mm/kasan/generic.c:187 [inline] check_memory_region+0x1cc/0x1f0 mm/kasan/generic.c:193 memcpy+0x23/0x60 mm/kasan/common.c:106 memcpy include/linux/string.h:381 [inline] hfs_bnode_read+0xbf/0xf0 fs/hfs/bnode.c:26 hfs_bnode_read_u16 fs/hfs/bnode.c:34 [inline] hfs_bnode_find+0x5ca/0xa20 fs/hfs/bnode.c:365 hfs_brec_find+0x27e/0x490 fs/hfs/bfind.c:114 hfs_brec_read+0x1d/0xe0 fs/hfs/bfind.c:153 hfs_cat_find_brec+0x142/0x310 fs/hfs/catalog.c:194 hfs_fill_super+0xabd/0x12a0 fs/hfs/super.c:420 mount_bdev+0x27b/0x340 fs/super.c:1417 hfs_mount+0x10/0x20 fs/hfs/super.c:457 legacy_get_tree+0x103/0x1f0 fs/fs_context.c:622 vfs_get_tree+0x8b/0x2d0 fs/super.c:1547 do_new_mount fs/namespace.c:2816 [inline] do_mount+0x1287/0x1c30 fs/namespace.c:3141 __do_sys_mount fs/namespace.c:3350 [inline] __se_sys_mount fs/namespace.c:3327 [inline] __x64_sys_mount+0x169/0x1c0 fs/namespace.c:3327 do_syscall_64+0xd0/0x630 arch/x86/entry/common.c:295 entry_SYSCALL_64_after_hwframe+0x49/0xb3 RIP: 0033:0x457efa Code: b8 a6 00 00 00 0f 05 48 3d 01 f0 ff ff 0f 83 dd 8f fb ff c3 66 2e 0f 1f 84 00 00 00 00 00 66 90 49 89 ca b8 a5 00 00 00 0f 05 <48> 3d 01 f0 ff ff 0f 83 ba 8f fb ff c3 66 0f 1f 84 00 00 00 00 00 RSP: 002b:00007f2f439ccba8 EFLAGS: 00000246 ORIG_RAX: 00000000000000a5 RAX: ffffffffffffffda RBX: 0000000020000000 RCX: 0000000000457efa RDX: 0000000020000000 RSI: 0000000020000100 RDI: 00007f2f439ccbf0 RBP: 0000000000000003 R08: 00000000200002c0 R09: 0000000020000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000003 R13: 0000000000000003 R14: 00000000006fcbb0 R15: 0000000000000000 The buggy address belongs to the page: page:ffffea0006d34b00 refcount:1 mapcount:1 mapping:00000000532aa398 index:0x103 anon flags: 0x2fffc0000080034(uptodate|lru|active|swapbacked) raw: 02fffc0000080034 ffffea0006d32b08 ffffea0006d358c8 ffff8881cd6be301 raw: 0000000000000103 0000000000000000 0000000100000000 ffff8881da264000 page dumped because: kasan: bad access detected page->mem_cgroup:ffff8881da264000 Memory state around the buggy address: ffff8881b4d2ce80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff8881b4d2cf00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff8881b4d2cf80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ^ ffff8881b4d2d000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff8881b4d2d080: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ==================================================================