R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000001 R13: 0000000000000000 R14: 00007febfe575fa0 R15: 00007ffd020e37d8 ================================================================== BUG: KASAN: stack-out-of-bounds in iov_iter_revert+0x47f/0x590 lib/iov_iter.c:648 Read of size 8 at addr ffffc9000bba7c98 by task syz.5.317/7611 CPU: 1 UID: 0 PID: 7611 Comm: syz.5.317 Not tainted 6.13.0-rc6-syzkaller-00036-gfbfd64d25c7a #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024 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:378 [inline] print_report+0x169/0x550 mm/kasan/report.c:489 kasan_report+0x143/0x180 mm/kasan/report.c:602 iov_iter_revert+0x47f/0x590 lib/iov_iter.c:648 fuse_direct_io+0x30b3/0x31f0 fs/fuse/file.c:1667 fuse_direct_write_iter fs/fuse/file.c:1742 [inline] fuse_file_write_iter+0xae2/0xf70 fs/fuse/file.c:1787 do_iter_readv_writev+0x602/0x880 vfs_writev+0x376/0xba0 fs/read_write.c:1050 do_writev+0x1b6/0x360 fs/read_write.c:1096 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 RIP: 0033:0x7febfe385d29 Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 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 a8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007febff141038 EFLAGS: 00000246 ORIG_RAX: 0000000000000014 RAX: ffffffffffffffda RBX: 00007febfe575fa0 RCX: 00007febfe385d29 RDX: 0000000000000002 RSI: 00000000200008c0 RDI: 0000000000000004 RBP: 00007febff141090 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000001 R13: 0000000000000000 R14: 00007febfe575fa0 R15: 00007ffd020e37d8 The buggy address belongs to stack of task syz.5.317/7611 and is located at offset 24 in frame: vfs_writev+0x0/0xba0 This frame has 3 objects: [32, 160) 'iovstack' [192, 200) 'iov' [224, 264) 'iter' The buggy address belongs to the virtual mapping at [ffffc9000bba0000, ffffc9000bba9000) created by: copy_process+0x5d1/0x3d50 kernel/fork.c:2224 The buggy address belongs to the physical page: page: refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x33d63 memcg:ffff88814c70dc82 flags: 0xfff00000000000(node=0|zone=1|lastcpupid=0x7ff) raw: 00fff00000000000 0000000000000000 dead000000000122 0000000000000000 raw: 0000000000000000 0000000000000000 00000001ffffffff ffff88814c70dc82 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 2, tgid 2 (kthreadd), ts 196119212011, free_ts 193057704973 set_page_owner include/linux/page_owner.h:32 [inline] post_alloc_hook+0x1f3/0x230 mm/page_alloc.c:1558 prep_new_page mm/page_alloc.c:1566 [inline] get_page_from_freelist+0x365c/0x37a0 mm/page_alloc.c:3476 __alloc_pages_noprof+0x292/0x710 mm/page_alloc.c:4753 alloc_pages_mpol_noprof+0x3e8/0x680 mm/mempolicy.c:2269 vm_area_alloc_pages mm/vmalloc.c:3591 [inline] __vmalloc_area_node mm/vmalloc.c:3669 [inline] __vmalloc_node_range_noprof+0x9c9/0x1380 mm/vmalloc.c:3846 alloc_thread_stack_node kernel/fork.c:314 [inline] dup_task_struct+0x444/0x8c0 kernel/fork.c:1116 copy_process+0x5d1/0x3d50 kernel/fork.c:2224 kernel_clone+0x226/0x8e0 kernel/fork.c:2806 kernel_thread+0x1bc/0x240 kernel/fork.c:2868 create_kthread kernel/kthread.c:412 [inline] kthreadd+0x60d/0x810 kernel/kthread.c:767 ret_from_fork+0x4d/0x80 arch/x86/kernel/process.c:147 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244 page last free pid 5947 tgid 5947 stack trace: reset_page_owner include/linux/page_owner.h:25 [inline] free_pages_prepare mm/page_alloc.c:1127 [inline] free_unref_page+0xd3f/0x1010 mm/page_alloc.c:2659 kasan_depopulate_vmalloc_pte+0x74/0x90 mm/kasan/shadow.c:408 apply_to_pte_range mm/memory.c:2831 [inline] apply_to_pmd_range mm/memory.c:2875 [inline] apply_to_pud_range mm/memory.c:2911 [inline] apply_to_p4d_range mm/memory.c:2947 [inline] __apply_to_page_range+0x808/0xde0 mm/memory.c:2981 kasan_release_vmalloc+0xa5/0xd0 mm/kasan/shadow.c:529 kasan_release_vmalloc_node mm/vmalloc.c:2196 [inline] purge_vmap_node+0x22f/0x8d0 mm/vmalloc.c:2213 __purge_vmap_area_lazy+0x708/0xae0 mm/vmalloc.c:2304 drain_vmap_area_work+0x27/0x40 mm/vmalloc.c:2338 process_one_work kernel/workqueue.c:3229 [inline] process_scheduled_works+0xa68/0x1840 kernel/workqueue.c:3310 worker_thread+0x870/0xd30 kernel/workqueue.c:3391 kthread+0x2f2/0x390 kernel/kthread.c:389 ret_from_fork+0x4d/0x80 arch/x86/kernel/process.c:147 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244 Memory state around the buggy address: ffffc9000bba7b80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffffc9000bba7c00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffffc9000bba7c80: f1 f1 f1 f1 00 00 00 00 00 00 00 00 00 00 00 00 ^ ffffc9000bba7d00: 00 00 00 00 f2 f2 f2 f2 00 f2 f2 f2 00 00 00 00 ffffc9000bba7d80: 00 f3 f3 f3 f3 f3 f3 f3 00 00 00 00 00 00 00 00 ==================================================================