================================================================== BUG: KASAN: use-after-free in memcpy include/linux/string.h:376 [inline] BUG: KASAN: use-after-free in memcpy_from_page+0x8c/0x110 lib/iov_iter.c:453 Read of size 4096 at addr ffff8880ab3ea000 by task loop3/16850 CPU: 1 PID: 16850 Comm: loop3 Not tainted 4.14.256-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:17 [inline] dump_stack+0x1b2/0x281 lib/dump_stack.c:58 print_address_description.cold+0x54/0x1d3 mm/kasan/report.c:252 kasan_report_error.cold+0x8a/0x191 mm/kasan/report.c:351 kasan_report+0x6f/0x80 mm/kasan/report.c:409 memcpy+0x20/0x50 mm/kasan/kasan.c:302 memcpy include/linux/string.h:376 [inline] memcpy_from_page+0x8c/0x110 lib/iov_iter.c:453 iov_iter_copy_from_user_atomic+0x5dc/0xa20 lib/iov_iter.c:799 generic_perform_write+0x21f/0x420 mm/filemap.c:3063 __generic_file_write_iter+0x227/0x590 mm/filemap.c:3180 generic_file_write_iter+0x36f/0x650 mm/filemap.c:3208 call_write_iter include/linux/fs.h:1778 [inline] do_iter_readv_writev+0x4cf/0x5f0 fs/read_write.c:675 do_iter_write+0x152/0x550 fs/read_write.c:954 vfs_iter_write+0x70/0xa0 fs/read_write.c:967 lo_write_bvec+0x114/0x310 drivers/block/loop.c:272 lo_write_simple drivers/block/loop.c:294 [inline] do_req_filebacked drivers/block/loop.c:587 [inline] loop_handle_cmd drivers/block/loop.c:1779 [inline] loop_queue_work+0x9f2/0x21e0 drivers/block/loop.c:1793 kthread_worker_fn+0x271/0x6c0 kernel/kthread.c:667 kthread+0x30d/0x420 kernel/kthread.c:232 ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:404 The buggy address belongs to the page: page:ffffea0002acfa80 count:1 mapcount:0 mapping: (null) index:0x0 flags: 0xfff00000000000() raw: 00fff00000000000 0000000000000000 0000000000000000 00000001ffffffff raw: dead000000000100 dead000000000200 0000000000000000 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff8880ab3e9f00: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff8880ab3e9f80: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff >ffff8880ab3ea000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ^ ffff8880ab3ea080: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff8880ab3ea100: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ==================================================================