================================================================== BUG: KASAN: slab-out-of-bounds in scr_memcpyw include/linux/vt_buffer.h:49 [inline] BUG: KASAN: slab-out-of-bounds in vc_do_resize+0xe3e/0x1ce0 drivers/tty/vt/vt.c:1280 Read of size 4 at addr ffff88808f901d80 by task syz-executor.0/4524 CPU: 0 PID: 4524 Comm: syz-executor.0 Not tainted 5.7.0-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+0x1e9/0x30e lib/dump_stack.c:118 print_address_description+0x66/0x5a0 mm/kasan/report.c:383 __kasan_report mm/kasan/report.c:513 [inline] kasan_report+0x132/0x1d0 mm/kasan/report.c:530 check_memory_region_inline mm/kasan/generic.c:183 [inline] check_memory_region+0x2b5/0x2f0 mm/kasan/generic.c:192 memcpy+0x25/0x60 mm/kasan/common.c:105 scr_memcpyw include/linux/vt_buffer.h:49 [inline] vc_do_resize+0xe3e/0x1ce0 drivers/tty/vt/vt.c:1280 fbcon_modechanged+0x710/0xd90 drivers/video/fbdev/core/fbcon.c:2989 fb_set_var+0x822/0xcc0 drivers/video/fbdev/core/fbmem.c:1056 do_fb_ioctl+0x502/0x6f0 drivers/video/fbdev/core/fbmem.c:1109 vfs_ioctl fs/ioctl.c:47 [inline] ksys_ioctl fs/ioctl.c:771 [inline] __do_sys_ioctl fs/ioctl.c:780 [inline] __se_sys_ioctl+0xf9/0x160 fs/ioctl.c:778 do_syscall_64+0xf3/0x1b0 arch/x86/entry/common.c:295 entry_SYSCALL_64_after_hwframe+0x49/0xb3 RIP: 0033:0x45ca69 Code: 0d b7 fb ff c3 66 2e 0f 1f 84 00 00 00 00 00 66 90 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 0f 83 db b6 fb ff c3 66 2e 0f 1f 84 00 00 00 00 RSP: 002b:00007ff668988c78 EFLAGS: 00000246 ORIG_RAX: 0000000000000010 RAX: ffffffffffffffda RBX: 00000000004e4b00 RCX: 000000000045ca69 RDX: 0000000020000000 RSI: 0000000000004601 RDI: 0000000000000003 RBP: 000000000078bf00 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 00000000ffffffff R13: 00000000000002f2 R14: 00000000004c5708 R15: 00007ff6689896d4 Allocated by task 4524: save_stack mm/kasan/common.c:48 [inline] set_track mm/kasan/common.c:56 [inline] __kasan_kmalloc+0x103/0x140 mm/kasan/common.c:494 __do_kmalloc mm/slab.c:3656 [inline] __kmalloc+0x24b/0x330 mm/slab.c:3665 kmalloc include/linux/slab.h:560 [inline] kzalloc+0x1d/0x40 include/linux/slab.h:669 vc_do_resize+0x2a0/0x1ce0 drivers/tty/vt/vt.c:1217 fbcon_modechanged+0x710/0xd90 drivers/video/fbdev/core/fbcon.c:2989 fb_set_var+0x822/0xcc0 drivers/video/fbdev/core/fbmem.c:1056 fbcon_resize+0x7bb/0xff0 drivers/video/fbdev/core/fbcon.c:2231 resize_screen drivers/tty/vt/vt.c:1156 [inline] vc_do_resize+0x70a/0x1ce0 drivers/tty/vt/vt.c:1235 fbcon_modechanged+0x710/0xd90 drivers/video/fbdev/core/fbcon.c:2989 fb_set_var+0x822/0xcc0 drivers/video/fbdev/core/fbmem.c:1056 do_fb_ioctl+0x502/0x6f0 drivers/video/fbdev/core/fbmem.c:1109 vfs_ioctl fs/ioctl.c:47 [inline] ksys_ioctl fs/ioctl.c:771 [inline] __do_sys_ioctl fs/ioctl.c:780 [inline] __se_sys_ioctl+0xf9/0x160 fs/ioctl.c:778 do_syscall_64+0xf3/0x1b0 arch/x86/entry/common.c:295 entry_SYSCALL_64_after_hwframe+0x49/0xb3 Freed by task 166: save_stack mm/kasan/common.c:48 [inline] set_track mm/kasan/common.c:56 [inline] kasan_set_free_info mm/kasan/common.c:316 [inline] __kasan_slab_free+0x114/0x170 mm/kasan/common.c:455 __cache_free mm/slab.c:3426 [inline] kfree+0x10a/0x220 mm/slab.c:3757 process_one_work+0x76e/0xfd0 kernel/workqueue.c:2268 worker_thread+0xa7f/0x1450 kernel/workqueue.c:2414 kthread+0x353/0x380 kernel/kthread.c:268 ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:351 The buggy address belongs to the object at ffff88808f901c00 which belongs to the cache kmalloc-512 of size 512 The buggy address is located 384 bytes inside of 512-byte region [ffff88808f901c00, ffff88808f901e00) The buggy address belongs to the page: page:ffffea00023e4040 refcount:1 mapcount:0 mapping:0000000000000000 index:0xffff88808f901000 flags: 0xfffe0000000200(slab) raw: 00fffe0000000200 ffffea0002404c08 ffffea00029c5e08 ffff8880aa400a80 raw: ffff88808f901000 ffff88808f901000 0000000100000003 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff88808f901c80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff88808f901d00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff88808f901d80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff88808f901e00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff88808f901e80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ==================================================================