================================================================== BUG: KASAN: null-ptr-deref in mcp2221_raw_event+0xc1f/0x1030 drivers/hid/hid-mcp2221.c:820 Write of size 30 at addr 0000000000000000 by task kworker/0:1/10 CPU: 0 UID: 0 PID: 10 Comm: kworker/0:1 Not tainted 6.16.0-rc2-syzkaller-00053-gcf16f408364e #0 PREEMPT(voluntary) Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/07/2025 Workqueue: usb_hub_wq hub_event Call Trace: __dump_stack lib/dump_stack.c:94 [inline] dump_stack_lvl+0x116/0x1f0 lib/dump_stack.c:120 kasan_report+0xe0/0x110 mm/kasan/report.c:634 check_region_inline mm/kasan/generic.c:183 [inline] kasan_check_range+0x100/0x1b0 mm/kasan/generic.c:189 __asan_memcpy+0x3c/0x60 mm/kasan/shadow.c:106 mcp2221_raw_event+0xc1f/0x1030 drivers/hid/hid-mcp2221.c:820 __hid_input_report.constprop.0+0x311/0x450 drivers/hid/hid-core.c:2117 hid_irq_in+0x35e/0x870 drivers/hid/usbhid/hid-core.c:286 __usb_hcd_giveback_urb+0x38d/0x6e0 drivers/usb/core/hcd.c:1650 usb_hcd_giveback_urb+0x39b/0x450 drivers/usb/core/hcd.c:1734 dummy_timer+0x180e/0x3a20 drivers/usb/gadget/udc/dummy_hcd.c:1995 __run_hrtimer kernel/time/hrtimer.c:1761 [inline] __hrtimer_run_queues+0x202/0xad0 kernel/time/hrtimer.c:1825 hrtimer_run_softirq+0x17d/0x350 kernel/time/hrtimer.c:1842 handle_softirqs+0x205/0x8d0 kernel/softirq.c:579 __do_softirq kernel/softirq.c:613 [inline] invoke_softirq kernel/softirq.c:453 [inline] __irq_exit_rcu+0xfa/0x160 kernel/softirq.c:680 irq_exit_rcu+0x9/0x30 kernel/softirq.c:696 instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1050 [inline] sysvec_apic_timer_interrupt+0x90/0xb0 arch/x86/kernel/apic/apic.c:1050 asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:702 RIP: 0010:rcu_is_watching_curr_cpu include/linux/context_tracking.h:128 [inline] RIP: 0010:rcu_is_watching+0x41/0xc0 kernel/rcu/tree.c:745 Code: 6c 8c 89 c5 83 f8 07 0f 87 82 00 00 00 48 8d 3c ed 80 fb ba 88 48 b8 00 00 00 00 00 fc ff df 48 89 fa 48 c1 ea 03 80 3c 02 00 <75> 5c 48 03 1c ed 80 fb ba 88 48 b8 00 00 00 00 00 fc ff df 48 89 RSP: 0018:ffffc900000af130 EFLAGS: 00000246 RAX: dffffc0000000000 RBX: ffffffff8c6cefa8 RCX: 00000000acea3732 RDX: 1ffffffff1175f70 RSI: ffffffff8768fbc0 RDI: ffffffff88bafb80 RBP: 0000000000000000 R08: 5ab616dc3f964729 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000001 R12: ffffffff81695dd0 R13: ffffc900000af1b8 R14: 0000000000000000 R15: ffff8881016f1d00 rcu_read_lock include/linux/rcupdate.h:842 [inline] class_rcu_constructor include/linux/rcupdate.h:1155 [inline] unwind_next_frame+0xa3b/0x20a0 arch/x86/kernel/unwind_orc.c:479 arch_stack_walk+0x94/0x100 arch/x86/kernel/stacktrace.c:25 stack_trace_save+0x8e/0xc0 kernel/stacktrace.c:122 kasan_save_stack+0x33/0x60 mm/kasan/common.c:47 kasan_save_track+0x14/0x30 mm/kasan/common.c:68 poison_kmalloc_redzone mm/kasan/common.c:377 [inline] __kasan_kmalloc+0x8f/0xa0 mm/kasan/common.c:394 kasan_kmalloc include/linux/kasan.h:260 [inline] __do_kmalloc_node mm/slub.c:4328 [inline] __kmalloc_noprof+0x213/0x4d0 mm/slub.c:4340 kmalloc_noprof include/linux/slab.h:909 [inline] kzalloc_noprof include/linux/slab.h:1039 [inline] rh_call_control drivers/usb/core/hcd.c:491 [inline] rh_urb_enqueue drivers/usb/core/hcd.c:821 [inline] usb_hcd_submit_urb+0x5cf/0x1c60 drivers/usb/core/hcd.c:1529 usb_submit_urb+0x88a/0x1770 drivers/usb/core/urb.c:581 usb_start_wait_urb+0x104/0x4b0 drivers/usb/core/message.c:59 usb_internal_control_msg drivers/usb/core/message.c:103 [inline] usb_control_msg+0x326/0x4a0 drivers/usb/core/message.c:154 get_port_status drivers/usb/core/hub.c:605 [inline] hub_ext_port_status+0x14e/0x670 drivers/usb/core/hub.c:622 usb_hub_port_status drivers/usb/core/hub.c:672 [inline] hub_port_debounce+0x1a2/0x3d0 drivers/usb/core/hub.c:4673 hub_port_debounce_be_stable drivers/usb/core/hub.h:183 [inline] hub_port_connect drivers/usb/core/hub.c:5387 [inline] hub_port_connect_change drivers/usb/core/hub.c:5675 [inline] port_event drivers/usb/core/hub.c:5835 [inline] hub_event+0x3653/0x5030 drivers/usb/core/hub.c:5917 process_one_work+0x9cc/0x1b70 kernel/workqueue.c:3238 process_scheduled_works kernel/workqueue.c:3321 [inline] worker_thread+0x6c8/0xf10 kernel/workqueue.c:3402 kthread+0x3c5/0x780 kernel/kthread.c:464 ret_from_fork+0x5b3/0x6c0 arch/x86/kernel/process.c:148 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245 ================================================================== ---------------- Code disassembly (best guess): 0: 6c insb (%dx),%es:(%rdi) 1: 8c 89 c5 83 f8 07 mov %cs,0x7f883c5(%rcx) 7: 0f 87 82 00 00 00 ja 0x8f d: 48 8d 3c ed 80 fb ba lea -0x77450480(,%rbp,8),%rdi 14: 88 15: 48 b8 00 00 00 00 00 movabs $0xdffffc0000000000,%rax 1c: fc ff df 1f: 48 89 fa mov %rdi,%rdx 22: 48 c1 ea 03 shr $0x3,%rdx 26: 80 3c 02 00 cmpb $0x0,(%rdx,%rax,1) * 2a: 75 5c jne 0x88 <-- trapping instruction 2c: 48 03 1c ed 80 fb ba add -0x77450480(,%rbp,8),%rbx 33: 88 34: 48 b8 00 00 00 00 00 movabs $0xdffffc0000000000,%rax 3b: fc ff df 3e: 48 rex.W 3f: 89 .byte 0x89