================================================================== BUG: KASAN: use-after-free in mcp2221_raw_event+0x110d/0x1140 drivers/hid/hid-mcp2221.c:975 Read of size 1 at addr ffff888115723fff by task pr/ttyS0/15 CPU: 1 UID: 0 PID: 15 Comm: pr/ttyS0 Not tainted syzkaller #0 PREEMPT(lazy) Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/16/2026 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+0x13d/0x4b0 mm/kasan/report.c:482 kasan_report+0xdf/0x1c0 mm/kasan/report.c:595 mcp2221_raw_event+0x110d/0x1140 drivers/hid/hid-mcp2221.c:975 __hid_input_report.constprop.0+0x319/0x470 drivers/hid/hid-core.c:2175 hid_irq_in+0x55d/0x710 drivers/hid/usbhid/hid-core.c:287 __usb_hcd_giveback_urb+0x38e/0x610 drivers/usb/core/hcd.c:1657 usb_hcd_giveback_urb+0x3ca/0x4a0 drivers/usb/core/hcd.c:1741 dummy_timer+0xdb2/0x3700 drivers/usb/gadget/udc/dummy_hcd.c:2019 __run_hrtimer kernel/time/hrtimer.c:2067 [inline] __hrtimer_run_queues+0x462/0x9c0 kernel/time/hrtimer.c:2124 hrtimer_run_softirq+0x1ca/0x360 kernel/time/hrtimer.c:2141 handle_softirqs+0x1d9/0x9b0 kernel/softirq.c:645 __do_softirq kernel/softirq.c:679 [inline] invoke_softirq kernel/softirq.c:519 [inline] __irq_exit_rcu+0x168/0x210 kernel/softirq.c:758 irq_exit_rcu+0x9/0x30 kernel/softirq.c:775 instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1062 [inline] sysvec_apic_timer_interrupt+0x8f/0xb0 arch/x86/kernel/apic/apic.c:1062 asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:674 RIP: 0010:finish_task_switch.isra.0+0x214/0xad0 kernel/sched/core.c:5377 Code: 74 08 3c 03 0f 8e aa 06 00 00 c7 83 40 0d 00 00 00 00 00 00 48 8d 7b 48 e8 49 06 06 06 e8 f4 66 38 00 fb 49 8d bf 30 16 00 00 <48> b8 00 00 00 00 00 fc ff df 48 89 fa 48 c1 ea 03 0f b6 04 02 84 RSP: 0018:ffffc900000ffaf0 EFLAGS: 00000202 RAX: 000000000023fe5b RBX: ffff8881f5739e40 RCX: 0000000000000000 RDX: 0000000000000001 RSI: ffffffff89329f40 RDI: ffff888101eeb470 RBP: ffffc900000ffb30 R08: 0000000000000001 R09: 0000000000000000 R10: 0000000000000001 R11: 0000000000000000 R12: ffff8881215e8000 R13: 0000000000000000 R14: ffff8881f573ab80 R15: ffff888101ee9e40 context_switch kernel/sched/core.c:5529 [inline] __schedule+0x132d/0x47e0 kernel/sched/core.c:7276 preempt_schedule_common+0x3c/0xb0 kernel/sched/core.c:7455 preempt_schedule_thunk+0x16/0x40 arch/x86/entry/thunk.S:12 __raw_spin_unlock_irqrestore include/linux/spinlock_api_smp.h:211 [inline] _raw_spin_unlock_irqrestore+0x61/0x80 kernel/locking/spinlock.c:221 nbcon_emit_one+0x15c/0x2b0 kernel/printk/nbcon.c:1165 nbcon_kthread_func+0x613/0x7d0 kernel/printk/nbcon.c:1271 kthread+0x373/0x450 kernel/kthread.c:436 ret_from_fork+0x69f/0xc90 arch/x86/kernel/process.c:158 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245 The buggy address belongs to the physical page: page: refcount:0 mapcount:0 mapping:0000000000000000 index:0xffff888115723800 pfn:0x115723 flags: 0x200000000000000(node=0|zone=2) raw: 0200000000000000 0000000000000000 00000000ffffffff 0000000000000000 raw: ffff888115723800 0000000000000000 00000000ffffffff 0000000000000000 page dumped because: kasan: bad access detected page_owner tracks the page as freed page last allocated via order 1, migratetype Unmovable, gfp_mask 0xd20c0(__GFP_IO|__GFP_FS|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC), pid 10335, tgid 10335 (sed), ts 769831643555 set_page_owner include/linux/page_owner.h:33 [inline] post_alloc_hook+0xfd/0x120 mm/page_alloc.c:1871 prep_new_page mm/page_alloc.c:1879 [inline] get_page_from_freelist+0xf4b/0x3440 mm/page_alloc.c:3943 __alloc_frozen_pages_noprof+0x2d7/0x2f70 mm/page_alloc.c:5436 alloc_slab_page mm/slub.c:3347 [inline] allocate_slab mm/slub.c:3462 [inline] new_slab+0xa9/0x6e0 mm/slub.c:3513 refill_objects+0xe3/0x410 mm/slub.c:7410 refill_sheaf mm/slub.c:2885 [inline] __pcs_replace_empty_main+0x35e/0x650 mm/slub.c:4774 alloc_from_pcs mm/slub.c:4850 [inline] slab_alloc_node mm/slub.c:4984 [inline] kmem_cache_alloc_noprof+0x471/0x650 mm/slub.c:5010 mt_alloc_one lib/maple_tree.c:139 [inline] mas_alloc_nodes lib/maple_tree.c:1086 [inline] mas_preallocate+0xc22/0xee0 lib/maple_tree.c:5057 vma_iter_prealloc mm/vma.h:665 [inline] __split_vma+0x2f8/0x1db0 mm/vma.c:573 vms_gather_munmap_vmas+0x3a5/0x1670 mm/vma.c:1528 __mmap_setup mm/vma.c:2538 [inline] __mmap_region+0x4c9/0x3150 mm/vma.c:2861 mmap_region+0x3db/0x6d0 mm/vma.c:2964 do_mmap+0x12b6/0x1c10 mm/mmap.c:573 vm_mmap_pgoff+0x1f0/0x390 mm/util.c:581 ksys_mmap_pgoff+0x3cb/0x610 mm/mmap.c:619 __do_sys_mmap arch/x86/kernel/sys_x86_64.c:89 [inline] __se_sys_mmap arch/x86/kernel/sys_x86_64.c:82 [inline] __x64_sys_mmap+0x125/0x190 arch/x86/kernel/sys_x86_64.c:82 page last free pid 2866 tgid 2866 ts 826552454228 stack trace: reset_page_owner include/linux/page_owner.h:26 [inline] __free_pages_prepare mm/page_alloc.c:1418 [inline] __free_frozen_pages+0x714/0xfc0 mm/page_alloc.c:2962 qlink_free mm/kasan/quarantine.c:163 [inline] qlist_free_all+0x47/0xf0 mm/kasan/quarantine.c:179 kasan_quarantine_reduce+0x1a0/0x1f0 mm/kasan/quarantine.c:286 __kasan_slab_alloc+0x4e/0x70 mm/kasan/common.c:350 kasan_slab_alloc include/linux/kasan.h:253 [inline] slab_post_alloc_hook mm/slub.c:4683 [inline] slab_alloc_node mm/slub.c:4996 [inline] kmem_cache_alloc_noprof+0x264/0x650 mm/slub.c:5010 alloc_filename fs/namei.c:147 [inline] do_getname+0x35/0x390 fs/namei.c:187 class_filename_flags_constructor include/linux/fs.h:2586 [inline] do_sys_openat2+0xc7/0x1e0 fs/open.c:1416 do_sys_open fs/open.c:1423 [inline] __do_sys_openat fs/open.c:1439 [inline] __se_sys_openat fs/open.c:1434 [inline] __x64_sys_openat+0x12d/0x210 fs/open.c:1434 do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline] do_syscall_64+0x119/0x710 arch/x86/entry/syscall_64.c:84 entry_SYSCALL_64_after_hwframe+0x77/0x7f Memory state around the buggy address: ffff888115723e80: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff888115723f00: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff >ffff888115723f80: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ^ ffff888115724000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff888115724080: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ================================================================== ---------------- Code disassembly (best guess): 0: 74 08 je 0xa 2: 3c 03 cmp $0x3,%al 4: 0f 8e aa 06 00 00 jle 0x6b4 a: c7 83 40 0d 00 00 00 movl $0x0,0xd40(%rbx) 11: 00 00 00 14: 48 8d 7b 48 lea 0x48(%rbx),%rdi 18: e8 49 06 06 06 call 0x6060666 1d: e8 f4 66 38 00 call 0x386716 22: fb sti 23: 49 8d bf 30 16 00 00 lea 0x1630(%r15),%rdi * 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: 84 .byte 0x84