================================================================== BUG: KASAN: vmalloc-out-of-bounds in fb_write_offset drivers/video/fbdev/core/sysmem.h:30 [inline] BUG: KASAN: vmalloc-out-of-bounds in bitfill drivers/video/fbdev/core/fb_fillrect.h:133 [inline] BUG: KASAN: vmalloc-out-of-bounds in fb_fillrect_static drivers/video/fbdev/core/fb_fillrect.h:219 [inline] BUG: KASAN: vmalloc-out-of-bounds in fb_fillrect drivers/video/fbdev/core/fb_fillrect.h:278 [inline] BUG: KASAN: vmalloc-out-of-bounds in sys_fillrect+0x15d4/0x17b0 drivers/video/fbdev/core/sysfillrect.c:24 Write of size 8 at addr ffffc900051f1000 by task syz.1.1259/10494 CPU: 2 UID: 0 PID: 10494 Comm: syz.1.1259 Not tainted syzkaller #0 PREEMPT(full) 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+0x116/0x1f0 lib/dump_stack.c:120 print_address_description mm/kasan/report.c:378 [inline] print_report+0xcd/0x630 mm/kasan/report.c:482 kasan_report+0xe0/0x110 mm/kasan/report.c:595 fb_write_offset drivers/video/fbdev/core/sysmem.h:30 [inline] bitfill drivers/video/fbdev/core/fb_fillrect.h:133 [inline] fb_fillrect_static drivers/video/fbdev/core/fb_fillrect.h:219 [inline] fb_fillrect drivers/video/fbdev/core/fb_fillrect.h:278 [inline] sys_fillrect+0x15d4/0x17b0 drivers/video/fbdev/core/sysfillrect.c:24 drm_fbdev_shmem_defio_fillrect+0x22/0x140 drivers/gpu/drm/drm_fbdev_shmem.c:38 bit_clear+0x17d/0x220 drivers/video/fbdev/core/bitblit.c:73 __fbcon_clear+0x603/0x720 drivers/video/fbdev/core/fbcon.c:1303 fbcon_scroll+0x48b/0x640 drivers/video/fbdev/core/fbcon.c:1863 con_scroll+0x45f/0x690 drivers/tty/vt/vt.c:588 csi_M drivers/tty/vt/vt.c:2140 [inline] csi_ECMA drivers/tty/vt/vt.c:2559 [inline] do_con_trol drivers/tty/vt/vt.c:2733 [inline] do_con_write+0x5575/0x8290 drivers/tty/vt/vt.c:3228 con_write+0x23/0xb0 drivers/tty/vt/vt.c:3565 process_output_block drivers/tty/n_tty.c:561 [inline] n_tty_write+0x41e/0x11e0 drivers/tty/n_tty.c:2377 iterate_tty_write drivers/tty/tty_io.c:1006 [inline] file_tty_write.constprop.0+0x503/0x9b0 drivers/tty/tty_io.c:1081 new_sync_write fs/read_write.c:593 [inline] vfs_write+0x7d3/0x11d0 fs/read_write.c:686 ksys_write+0x12a/0x250 fs/read_write.c:738 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xcd/0xfa0 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7fb68ab8efc9 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:00007fb68b9dc038 EFLAGS: 00000246 ORIG_RAX: 0000000000000001 RAX: ffffffffffffffda RBX: 00007fb68ade6090 RCX: 00007fb68ab8efc9 RDX: 0000000000001006 RSI: 0000200000001040 RDI: 0000000000000009 RBP: 00007fb68ac11f91 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 00007fb68ade6128 R14: 00007fb68ade6090 R15: 00007ffc39fb3248 The buggy address belongs to a 0-page vmalloc region starting at 0xffffc90004ef1000 allocated at drm_gem_shmem_vmap_locked+0x561/0x7e0 drivers/gpu/drm/drm_gem_shmem_helper.c:371 Memory state around the buggy address: ffffc900051f0f00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffffc900051f0f80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffffc900051f1000: f8 f8 f8 f8 f8 f8 f8 f8 f8 f8 f8 f8 f8 f8 f8 f8 ^ ffffc900051f1080: f8 f8 f8 f8 f8 f8 f8 f8 f8 f8 f8 f8 f8 f8 f8 f8 ffffc900051f1100: f8 f8 f8 f8 f8 f8 f8 f8 f8 f8 f8 f8 f8 f8 f8 f8 ==================================================================