================================================================== BUG: KASAN: use-after-free in mcp2221_raw_event+0x106a/0x1240 drivers/hid/hid-mcp2221.c:950 Read of size 1 at addr ffff8880526d3fff by task syz.6.1179/10878 CPU: 1 UID: 0 PID: 10878 Comm: syz.6.1179 Tainted: G L syzkaller #0 PREEMPT(full) Tainted: [L]=SOFTLOCKUP Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/18/2026 Call Trace: dump_stack_lvl+0xe8/0x150 lib/dump_stack.c:120 print_address_description mm/kasan/report.c:378 [inline] print_report+0xba/0x230 mm/kasan/report.c:482 kasan_report+0x117/0x150 mm/kasan/report.c:595 mcp2221_raw_event+0x106a/0x1240 drivers/hid/hid-mcp2221.c:950 __hid_input_report drivers/hid/hid-core.c:2140 [inline] hid_input_report+0x41d/0x580 drivers/hid/hid-core.c:2167 hid_irq_in+0x47e/0x6d0 drivers/hid/usbhid/hid-core.c:286 __usb_hcd_giveback_urb+0x376/0x540 drivers/usb/core/hcd.c:1657 dummy_timer+0xbbd/0x45d0 drivers/usb/gadget/udc/dummy_hcd.c:1995 __run_hrtimer kernel/time/hrtimer.c:1785 [inline] __hrtimer_run_queues+0x53a/0xcc0 kernel/time/hrtimer.c:1849 hrtimer_run_softirq+0x182/0x5a0 kernel/time/hrtimer.c:1866 handle_softirqs+0x22a/0x870 kernel/softirq.c:622 __do_softirq kernel/softirq.c:656 [inline] invoke_softirq kernel/softirq.c:496 [inline] __irq_exit_rcu+0x5f/0x150 kernel/softirq.c:723 irq_exit_rcu+0x9/0x30 kernel/softirq.c:739 instr_sysvec_call_function_single arch/x86/kernel/smp.c:266 [inline] sysvec_call_function_single+0x54/0xc0 arch/x86/kernel/smp.c:266 asm_sysvec_call_function_single+0x1a/0x20 arch/x86/include/asm/idtentry.h:704 RIP: 0033:0x7f7c2ee6cd30 Code: eb c0 48 39 f2 72 a4 48 39 f0 0f 83 c0 00 00 00 48 89 75 00 49 89 4c 24 f8 48 8b 4d 08 48 8b 55 00 eb 91 0f 1f 80 00 00 00 00 <4c> 89 ea 4c 89 e6 48 89 df e8 02 ff ff ff 48 89 d8 48 29 e8 48 3d RSP: 002b:00007f7c2f33f9a0 EFLAGS: 00000212 RAX: 00007f7c2ead9358 RBX: 00007f7c2ead9360 RCX: ffffffff81be6b11 RDX: ffffffff81be6b11 RSI: ffffffff81be6b11 RDI: 00007f7c2ead9358 RBP: 00007f7c2ead9310 R08: 00007f7c2f200000 R09: 00007f7c2f216038 R10: 0000000000000001 R11: 0000000000000002 R12: 00007f7c2ead93a8 R13: 0000000000000015 R14: 0000000000000013 R15: 0000000000000001 The buggy address belongs to the physical page: page: refcount:0 mapcount:0 mapping:0000000000000000 index:0xffff8880526d3500 pfn:0x526d3 flags: 0xfff00000000000(node=0|zone=1|lastcpupid=0x7ff) raw: 00fff00000000000 ffffea0000a23e48 ffffea0000c1e3c8 0000000000000000 raw: ffff8880526d3500 0000000000000000 00000000ffffffff 0000000000000000 page dumped because: kasan: bad access detected page_owner tracks the page as freed page last allocated via order 0, migratetype Unmovable, gfp_mask 0x52dc0(GFP_KERNEL|__GFP_ZERO|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP), pid 10833, tgid 10831 (syz.1.1168), ts 395654952892, free_ts 396144459522 set_page_owner include/linux/page_owner.h:32 [inline] post_alloc_hook+0x231/0x280 mm/page_alloc.c:1889 prep_new_page mm/page_alloc.c:1897 [inline] get_page_from_freelist+0x24dc/0x2580 mm/page_alloc.c:3962 __alloc_frozen_pages_noprof+0x18d/0x380 mm/page_alloc.c:5250 alloc_pages_mpol+0x232/0x4a0 mm/mempolicy.c:2490 alloc_frozen_pages_noprof mm/mempolicy.c:2561 [inline] alloc_pages_noprof+0xa8/0x1a0 mm/mempolicy.c:2581 get_free_pages_noprof+0xf/0x80 mm/page_alloc.c:5309 alloc_one_pg_vec_page net/packet/af_packet.c:4368 [inline] alloc_pg_vec net/packet/af_packet.c:4398 [inline] packet_set_ring+0x735/0x2490 net/packet/af_packet.c:4483 packet_setsockopt+0xd9c/0x1510 net/packet/af_packet.c:3839 do_sock_setsockopt+0x17c/0x1b0 net/socket.c:2322 __sys_setsockopt net/socket.c:2347 [inline] __do_sys_setsockopt net/socket.c:2353 [inline] __se_sys_setsockopt net/socket.c:2350 [inline] __x64_sys_setsockopt+0x13d/0x1b0 net/socket.c:2350 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0x14d/0xf80 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f page last free pid 10831 tgid 10831 stack trace: reset_page_owner include/linux/page_owner.h:25 [inline] __free_pages_prepare mm/page_alloc.c:1433 [inline] __free_frozen_pages+0xc2b/0xdb0 mm/page_alloc.c:2978 free_pg_vec net/packet/af_packet.c:4354 [inline] packet_set_ring+0x1a21/0x2490 net/packet/af_packet.c:4573 packet_release+0x7e8/0xd10 net/packet/af_packet.c:3152 __sock_release net/socket.c:662 [inline] sock_close+0xc3/0x240 net/socket.c:1455 __fput+0x44f/0xa70 fs/file_table.c:469 task_work_run+0x1d9/0x270 kernel/task_work.c:233 resume_user_mode_work include/linux/resume_user_mode.h:50 [inline] __exit_to_user_mode_loop kernel/entry/common.c:67 [inline] exit_to_user_mode_loop+0xed/0x480 kernel/entry/common.c:98 __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 include/linux/entry-common.h:325 [inline] do_syscall_64+0x32d/0xf80 arch/x86/entry/syscall_64.c:100 entry_SYSCALL_64_after_hwframe+0x77/0x7f Memory state around the buggy address: ffff8880526d3e80: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff8880526d3f00: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff >ffff8880526d3f80: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ^ ffff8880526d4000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff8880526d4080: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ==================================================================