================================================================== BUG: KASAN: slab-out-of-bounds in memcpy include/linux/string.h:377 [inline] BUG: KASAN: slab-out-of-bounds in soft_cursor+0x44b/0xa30 drivers/video/fbdev/core/softcursor.c:70 Read of size 4 at addr ffff8880aac1342c by task kworker/0:2/4384 CPU: 0 PID: 4384 Comm: kworker/0:2 Not tainted 4.19.184-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Workqueue: events_power_efficient fb_flashcursor Call Trace: __dump_stack lib/dump_stack.c:77 [inline] dump_stack+0x1fc/0x2ef lib/dump_stack.c:118 print_address_description.cold+0x54/0x219 mm/kasan/report.c:256 kasan_report_error.cold+0x8a/0x1b9 mm/kasan/report.c:354 kasan_report+0x8f/0xa0 mm/kasan/report.c:412 memcpy+0x20/0x50 mm/kasan/kasan.c:302 memcpy include/linux/string.h:377 [inline] soft_cursor+0x44b/0xa30 drivers/video/fbdev/core/softcursor.c:70 bit_cursor+0x1126/0x1740 drivers/video/fbdev/core/bitblit.c:377 fb_flashcursor+0x38c/0x430 drivers/video/fbdev/core/fbcon.c:379 process_one_work+0x864/0x1570 kernel/workqueue.c:2152 worker_thread+0x64c/0x1130 kernel/workqueue.c:2295 kthread+0x33f/0x460 kernel/kthread.c:259 ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:415 Allocated by task 16481: __do_kmalloc mm/slab.c:3727 [inline] __kmalloc+0x15a/0x3c0 mm/slab.c:3736 kmalloc include/linux/slab.h:520 [inline] fbcon_set_font+0x34f/0x8a0 drivers/video/fbdev/core/fbcon.c:2479 con_font_set drivers/tty/vt/vt.c:4537 [inline] con_font_op+0x94b/0xf20 drivers/tty/vt/vt.c:4581 vt_ioctl+0x116b/0x2380 drivers/tty/vt/vt_ioctl.c:938 tty_ioctl+0x5b0/0x15c0 drivers/tty/tty_io.c:2669 vfs_ioctl fs/ioctl.c:46 [inline] file_ioctl fs/ioctl.c:501 [inline] do_vfs_ioctl+0xcdb/0x12e0 fs/ioctl.c:688 ksys_ioctl+0x9b/0xc0 fs/ioctl.c:705 __do_sys_ioctl fs/ioctl.c:712 [inline] __se_sys_ioctl fs/ioctl.c:710 [inline] __x64_sys_ioctl+0x6f/0xb0 fs/ioctl.c:710 do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe Freed by task 18: __cache_free mm/slab.c:3503 [inline] kfree+0xcc/0x210 mm/slab.c:3822 skb_free_head net/core/skbuff.c:563 [inline] skb_release_data+0x6de/0x920 net/core/skbuff.c:583 skb_release_all net/core/skbuff.c:640 [inline] __kfree_skb net/core/skbuff.c:654 [inline] kfree_skb+0x11a/0x3d0 net/core/skbuff.c:672 ip6_mc_input+0x826/0xa80 net/ipv6/ip6_input.c:518 dst_input include/net/dst.h:461 [inline] ip6_rcv_finish+0x1d9/0x2f0 net/ipv6/ip6_input.c:76 NF_HOOK include/linux/netfilter.h:289 [inline] ipv6_rcv+0xf2/0x3f0 net/ipv6/ip6_input.c:283 __netif_receive_skb_one_core+0x114/0x180 net/core/dev.c:4954 __netif_receive_skb+0x27/0x1c0 net/core/dev.c:5066 netif_receive_skb_internal+0xf0/0x3f0 net/core/dev.c:5156 ieee80211_deliver_skb_to_local_stack net/mac80211/rx.c:2410 [inline] ieee80211_deliver_skb+0x8cb/0xa70 net/mac80211/rx.c:2499 ieee80211_rx_h_data net/mac80211/rx.c:2834 [inline] ieee80211_rx_handlers+0x2967/0xa630 net/mac80211/rx.c:3604 ieee80211_invoke_rx_handlers net/mac80211/rx.c:3645 [inline] ieee80211_prepare_and_rx_handle+0x23ed/0x6780 net/mac80211/rx.c:4342 __ieee80211_rx_handle_packet net/mac80211/rx.c:4402 [inline] ieee80211_rx_napi+0x108d/0x2470 net/mac80211/rx.c:4591 ieee80211_rx include/net/mac80211.h:4109 [inline] ieee80211_tasklet_handler+0x101/0x160 net/mac80211/main.c:229 tasklet_action_common.constprop.0+0x265/0x360 kernel/softirq.c:522 __do_softirq+0x265/0x980 kernel/softirq.c:292 The buggy address belongs to the object at ffff8880aac132c0 which belongs to the cache kmalloc-512 of size 512 The buggy address is located 364 bytes inside of 512-byte region [ffff8880aac132c0, ffff8880aac134c0) The buggy address belongs to the page: page:ffffea0002ab04c0 count:1 mapcount:0 mapping:ffff88813bff0940 index:0xffff8880aac13cc0 flags: 0xfff00000000100(slab) raw: 00fff00000000100 ffffea0002578c88 ffffea000296a608 ffff88813bff0940 raw: ffff8880aac13cc0 ffff8880aac13040 0000000100000004 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff8880aac13300: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff8880aac13380: 00 00 00 00 00 00 00 00 00 00 fc fc fc fc fc fc >ffff8880aac13400: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff8880aac13480: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff8880aac13500: fc fc fc fc fc fc fc fc fb fb fb fb fb fb fb fb ==================================================================