loop0: detected capacity change from 0 to 4096 ntfs3(loop0): Failed to load $UpCase (-22). ================================================================== BUG: KASAN: stack-out-of-bounds in find_lock_entries+0x11b/0xbb0 mm/filemap.c:2115 Read of size 8 at addr ffffc9000dccf9df by task syz.0.2983/12256 CPU: 0 UID: 0 PID: 12256 Comm: syz.0.2983 Not tainted 6.14.0-rc5-syzkaller-g7eb172143d55 #0 Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2~bpo12+1 04/01/2014 Call Trace: __dump_stack lib/dump_stack.c:94 [inline] dump_stack_lvl+0x241/0x360 lib/dump_stack.c:120 print_address_description mm/kasan/report.c:408 [inline] print_report+0x16e/0x5b0 mm/kasan/report.c:521 kasan_report+0x143/0x180 mm/kasan/report.c:634 find_lock_entries+0x11b/0xbb0 mm/filemap.c:2115 shmem_undo_range+0x2d4/0x1820 mm/shmem.c:1094 shmem_truncate_range mm/shmem.c:1224 [inline] shmem_evict_inode+0x29b/0xa80 mm/shmem.c:1352 evict+0x4e8/0x9a0 fs/inode.c:796 __dentry_kill+0x20d/0x630 fs/dcache.c:643 dput+0x19f/0x2b0 fs/dcache.c:885 __fput+0x60b/0x9f0 fs/file_table.c:472 task_work_run+0x24f/0x310 kernel/task_work.c:227 resume_user_mode_work include/linux/resume_user_mode.h:50 [inline] exit_to_user_mode_loop kernel/entry/common.c:114 [inline] exit_to_user_mode_prepare include/linux/entry-common.h:329 [inline] __syscall_exit_to_user_mode_work kernel/entry/common.c:207 [inline] syscall_exit_to_user_mode+0x13f/0x340 kernel/entry/common.c:218 do_syscall_64+0x100/0x230 arch/x86/entry/common.c:89 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7f02ccb8ba4a Code: 48 3d 00 f0 ff ff 77 48 c3 0f 1f 80 00 00 00 00 48 83 ec 18 89 7c 24 0c e8 43 91 02 00 8b 7c 24 0c 89 c2 b8 03 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 36 89 d7 89 44 24 0c e8 a3 91 02 00 8b 44 24 RSP: 002b:00007f02cd915e50 EFLAGS: 00000293 ORIG_RAX: 0000000000000003 RAX: 0000000000000000 RBX: ffffffffffffffff RCX: 00007f02ccb8ba4a RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000003 RBP: 0000000000000003 R08: 0000000000000000 R09: 0000000000000001 R10: 0000000000000000 R11: 0000000000000293 R12: 0000000000000016 R13: 00007f02cd915eb0 R14: 000000000001f768 R15: 0000400000000400 The buggy address belongs to stack of task syz.0.2983/12256 and is located at offset 671 in frame: shmem_undo_range+0x0/0x1820 This frame has 3 objects: [32, 288) 'fbatch' [352, 600) 'indices' [672, 680) 'index' The buggy address belongs to the virtual mapping at [ffffc9000dcc8000, ffffc9000dcd1000) created by: copy_process+0x5d1/0x3cf0 kernel/fork.c:2233 The buggy address belongs to the physical page: page: refcount:1 mapcount:0 mapping:0000000000000000 index:0x189 pfn:0x50ccb memcg:ffff888058a02302 flags: 0x4fff00000000000(node=1|zone=1|lastcpupid=0x7ff) raw: 04fff00000000000 0000000000000000 dead000000000122 0000000000000000 raw: 0000000000000189 0000000000000000 00000001ffffffff ffff888058a02302 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 0, migratetype Unmovable, gfp_mask 0x2dc2(GFP_KERNEL|__GFP_HIGHMEM|__GFP_NOWARN|__GFP_ZERO), pid 12156, tgid 12156 (syz.0.2935), ts 464094650453, free_ts 464031932524 set_page_owner include/linux/page_owner.h:32 [inline] post_alloc_hook+0x1f4/0x240 mm/page_alloc.c:1551 prep_new_page mm/page_alloc.c:1559 [inline] get_page_from_freelist+0x365c/0x37a0 mm/page_alloc.c:3477 __alloc_frozen_pages_noprof+0x292/0x710 mm/page_alloc.c:4739 alloc_pages_mpol+0x311/0x660 mm/mempolicy.c:2270 alloc_frozen_pages_noprof mm/mempolicy.c:2341 [inline] alloc_pages_noprof+0x121/0x190 mm/mempolicy.c:2361 vm_area_alloc_pages mm/vmalloc.c:3591 [inline] __vmalloc_area_node mm/vmalloc.c:3669 [inline] __vmalloc_node_range_noprof+0x9c6/0x1380 mm/vmalloc.c:3846 alloc_thread_stack_node kernel/fork.c:314 [inline] dup_task_struct+0x444/0x8c0 kernel/fork.c:1127 copy_process+0x5d1/0x3cf0 kernel/fork.c:2233 kernel_clone+0x226/0x8e0 kernel/fork.c:2815 __do_sys_clone3 kernel/fork.c:3119 [inline] __se_sys_clone3+0x2ee/0x380 kernel/fork.c:3098 do_syscall_x64 arch/x86/entry/common.c:52 [inline] do_syscall_64+0xf3/0x230 arch/x86/entry/common.c:83 entry_SYSCALL_64_after_hwframe+0x77/0x7f page last free pid 8 tgid 8 stack trace: create_dummy_stack mm/page_owner.c:94 [inline] register_dummy_stack+0x8a/0xe0 mm/page_owner.c:100 init_page_owner+0x3e/0x7a0 mm/page_owner.c:118 invoke_init_callbacks mm/page_ext.c:148 [inline] page_ext_init+0x731/0x790 mm/page_ext.c:497 mm_core_init+0x4c/0x60 mm/mm_init.c:2673 Memory state around the buggy address: ffffc9000dccf880: f2 f2 f2 f2 00 00 00 00 00 00 00 00 00 00 00 00 ffffc9000dccf900: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffffc9000dccf980: 00 00 00 f2 f2 f2 f2 f2 f2 f2 f2 f2 00 f3 f3 f3 ^ ffffc9000dccfa00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffffc9000dccfa80: 00 00 00 00 00 00 00 00 f1 f1 f1 f1 00 f2 f2 f2 ==================================================================