================================================================== BUG: KASAN: use-after-free in copy_page_from_iter_atomic+0xab6/0x1520 lib/iov_iter.c:978 Read of size 4096 at addr ffff888059582000 by task kworker/u4:7/4580 CPU: 0 PID: 4580 Comm: kworker/u4:7 Not tainted 5.15.189-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/12/2025 Workqueue: loop5 loop_workfn Call Trace: dump_stack_lvl+0x168/0x230 lib/dump_stack.c:106 print_address_description+0x60/0x2d0 mm/kasan/report.c:248 __kasan_report mm/kasan/report.c:434 [inline] kasan_report+0xdf/0x130 mm/kasan/report.c:451 check_region_inline mm/kasan/generic.c:-1 [inline] kasan_check_range+0x27b/0x290 mm/kasan/generic.c:189 memcpy+0x25/0x60 mm/kasan/shadow.c:65 copy_page_from_iter_atomic+0xab6/0x1520 lib/iov_iter.c:978 generic_perform_write+0x2ff/0x530 mm/filemap.c:3793 __generic_file_write_iter+0x25f/0x4e0 mm/filemap.c:3912 generic_file_write_iter+0xa6/0x1b0 mm/filemap.c:3944 do_iter_readv_writev+0x497/0x600 fs/read_write.c:-1 do_iter_write+0x205/0x7b0 fs/read_write.c:855 lo_write_bvec+0x299/0x770 drivers/block/loop.c:316 lo_write_simple drivers/block/loop.c:338 [inline] do_req_filebacked drivers/block/loop.c:656 [inline] loop_handle_cmd drivers/block/loop.c:2235 [inline] loop_process_work+0x1d62/0x2480 drivers/block/loop.c:2275 process_one_work+0x863/0x1000 kernel/workqueue.c:2310 worker_thread+0xaa8/0x12a0 kernel/workqueue.c:2457 kthread+0x436/0x520 kernel/kthread.c:334 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:287 The buggy address belongs to the page: page:ffffea0001656080 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x59582 memcg:ffff888029f3bd82 flags: 0xfff00000000000(node=0|zone=1|lastcpupid=0x7ff) raw: 00fff00000000000 0000000000000000 dead000000000122 0000000000000000 raw: 0000000000000000 0000000000000000 00000001ffffffff ffff888029f3bd82 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 0, migratetype Unmovable, gfp_mask 0x102dc2(GFP_HIGHUSER|__GFP_NOWARN|__GFP_ZERO), pid 5740, ts 119736219678, free_ts 119689889032 prep_new_page mm/page_alloc.c:2426 [inline] get_page_from_freelist+0x1b77/0x1c60 mm/page_alloc.c:4192 __alloc_pages+0x1e1/0x470 mm/page_alloc.c:5474 vm_area_alloc_pages mm/vmalloc.c:2869 [inline] __vmalloc_area_node mm/vmalloc.c:2925 [inline] __vmalloc_node_range+0x4b2/0x8b0 mm/vmalloc.c:3030 alloc_thread_stack_node kernel/fork.c:246 [inline] dup_task_struct+0x3f5/0xb30 kernel/fork.c:899 copy_process+0x5b3/0x3e00 kernel/fork.c:2121 kernel_clone+0x219/0x930 kernel/fork.c:2679 __do_sys_clone3 kernel/fork.c:2954 [inline] __se_sys_clone3+0x2d5/0x360 kernel/fork.c:2938 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x66/0xd0 page last free stack trace: reset_page_owner include/linux/page_owner.h:24 [inline] free_pages_prepare mm/page_alloc.c:1340 [inline] free_pcp_prepare mm/page_alloc.c:1391 [inline] free_unref_page_prepare+0x637/0x6c0 mm/page_alloc.c:3317 free_unref_page+0x94/0x280 mm/page_alloc.c:3396 lbmLogShutdown fs/jfs/jfs_logmgr.c:1872 [inline] lmLogShutdown+0x436/0x820 fs/jfs/jfs_logmgr.c:1692 lmLogClose+0x286/0x520 fs/jfs/jfs_logmgr.c:1468 jfs_umount+0x28f/0x360 fs/jfs/jfs_umount.c:116 jfs_put_super+0x88/0x190 fs/jfs/super.c:194 generic_shutdown_super+0x130/0x300 fs/super.c:475 kill_block_super+0x7c/0xe0 fs/super.c:1427 deactivate_locked_super+0x93/0xf0 fs/super.c:335 cleanup_mnt+0x418/0x4d0 fs/namespace.c:1139 task_work_run+0x125/0x1a0 kernel/task_work.c:188 tracehook_notify_resume include/linux/tracehook.h:189 [inline] exit_to_user_mode_loop+0x10f/0x130 kernel/entry/common.c:181 exit_to_user_mode_prepare+0xb1/0x140 kernel/entry/common.c:214 __syscall_exit_to_user_mode_work kernel/entry/common.c:296 [inline] syscall_exit_to_user_mode+0x16/0x40 kernel/entry/common.c:307 do_syscall_64+0x58/0xa0 arch/x86/entry/common.c:86 entry_SYSCALL_64_after_hwframe+0x66/0xd0 Memory state around the buggy address: ffff888059581f00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff888059581f80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff888059582000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ^ ffff888059582080: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff888059582100: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ==================================================================