================================================================== BUG: KASAN: null-ptr-deref in mcp2221_raw_event+0xc1f/0x1030 drivers/hid/hid-mcp2221.c:910 Write of size 111 at addr 0000000000000000 by task syz.4.2303/13625 CPU: 0 UID: 0 PID: 13625 Comm: syz.4.2303 Not tainted syzkaller #0 PREEMPT(voluntary) Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/12/2025 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:595 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:910 __hid_input_report.constprop.0+0x314/0x450 drivers/hid/hid-core.c:2130 hid_irq_in+0x35e/0x870 drivers/hid/usbhid/hid-core.c:286 __usb_hcd_giveback_urb+0x388/0x610 drivers/usb/core/hcd.c:1661 usb_hcd_giveback_urb+0x39b/0x450 drivers/usb/core/hcd.c:1745 dummy_timer+0x1814/0x3a30 drivers/usb/gadget/udc/dummy_hcd.c:1995 __run_hrtimer kernel/time/hrtimer.c:1761 [inline] __hrtimer_run_queues+0x1ff/0xad0 kernel/time/hrtimer.c:1825 hrtimer_run_softirq+0x17d/0x350 kernel/time/hrtimer.c:1842 handle_softirqs+0x208/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:zap_present_folio_ptes mm/memory.c:1499 [inline] RIP: 0010:zap_present_ptes mm/memory.c:1581 [inline] RIP: 0010:do_zap_pte_range mm/memory.c:1682 [inline] RIP: 0010:zap_pte_range mm/memory.c:1726 [inline] RIP: 0010:zap_pmd_range mm/memory.c:1818 [inline] RIP: 0010:zap_pud_range mm/memory.c:1847 [inline] RIP: 0010:zap_p4d_range mm/memory.c:1868 [inline] RIP: 0010:unmap_page_range+0xf86/0x3650 mm/memory.c:1889 Code: 00 48 8b 04 24 48 8b 28 48 8b 44 24 50 48 c1 e8 03 42 80 3c 20 00 0f 85 70 21 00 00 48 8b 44 24 28 48 8b 40 18 48 89 44 24 60 <48> 8b 44 24 40 44 0f b6 7c 24 60 48 c1 e8 03 42 0f b6 04 20 41 83 RSP: 0018:ffffc9001384f628 EFLAGS: 00000246 RAX: 0000000000000000 RBX: 0000000000000000 RCX: ffffffff81c7c722 RDX: ffff8881129f0000 RSI: ffffffff81c7c730 RDI: 0000000000000007 RBP: ffff88811a0e8000 R08: 0000000000000007 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000000 R12: dffffc0000000000 R13: ffff88811b80dce0 R14: 00007f6e7c39c000 R15: 0000000000000000 unmap_single_vma.constprop.0+0x153/0x240 mm/memory.c:1932 unmap_vmas+0x218/0x470 mm/memory.c:1976 exit_mmap+0x1b9/0xb90 mm/mmap.c:1280 __mmput kernel/fork.c:1130 [inline] mmput+0xdb/0x430 kernel/fork.c:1152 exit_mm kernel/exit.c:582 [inline] do_exit+0x7c7/0x2bf0 kernel/exit.c:949 do_group_exit+0xd3/0x2a0 kernel/exit.c:1102 get_signal+0x2673/0x26d0 kernel/signal.c:3034 arch_do_signal_or_restart+0x8f/0x7d0 arch/x86/kernel/signal.c:337 exit_to_user_mode_loop+0x7c/0xe0 kernel/entry/common.c:40 exit_to_user_mode_prepare include/linux/irq-entry-common.h:225 [inline] syscall_exit_to_user_mode_work include/linux/entry-common.h:175 [inline] syscall_exit_to_user_mode include/linux/entry-common.h:210 [inline] do_syscall_64+0x3e9/0x4b0 arch/x86/entry/syscall_64.c:100 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7f6e7ce3ebe9 Code: Unable to access opcode bytes at 0x7f6e7ce3ebbf. RSP: 002b:00007f6e7b8a7038 EFLAGS: 00000246 ORIG_RAX: 0000000000000000 RAX: fffffffffffffff0 RBX: 00007f6e7d075fa0 RCX: 00007f6e7ce3ebe9 RDX: 00000000000000bc RSI: 0000200000000000 RDI: 0000000000000004 RBP: 00007f6e7cec1e19 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 00007f6e7d076038 R14: 00007f6e7d075fa0 R15: 00007ffdb52a7408 ================================================================== ---------------- Code disassembly (best guess): 0: 00 48 8b add %cl,-0x75(%rax) 3: 04 24 add $0x24,%al 5: 48 8b 28 mov (%rax),%rbp 8: 48 8b 44 24 50 mov 0x50(%rsp),%rax d: 48 c1 e8 03 shr $0x3,%rax 11: 42 80 3c 20 00 cmpb $0x0,(%rax,%r12,1) 16: 0f 85 70 21 00 00 jne 0x218c 1c: 48 8b 44 24 28 mov 0x28(%rsp),%rax 21: 48 8b 40 18 mov 0x18(%rax),%rax 25: 48 89 44 24 60 mov %rax,0x60(%rsp) * 2a: 48 8b 44 24 40 mov 0x40(%rsp),%rax <-- trapping instruction 2f: 44 0f b6 7c 24 60 movzbl 0x60(%rsp),%r15d 35: 48 c1 e8 03 shr $0x3,%rax 39: 42 0f b6 04 20 movzbl (%rax,%r12,1),%eax 3e: 41 rex.B 3f: 83 .byte 0x83