================================================================== BUG: KASAN: slab-out-of-bounds in mcp2221_raw_event+0x103c/0x10a0 drivers/hid/hid-mcp2221.c:948 Read of size 1 at addr ffff88813e263fff by task klogd/2853 CPU: 1 UID: 0 PID: 2853 Comm: klogd Not tainted syzkaller #0 PREEMPT(voluntary) Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/25/2025 Call Trace: __dump_stack lib/dump_stack.c:94 [inline] dump_stack_lvl+0x100/0x190 lib/dump_stack.c:120 print_address_description mm/kasan/report.c:378 [inline] print_report+0x156/0x4c9 mm/kasan/report.c:482 kasan_report+0xdf/0x1a0 mm/kasan/report.c:595 mcp2221_raw_event+0x103c/0x10a0 drivers/hid/hid-mcp2221.c:948 __hid_input_report.constprop.0+0x314/0x460 drivers/hid/hid-core.c:2139 hid_irq_in+0x52e/0x6b0 drivers/hid/usbhid/hid-core.c:286 __usb_hcd_giveback_urb+0x38d/0x610 drivers/usb/core/hcd.c:1657 usb_hcd_giveback_urb+0x3ca/0x4a0 drivers/usb/core/hcd.c:1741 dummy_timer+0xd85/0x3670 drivers/usb/gadget/udc/dummy_hcd.c:1995 __run_hrtimer kernel/time/hrtimer.c:1777 [inline] __hrtimer_run_queues+0x516/0x990 kernel/time/hrtimer.c:1841 hrtimer_run_softirq+0x17d/0x350 kernel/time/hrtimer.c:1858 handle_softirqs+0x1dd/0x8f0 kernel/softirq.c:622 __do_softirq kernel/softirq.c:656 [inline] invoke_softirq kernel/softirq.c:496 [inline] __irq_exit_rcu+0xed/0x150 kernel/softirq.c:723 irq_exit_rcu+0x9/0x30 kernel/softirq.c:739 instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1056 [inline] sysvec_apic_timer_interrupt+0x8f/0xb0 arch/x86/kernel/apic/apic.c:1056 asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:697 RIP: 0010:finish_task_switch.isra.0+0x160/0x700 kernel/sched/core.c:5118 Code: 8d 7b 18 31 f6 e8 20 d0 0a 00 31 f6 48 89 df e8 d6 f9 ff ff 48 89 df e8 1e c3 d2 05 e8 09 be 35 00 fb 49 8d bc 24 40 15 00 00 <48> b8 00 00 00 00 00 fc ff df 48 89 fa 48 c1 ea 03 0f b6 04 02 5a RSP: 0018:ffffc90001637d80 EFLAGS: 00000202 RAX: 000000000027be67 RBX: ffff8881f57390c0 RCX: 0000000000000000 RDX: 0000000000000000 RSI: ffffffff88dec6f5 RDI: ffff8881176c1540 RBP: ffffc90001637dc8 R08: 0000000000000001 R09: 0000000000000000 R10: 0000000000000001 R11: 0000000000000000 R12: ffff8881176c0000 R13: ffff88813a91d7c0 R14: 0000000000000000 R15: 0000000000002001 context_switch kernel/sched/core.c:5263 [inline] __schedule+0xeb8/0x3e50 kernel/sched/core.c:6867 __schedule_loop kernel/sched/core.c:6949 [inline] schedule+0xdd/0x390 kernel/sched/core.c:6964 __exit_to_user_mode_loop kernel/entry/common.c:32 [inline] exit_to_user_mode_loop+0x64/0x430 kernel/entry/common.c:75 __exit_to_user_mode_prepare include/linux/irq-entry-common.h:226 [inline] syscall_exit_to_user_mode_prepare include/linux/irq-entry-common.h:256 [inline] syscall_exit_to_user_mode_work include/linux/entry-common.h:159 [inline] syscall_exit_to_user_mode include/linux/entry-common.h:194 [inline] do_syscall_64+0x4a8/0x570 arch/x86/entry/syscall_64.c:100 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7fcf4817a407 Code: 48 89 fa 4c 89 df e8 38 aa 00 00 8b 93 08 03 00 00 59 5e 48 83 f8 fc 74 1a 5b c3 0f 1f 84 00 00 00 00 00 48 8b 44 24 10 0f 05 <5b> c3 0f 1f 80 00 00 00 00 83 e2 39 83 fa 08 75 de e8 23 ff ff ff RSP: 002b:00007ffcd4f15660 EFLAGS: 00000202 ORIG_RAX: 000000000000002c RAX: 000000000000006c RBX: 00007fcf4802ac80 RCX: 00007fcf4817a407 RDX: 000000000000006c RSI: 00007ffcd4f157a0 RDI: 0000000000000003 RBP: 00007ffcd4f15bd0 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000004000 R11: 0000000000000202 R12: 00007ffcd4f15be8 R13: 00007ffcd4f157a0 R14: 0000000000000051 R15: 00007ffcd4f157a0 Allocated by task 0: kasan_save_stack+0x30/0x50 mm/kasan/common.c:57 kasan_save_track+0x14/0x30 mm/kasan/common.c:78 poison_kmalloc_redzone mm/kasan/common.c:398 [inline] __kasan_kmalloc+0x8f/0xa0 mm/kasan/common.c:415 kmalloc_noprof include/linux/slab.h:957 [inline] dummy_urb_enqueue+0xa3/0x880 drivers/usb/gadget/udc/dummy_hcd.c:1273 usb_hcd_submit_urb+0x26c/0x2150 drivers/usb/core/hcd.c:1542 usb_submit_urb+0x8aa/0x1910 drivers/usb/core/urb.c:587 usbtouch_irq+0x1ff/0x3a0 drivers/input/touchscreen/usbtouchscreen.c:1322 __usb_hcd_giveback_urb+0x38d/0x610 drivers/usb/core/hcd.c:1657 usb_hcd_giveback_urb+0x3ca/0x4a0 drivers/usb/core/hcd.c:1741 dummy_timer+0xd85/0x3670 drivers/usb/gadget/udc/dummy_hcd.c:1995 __run_hrtimer kernel/time/hrtimer.c:1777 [inline] __hrtimer_run_queues+0x516/0x990 kernel/time/hrtimer.c:1841 hrtimer_run_softirq+0x17d/0x350 kernel/time/hrtimer.c:1858 handle_softirqs+0x1dd/0x8f0 kernel/softirq.c:622 __do_softirq kernel/softirq.c:656 [inline] invoke_softirq kernel/softirq.c:496 [inline] __irq_exit_rcu+0xed/0x150 kernel/softirq.c:723 irq_exit_rcu+0x9/0x30 kernel/softirq.c:739 instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1056 [inline] sysvec_apic_timer_interrupt+0x8f/0xb0 arch/x86/kernel/apic/apic.c:1056 asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:697 Freed by task 10761: kasan_save_stack+0x30/0x50 mm/kasan/common.c:57 kasan_save_track+0x14/0x30 mm/kasan/common.c:78 kasan_save_free_info+0x3b/0x70 mm/kasan/generic.c:584 poison_slab_object mm/kasan/common.c:253 [inline] __kasan_slab_free+0x43/0x70 mm/kasan/common.c:285 kasan_slab_free include/linux/kasan.h:235 [inline] slab_free_hook mm/slub.c:2540 [inline] slab_free mm/slub.c:6670 [inline] kfree+0x1ad/0x630 mm/slub.c:6878 dummy_timer+0xd19/0x3670 drivers/usb/gadget/udc/dummy_hcd.c:1989 __run_hrtimer kernel/time/hrtimer.c:1777 [inline] __hrtimer_run_queues+0x516/0x990 kernel/time/hrtimer.c:1841 hrtimer_run_softirq+0x17d/0x350 kernel/time/hrtimer.c:1858 handle_softirqs+0x1dd/0x8f0 kernel/softirq.c:622 __do_softirq kernel/softirq.c:656 [inline] invoke_softirq kernel/softirq.c:496 [inline] __irq_exit_rcu+0xed/0x150 kernel/softirq.c:723 irq_exit_rcu+0x9/0x30 kernel/softirq.c:739 instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1056 [inline] sysvec_apic_timer_interrupt+0x8f/0xb0 arch/x86/kernel/apic/apic.c:1056 asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:697 The buggy address belongs to the object at ffff88813e263f00 which belongs to the cache kmalloc-128 of size 128 The buggy address is located 127 bytes to the right of allocated 128-byte region [ffff88813e263f00, ffff88813e263f80) The buggy address belongs to the physical page: page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x13e263 flags: 0x200000000000000(node=0|zone=2) page_type: f5(slab) raw: 0200000000000000 ffff888100041a00 dead000000000122 0000000000000000 raw: 0000000000000000 0000000000100010 00000000f5000000 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 0x52820(GFP_ATOMIC|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP), pid 0, tgid 0 (swapper/1), ts 1083195308286, free_ts 1070867391797 set_page_owner include/linux/page_owner.h:32 [inline] post_alloc_hook+0x1e1/0x250 mm/page_alloc.c:1884 prep_new_page mm/page_alloc.c:1892 [inline] get_page_from_freelist+0xd57/0x3b20 mm/page_alloc.c:3945 __alloc_frozen_pages_noprof+0x269/0x2230 mm/page_alloc.c:5240 alloc_pages_mpol+0xe8/0x410 mm/mempolicy.c:2486 alloc_slab_page mm/slub.c:3075 [inline] allocate_slab mm/slub.c:3248 [inline] new_slab+0x2c4/0x440 mm/slub.c:3302 ___slab_alloc+0xda3/0x1ca0 mm/slub.c:4656 __slab_alloc.isra.0+0x63/0x110 mm/slub.c:4779 __slab_alloc_node mm/slub.c:4855 [inline] slab_alloc_node mm/slub.c:5251 [inline] __kmalloc_cache_noprof+0x4ee/0x7e0 mm/slub.c:5771 kmalloc_noprof include/linux/slab.h:957 [inline] dummy_urb_enqueue+0xa3/0x880 drivers/usb/gadget/udc/dummy_hcd.c:1273 usb_hcd_submit_urb+0x26c/0x2150 drivers/usb/core/hcd.c:1542 usb_submit_urb+0x8aa/0x1910 drivers/usb/core/urb.c:587 usbtouch_irq+0x1ff/0x3a0 drivers/input/touchscreen/usbtouchscreen.c:1322 __usb_hcd_giveback_urb+0x38d/0x610 drivers/usb/core/hcd.c:1657 usb_hcd_giveback_urb+0x3ca/0x4a0 drivers/usb/core/hcd.c:1741 dummy_timer+0xd85/0x3670 drivers/usb/gadget/udc/dummy_hcd.c:1995 __run_hrtimer kernel/time/hrtimer.c:1777 [inline] __hrtimer_run_queues+0x516/0x990 kernel/time/hrtimer.c:1841 page last free pid 15225 tgid 15225 stack trace: reset_page_owner include/linux/page_owner.h:25 [inline] free_pages_prepare mm/page_alloc.c:1433 [inline] __free_frozen_pages+0x7d1/0x1010 mm/page_alloc.c:2973 tlb_batch_list_free mm/mmu_gather.c:159 [inline] tlb_finish_mmu+0x23a/0x7f0 mm/mmu_gather.c:500 exit_mmap+0x3c5/0xae0 mm/mmap.c:1290 __mmput kernel/fork.c:1173 [inline] mmput+0xe0/0x430 kernel/fork.c:1196 exit_mm kernel/exit.c:581 [inline] do_exit+0x78a/0x2a30 kernel/exit.c:959 do_group_exit+0xd5/0x2a0 kernel/exit.c:1112 __do_sys_exit_group kernel/exit.c:1123 [inline] __se_sys_exit_group kernel/exit.c:1121 [inline] __x64_sys_exit_group+0x3e/0x50 kernel/exit.c:1121 x64_sys_call+0x14fd/0x1510 arch/x86/include/generated/asm/syscalls_64.h:232 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xc9/0x570 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f Memory state around the buggy address: ffff88813e263e80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff88813e263f00: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb >ffff88813e263f80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff88813e264000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff88813e264080: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ================================================================== ---------------- Code disassembly (best guess): 0: 8d 7b 18 lea 0x18(%rbx),%edi 3: 31 f6 xor %esi,%esi 5: e8 20 d0 0a 00 call 0xad02a a: 31 f6 xor %esi,%esi c: 48 89 df mov %rbx,%rdi f: e8 d6 f9 ff ff call 0xfffff9ea 14: 48 89 df mov %rbx,%rdi 17: e8 1e c3 d2 05 call 0x5d2c33a 1c: e8 09 be 35 00 call 0x35be2a 21: fb sti 22: 49 8d bc 24 40 15 00 lea 0x1540(%r12),%rdi 29: 00 * 2a: 48 b8 00 00 00 00 00 movabs $0xdffffc0000000000,%rax <-- trapping instruction 31: fc ff df 34: 48 89 fa mov %rdi,%rdx 37: 48 c1 ea 03 shr $0x3,%rdx 3b: 0f b6 04 02 movzbl (%rdx,%rax,1),%eax 3f: 5a pop %rdx