================================================================== BUG: KASAN: slab-out-of-bounds in mcp2221_raw_event+0x1070/0x10a0 drivers/hid/hid-mcp2221.c:948 Read of size 1 at addr ffff88814002ffff by task udevd/6772 CPU: 1 UID: 0 PID: 6772 Comm: udevd Not tainted syzkaller #0 PREEMPT(voluntary) Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 08/18/2025 Call Trace: __dump_stack lib/dump_stack.c:94 [inline] dump_stack_lvl+0x116/0x1f0 lib/dump_stack.c:120 print_address_description mm/kasan/report.c:378 [inline] print_report+0xcd/0x630 mm/kasan/report.c:482 kasan_report+0xe0/0x110 mm/kasan/report.c:595 mcp2221_raw_event+0x1070/0x10a0 drivers/hid/hid-mcp2221.c:948 __hid_input_report.constprop.0+0x311/0x450 drivers/hid/hid-core.c:2130 hid_irq_in+0x35e/0x870 drivers/hid/usbhid/hid-core.c:286 __usb_hcd_giveback_urb+0x38b/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:__sanitizer_cov_trace_pc+0x4/0x70 kernel/kcov.c:213 Code: 48 89 df 5b e9 5d 46 56 00 be 03 00 00 00 5b e9 c2 da 0b 01 66 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa <48> 8b 34 24 65 48 8b 15 18 a5 14 0b 65 8b 05 29 a5 14 0b a9 00 01 RSP: 0018:ffffc90014b0fbc8 EFLAGS: 00000282 RAX: ffffed10238490b3 RBX: 0000000000000004 RCX: ffffffff81fcbe7f RDX: ffff88811c248598 RSI: 0000000000000000 RDI: 0000000000000005 RBP: ffff88811701d0c0 R08: 0000000000000005 R09: 0000000000000000 R10: 0000000000000004 R11: 0000000000000000 R12: dffffc0000000000 R13: ffff88811701d0d8 R14: ffffc90014b0fc38 R15: 1ffff92002961f86 ep_wakeup_source fs/eventpoll.c:699 [inline] ep_send_events+0x407/0xc40 fs/eventpoll.c:1891 ep_try_send_events fs/eventpoll.c:1992 [inline] ep_poll fs/eventpoll.c:2057 [inline] do_epoll_wait+0x91b/0x1040 fs/eventpoll.c:2560 __do_sys_epoll_wait fs/eventpoll.c:2568 [inline] __se_sys_epoll_wait fs/eventpoll.c:2563 [inline] __x64_sys_epoll_wait+0x194/0x290 fs/eventpoll.c:2563 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xcd/0x4d0 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7f894cfbd407 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:00007ffee6aa7670 EFLAGS: 00000202 ORIG_RAX: 00000000000000e8 RAX: ffffffffffffffda RBX: 00007f894cecf880 RCX: 00007f894cfbd407 RDX: 0000000000000004 RSI: 00007ffee6aa7700 RDI: 0000000000000004 RBP: 0000558c14a1a2c0 R08: 0000000000000000 R09: 0000000000000000 R10: ffffffffffffffff R11: 0000000000000202 R12: 0000558c14c5ced0 R13: 00007ffee6aa7700 R14: 0000000000000000 R15: 0000000000000000 Allocated by task 2848: kasan_save_stack+0x33/0x60 mm/kasan/common.c:47 kasan_save_track+0x14/0x30 mm/kasan/common.c:68 unpoison_slab_object mm/kasan/common.c:330 [inline] __kasan_slab_alloc+0x6e/0x70 mm/kasan/common.c:356 kasan_slab_alloc include/linux/kasan.h:250 [inline] slab_post_alloc_hook mm/slub.c:4191 [inline] slab_alloc_node mm/slub.c:4240 [inline] kmem_cache_alloc_noprof+0x14f/0x3b0 mm/slub.c:4247 getname_flags.part.0+0x4c/0x550 fs/namei.c:146 getname_flags+0x93/0xf0 include/linux/audit.h:322 getname include/linux/fs.h:2919 [inline] do_sys_openat2+0xb8/0x1d0 fs/open.c:1429 do_sys_open fs/open.c:1450 [inline] __do_sys_openat fs/open.c:1466 [inline] __se_sys_openat fs/open.c:1461 [inline] __x64_sys_openat+0x174/0x210 fs/open.c:1461 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xcd/0x4d0 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f Freed by task 2848: kasan_save_stack+0x33/0x60 mm/kasan/common.c:47 kasan_save_track+0x14/0x30 mm/kasan/common.c:68 kasan_save_free_info+0x3b/0x60 mm/kasan/generic.c:576 poison_slab_object mm/kasan/common.c:243 [inline] __kasan_slab_free+0x3e/0x50 mm/kasan/common.c:275 kasan_slab_free include/linux/kasan.h:233 [inline] slab_free_hook mm/slub.c:2422 [inline] slab_free mm/slub.c:4695 [inline] kmem_cache_free+0x2a0/0x470 mm/slub.c:4797 putname+0x154/0x1a0 fs/namei.c:297 do_sys_openat2+0x152/0x1d0 fs/open.c:1443 do_sys_open fs/open.c:1450 [inline] __do_sys_openat fs/open.c:1466 [inline] __se_sys_openat fs/open.c:1461 [inline] __x64_sys_openat+0x174/0x210 fs/open.c:1461 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xcd/0x4d0 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f The buggy address belongs to the object at ffff88814002e600 which belongs to the cache names_cache of size 4096 The buggy address is located 2559 bytes to the right of allocated 4096-byte region [ffff88814002e600, ffff88814002f600) The buggy address belongs to the physical page: page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x140028 head: order:3 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0 flags: 0x200000000000040(head|node=0|zone=2) page_type: f5(slab) raw: 0200000000000040 ffff8881012a1000 dead000000000122 0000000000000000 raw: 0000000000000000 0000000000070007 00000000f5000000 0000000000000000 head: 0200000000000040 ffff8881012a1000 dead000000000122 0000000000000000 head: 0000000000000000 0000000000070007 00000000f5000000 0000000000000000 head: 0200000000000003 ffffea0005000a01 00000000ffffffff 00000000ffffffff head: 0000000000000000 0000000000000000 00000000ffffffff 0000000000000008 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 3, migratetype Unmovable, gfp_mask 0xd20c0(__GFP_IO|__GFP_FS|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC), pid 2848, tgid 2848 (udevd), ts 1767512266773, free_ts 1766955511868 set_page_owner include/linux/page_owner.h:32 [inline] post_alloc_hook+0x1c0/0x230 mm/page_alloc.c:1851 prep_new_page mm/page_alloc.c:1859 [inline] get_page_from_freelist+0xf98/0x2ce0 mm/page_alloc.c:3858 __alloc_frozen_pages_noprof+0x259/0x21e0 mm/page_alloc.c:5148 alloc_pages_mpol+0xe4/0x410 mm/mempolicy.c:2416 alloc_slab_page mm/slub.c:2492 [inline] allocate_slab mm/slub.c:2660 [inline] new_slab+0x247/0x330 mm/slub.c:2714 ___slab_alloc+0xc55/0x1620 mm/slub.c:3901 __slab_alloc.constprop.0+0x56/0xb0 mm/slub.c:3992 __slab_alloc_node mm/slub.c:4067 [inline] slab_alloc_node mm/slub.c:4228 [inline] kmem_cache_alloc_noprof+0x1f9/0x3b0 mm/slub.c:4247 getname_flags.part.0+0x4c/0x550 fs/namei.c:146 getname_flags+0x93/0xf0 include/linux/audit.h:322 getname include/linux/fs.h:2919 [inline] do_sys_openat2+0xb8/0x1d0 fs/open.c:1429 do_sys_open fs/open.c:1450 [inline] __do_sys_openat fs/open.c:1466 [inline] __se_sys_openat fs/open.c:1461 [inline] __x64_sys_openat+0x174/0x210 fs/open.c:1461 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xcd/0x4d0 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f page last free pid 6772 tgid 6772 stack trace: reset_page_owner include/linux/page_owner.h:25 [inline] free_pages_prepare mm/page_alloc.c:1395 [inline] __free_frozen_pages+0x78a/0xfd0 mm/page_alloc.c:2895 discard_slab mm/slub.c:2758 [inline] __put_partials+0x165/0x1c0 mm/slub.c:3223 qlink_free mm/kasan/quarantine.c:163 [inline] qlist_free_all+0x4d/0x120 mm/kasan/quarantine.c:179 kasan_quarantine_reduce+0x195/0x1e0 mm/kasan/quarantine.c:286 __kasan_slab_alloc+0x4e/0x70 mm/kasan/common.c:340 kasan_slab_alloc include/linux/kasan.h:250 [inline] slab_post_alloc_hook mm/slub.c:4191 [inline] slab_alloc_node mm/slub.c:4240 [inline] kmem_cache_alloc_noprof+0x14f/0x3b0 mm/slub.c:4247 getname_flags.part.0+0x4c/0x550 fs/namei.c:146 getname_flags+0x93/0xf0 include/linux/audit.h:322 do_readlinkat+0xb4/0x3a0 fs/stat.c:575 __do_sys_readlink fs/stat.c:613 [inline] __se_sys_readlink fs/stat.c:610 [inline] __x64_sys_readlink+0x78/0xc0 fs/stat.c:610 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xcd/0x4d0 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f Memory state around the buggy address: ffff88814002fe80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff88814002ff00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc >ffff88814002ff80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff888140030000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff888140030080: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ================================================================== ---------------- Code disassembly (best guess): 0: 48 89 df mov %rbx,%rdi 3: 5b pop %rbx 4: e9 5d 46 56 00 jmp 0x564666 9: be 03 00 00 00 mov $0x3,%esi e: 5b pop %rbx f: e9 c2 da 0b 01 jmp 0x10bdad6 14: 66 90 xchg %ax,%ax 16: 90 nop 17: 90 nop 18: 90 nop 19: 90 nop 1a: 90 nop 1b: 90 nop 1c: 90 nop 1d: 90 nop 1e: 90 nop 1f: 90 nop 20: 90 nop 21: 90 nop 22: 90 nop 23: 90 nop 24: 90 nop 25: 90 nop 26: f3 0f 1e fa endbr64 * 2a: 48 8b 34 24 mov (%rsp),%rsi <-- trapping instruction 2e: 65 48 8b 15 18 a5 14 mov %gs:0xb14a518(%rip),%rdx # 0xb14a54e 35: 0b 36: 65 8b 05 29 a5 14 0b mov %gs:0xb14a529(%rip),%eax # 0xb14a566 3d: a9 .byte 0xa9 3e: 00 01 add %al,(%rcx)