================================================================== BUG: KASAN: slab-out-of-bounds in memcpy include/linux/fortify-string.h:225 [inline] BUG: KASAN: slab-out-of-bounds in usb_hcd_poll_rh_status+0x376/0x780 drivers/usb/core/hcd.c:774 Write of size 2 at addr ffff88814811d370 by task rs:main Q:Reg/6185 CPU: 1 PID: 6185 Comm: rs:main Q:Reg Not tainted 5.15.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:88 [inline] dump_stack_lvl+0xcd/0x134 lib/dump_stack.c:106 print_address_description.constprop.0.cold+0x6c/0x30c mm/kasan/report.c:256 __kasan_report mm/kasan/report.c:442 [inline] kasan_report.cold+0x83/0xdf mm/kasan/report.c:459 check_region_inline mm/kasan/generic.c:183 [inline] kasan_check_range+0x13d/0x180 mm/kasan/generic.c:189 memcpy+0x39/0x60 mm/kasan/shadow.c:66 memcpy include/linux/fortify-string.h:225 [inline] usb_hcd_poll_rh_status+0x376/0x780 drivers/usb/core/hcd.c:774 call_timer_fn+0x1a5/0x6b0 kernel/time/timer.c:1421 expire_timers kernel/time/timer.c:1466 [inline] __run_timers.part.0+0x675/0xa20 kernel/time/timer.c:1734 __run_timers kernel/time/timer.c:1715 [inline] run_timer_softirq+0xb3/0x1d0 kernel/time/timer.c:1747 __do_softirq+0x29b/0x9c2 kernel/softirq.c:558 invoke_softirq kernel/softirq.c:432 [inline] __irq_exit_rcu+0x123/0x180 kernel/softirq.c:636 irq_exit_rcu+0x5/0x20 kernel/softirq.c:648 sysvec_apic_timer_interrupt+0x45/0xc0 arch/x86/kernel/apic/apic.c:1097 asm_sysvec_apic_timer_interrupt+0x12/0x20 arch/x86/include/asm/idtentry.h:638 RIP: 0033:0x55cba945a044 Code: 41 8b 47 08 49 39 c5 72 13 4c 89 ee 4c 89 ff e8 82 09 ff ff 85 c0 0f 85 b9 00 00 00 49 8b 16 49 8b 07 48 8b 74 24 08 48 89 10 <41> 8b 56 08 89 50 08 41 0f b7 56 0c 66 89 50 0c 41 0f b6 56 0e 88 RSP: 002b:00007fcc03ffe810 EFLAGS: 00000287 RAX: 00007fcbf4031140 RBX: 0000000000000009 RCX: 0000000000000000 RDX: 3020382020766f4e RSI: 00007fcc04008c25 RDI: 00007fcc04008a80 RBP: 00007fcc04008bc0 R08: 0000000000000000 R09: 0000000000000000 R10: 000055cba9697280 R11: 0000000000000000 R12: 0000000000000032 R13: 0000000000000056 R14: 00007fcc04008c78 R15: 00007fcbf401a570 Allocated by task 15415: kasan_save_stack+0x1e/0x50 mm/kasan/common.c:38 kasan_set_track mm/kasan/common.c:46 [inline] set_alloc_info mm/kasan/common.c:434 [inline] ____kasan_kmalloc mm/kasan/common.c:513 [inline] ____kasan_kmalloc mm/kasan/common.c:472 [inline] __kasan_kmalloc+0xa9/0xd0 mm/kasan/common.c:522 kmalloc include/linux/slab.h:595 [inline] proc_do_submiturb+0x2a7d/0x3630 drivers/usb/core/devio.c:1816 proc_submiturb drivers/usb/core/devio.c:1975 [inline] usbdev_do_ioctl drivers/usb/core/devio.c:2671 [inline] usbdev_ioctl+0x692/0x36c0 drivers/usb/core/devio.c:2791 vfs_ioctl fs/ioctl.c:51 [inline] __do_sys_ioctl fs/ioctl.c:874 [inline] __se_sys_ioctl fs/ioctl.c:860 [inline] __x64_sys_ioctl+0x193/0x200 fs/ioctl.c:860 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x44/0xae The buggy address belongs to the object at ffff88814811d370 which belongs to the cache kmalloc-8 of size 8 The buggy address is located 0 bytes inside of 8-byte region [ffff88814811d370, ffff88814811d378) The buggy address belongs to the page: page:ffffea0005204740 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x14811d flags: 0x57ff00000000200(slab|node=1|zone=2|lastcpupid=0x7ff) raw: 057ff00000000200 dead000000000100 dead000000000122 ffff888010c41280 raw: 0000000000000000 0000000080660066 00000001ffffffff 0000000000000000 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 0, migratetype Unmovable, gfp_mask 0x12cc0(GFP_KERNEL|__GFP_NOWARN|__GFP_NORETRY), pid 1, ts 9038153591, free_ts 0 prep_new_page mm/page_alloc.c:2418 [inline] get_page_from_freelist+0xa72/0x2f50 mm/page_alloc.c:4149 __alloc_pages+0x1b2/0x500 mm/page_alloc.c:5369 alloc_page_interleave+0x1e/0x200 mm/mempolicy.c:2036 alloc_pages+0x29f/0x300 mm/mempolicy.c:2186 alloc_slab_page mm/slub.c:1793 [inline] allocate_slab mm/slub.c:1930 [inline] new_slab+0x32d/0x4a0 mm/slub.c:1993 ___slab_alloc+0x918/0xfe0 mm/slub.c:3022 __slab_alloc.constprop.0+0x4d/0xa0 mm/slub.c:3109 slab_alloc_node mm/slub.c:3200 [inline] slab_alloc mm/slub.c:3242 [inline] __kmalloc_track_caller+0x2e7/0x320 mm/slub.c:4925 kvasprintf+0xb5/0x150 lib/kasprintf.c:25 kvasprintf_const+0x60/0x190 lib/kasprintf.c:49 kobject_set_name_vargs+0x56/0x150 lib/kobject.c:289 dev_set_name+0xbb/0xf0 drivers/base/core.c:3182 usb_create_ep_devs+0x154/0x2a0 drivers/usb/core/endpoint.c:167 create_intf_ep_devs.isra.0+0x158/0x1f0 drivers/usb/core/message.c:1253 usb_set_configuration+0x1040/0x1900 drivers/usb/core/message.c:2176 usb_generic_driver_probe+0xba/0x100 drivers/usb/core/generic.c:238 page_owner free stack trace missing Memory state around the buggy address: ffff88814811d200: fc 00 fc fc fc fc fa fc fc fc fc 00 fc fc fc fc ffff88814811d280: 00 fc fc fc fc fb fc fc fc fc fa fc fc fc fc 00 >ffff88814811d300: fc fc fc fc 00 fc fc fc fc 00 fc fc fc fc 01 fc ^ ffff88814811d380: fc fc fc 00 fc fc fc fc 00 fc fc fc fc 00 fc fc ffff88814811d400: fc fc 00 fc fc fc fc fb fc fc fc fc fa fc fc fc ==================================================================