usb usb9: usbfs: process 23312 (syz-executor.5) did not claim interface 0 before use ================================================================== BUG: KASAN: slab-out-of-bounds in memcpy include/linux/string.h:377 [inline] BUG: KASAN: slab-out-of-bounds in usb_hcd_poll_rh_status+0x387/0x6f0 drivers/usb/core/hcd.c:771 Write of size 2 at addr ffff8880a02bb340 by task systemd-udevd/23315 CPU: 1 PID: 23315 Comm: systemd-udevd Not tainted 4.19.211-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: tmpfs: No value for mount option '' __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 IPVS: ftp: loaded support on port[0] = 21 memcpy+0x35/0x50 mm/kasan/kasan.c:303 memcpy include/linux/string.h:377 [inline] usb_hcd_poll_rh_status+0x387/0x6f0 drivers/usb/core/hcd.c:771 call_timer_fn+0x177/0x700 kernel/time/timer.c:1338 expire_timers+0x243/0x4e0 kernel/time/timer.c:1375 __run_timers kernel/time/timer.c:1696 [inline] run_timer_softirq+0x21c/0x670 kernel/time/timer.c:1709 __do_softirq+0x265/0x980 kernel/softirq.c:292 invoke_softirq kernel/softirq.c:372 [inline] irq_exit+0x215/0x260 kernel/softirq.c:412 exiting_irq arch/x86/include/asm/apic.h:536 [inline] smp_apic_timer_interrupt+0x136/0x550 arch/x86/kernel/apic/apic.c:1098 apic_timer_interrupt+0xf/0x20 arch/x86/entry/entry_64.S:894 RIP: 0010:deref_stack_reg+0x36/0x1d0 arch/x86/kernel/unwind_orc.c:330 Code: 41 55 49 89 d5 41 54 49 89 fc 55 48 89 f5 53 48 83 ec 68 48 c7 44 24 08 b3 8a b5 41 48 8d 5c 24 08 48 c7 44 24 10 35 af b6 89 <48> c1 eb 03 48 c7 44 24 18 20 7f 29 81 48 8d 14 03 c7 02 f1 f1 f1 RSP: 0018:ffff888045c1f928 EFLAGS: 00000296 ORIG_RAX: ffffffffffffff13 RAX: dffffc0000000000 RBX: ffff888045c1f930 RCX: ffff888045c1fe10 RDX: ffff888045c1fb38 RSI: ffff888045c1fe50 RDI: ffff888045c1faf0 RBP: ffff888045c1fe50 R08: ffffffff8b9b0a62 R09: ffffffff8b9b0a34 R10: ffff888045c1fb4f R11: 0000000000074071 R12: ffff888045c1faf0 R13: ffff888045c1fb38 R14: ffff888045c1faf0 R15: ffffffff8b9b0a5e unwind_next_frame+0x9fc/0x1400 arch/x86/kernel/unwind_orc.c:502 __save_stack_trace+0x9f/0x190 arch/x86/kernel/stacktrace.c:44 save_stack mm/kasan/kasan.c:448 [inline] set_track mm/kasan/kasan.c:460 [inline] kasan_kmalloc+0xeb/0x160 mm/kasan/kasan.c:553 kmem_cache_alloc+0x122/0x370 mm/slab.c:3559 getname_flags+0xce/0x590 fs/namei.c:140 do_sys_open+0x26c/0x520 fs/open.c:1079 do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe RIP: 0033:0x7f196accc6f0 Code: 00 f7 d8 64 89 01 48 83 c8 ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 83 3d 19 30 2c 00 00 75 10 b8 02 00 00 00 0f 05 <48> 3d 01 f0 ff ff 73 31 c3 48 83 ec 08 e8 fe 9d 01 00 48 89 04 24 RSP: 002b:00007fffdbecb8e8 EFLAGS: 00000246 ORIG_RAX: 0000000000000002 RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007f196accc6f0 RDX: 0000000000000180 RSI: 00000000000800c2 RDI: 00005641d6cb57c0 RBP: 000000000003a2f8 R08: 00007fffdbee7000 R09: 0000006e6dd8a70a R10: 00007fffdbecb910 R11: 0000000000000246 R12: 00005641d6cb57d5 R13: 8421084210842109 R14: 00000000000800c2 R15: 00007f196ad5a540 Allocated by task 23312: __do_kmalloc mm/slab.c:3727 [inline] __kmalloc+0x15a/0x3c0 mm/slab.c:3736 kmalloc include/linux/slab.h:520 [inline] proc_do_submiturb+0x2d17/0x3b00 drivers/usb/core/devio.c:1673 proc_submiturb drivers/usb/core/devio.c:1827 [inline] usbdev_do_ioctl+0x773/0x3030 drivers/usb/core/devio.c:2481 usbdev_ioctl+0x21/0x30 drivers/usb/core/devio.c:2585 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 22018: __cache_free mm/slab.c:3503 [inline] kfree+0xcc/0x210 mm/slab.c:3822 ovl_free_fs+0x4dc/0x7c0 fs/overlayfs/super.c:247 ovl_fill_super+0xa35/0x3f10 fs/overlayfs/super.c:1694 mount_nodev+0x60/0x110 fs/super.c:1204 mount_fs+0xa3/0x310 fs/super.c:1261 vfs_kern_mount.part.0+0x68/0x470 fs/namespace.c:961 vfs_kern_mount fs/namespace.c:951 [inline] do_new_mount fs/namespace.c:2492 [inline] do_mount+0x115c/0x2f50 fs/namespace.c:2822 ksys_mount+0xcf/0x130 fs/namespace.c:3038 __do_sys_mount fs/namespace.c:3052 [inline] __se_sys_mount fs/namespace.c:3049 [inline] __x64_sys_mount+0xba/0x150 fs/namespace.c:3049 do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe The buggy address belongs to the object at ffff8880a02bb340 which belongs to the cache kmalloc-32 of size 32 The buggy address is located 0 bytes inside of 32-byte region [ffff8880a02bb340, ffff8880a02bb360) The buggy address belongs to the page: page:ffffea000280aec0 count:1 mapcount:0 mapping:ffff88813bff01c0 index:0xffff8880a02bbfc1 flags: 0xfff00000000100(slab) raw: 00fff00000000100 ffffea00023e8bc8 ffffea0002a38548 ffff88813bff01c0 raw: ffff8880a02bbfc1 ffff8880a02bb000 000000010000003b 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff8880a02bb200: fb fb fb fb fc fc fc fc 00 03 fc fc fc fc fc fc ffff8880a02bb280: 00 fc fc fc fc fc fc fc 05 fc fc fc fc fc fc fc >ffff8880a02bb300: fb fb fb fb fc fc fc fc 01 fc fc fc fc fc fc fc ^ ffff8880a02bb380: fb fb fb fb fc fc fc fc fb fb fb fb fc fc fc fc ffff8880a02bb400: 00 00 04 fc fc fc fc fc fb fb fb fb fc fc fc fc ================================================================== ---------------- Code disassembly (best guess): 0: 41 55 push %r13 2: 49 89 d5 mov %rdx,%r13 5: 41 54 push %r12 7: 49 89 fc mov %rdi,%r12 a: 55 push %rbp b: 48 89 f5 mov %rsi,%rbp e: 53 push %rbx f: 48 83 ec 68 sub $0x68,%rsp 13: 48 c7 44 24 08 b3 8a movq $0x41b58ab3,0x8(%rsp) 1a: b5 41 1c: 48 8d 5c 24 08 lea 0x8(%rsp),%rbx 21: 48 c7 44 24 10 35 af movq $0xffffffff89b6af35,0x10(%rsp) 28: b6 89 * 2a: 48 c1 eb 03 shr $0x3,%rbx <-- trapping instruction 2e: 48 c7 44 24 18 20 7f movq $0xffffffff81297f20,0x18(%rsp) 35: 29 81 37: 48 8d 14 03 lea (%rbx,%rax,1),%rdx 3b: c7 .byte 0xc7 3c: 02 f1 add %cl,%dh 3e: f1 icebp 3f: f1 icebp