================================================================== BUG: KASAN: slab-out-of-bounds in mcp2221_raw_event+0x1070/0x10a0 drivers/hid/hid-mcp2221.c:948 Read of size 1 at addr ffff88811800ffff by task ksoftirqd/0/14 CPU: 0 UID: 0 PID: 14 Comm: ksoftirqd/0 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+0x314/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+0x1809/0x3a00 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 run_ksoftirqd kernel/softirq.c:968 [inline] run_ksoftirqd+0x3a/0x60 kernel/softirq.c:960 smpboot_thread_fn+0x3f7/0xae0 kernel/smpboot.c:160 kthread+0x3c5/0x780 kernel/kthread.c:463 ret_from_fork+0x56d/0x700 arch/x86/kernel/process.c:148 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245 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_lru_noprof+0x14f/0x3a0 mm/slub.c:4259 shmem_alloc_inode+0x25/0x50 mm/shmem.c:5211 alloc_inode+0x64/0x240 fs/inode.c:346 new_inode+0x22/0x1c0 fs/inode.c:1145 __shmem_get_inode+0x19c/0xea0 mm/shmem.c:3110 shmem_get_inode mm/shmem.c:3209 [inline] shmem_mknod+0x66/0x240 mm/shmem.c:3905 lookup_open.isra.0+0x1171/0x1560 fs/namei.c:3708 open_last_lookups fs/namei.c:3807 [inline] path_openat+0x893/0x2cb0 fs/namei.c:4043 do_filp_open+0x20b/0x470 fs/namei.c:4073 do_sys_openat2+0x11b/0x1d0 fs/open.c:1435 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 1116: 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 i_callback+0x46/0x70 fs/inode.c:325 rcu_do_batch kernel/rcu/tree.c:2605 [inline] rcu_core+0x79c/0x1530 kernel/rcu/tree.c:2861 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 Last potentially related work creation: kasan_save_stack+0x33/0x60 mm/kasan/common.c:47 kasan_record_aux_stack+0x8c/0xa0 mm/kasan/generic.c:548 __call_rcu_common.constprop.0+0xa5/0xa10 kernel/rcu/tree.c:3123 destroy_inode+0x12c/0x1b0 fs/inode.c:401 evict+0x5b4/0x920 fs/inode.c:834 iput_final fs/inode.c:1897 [inline] iput fs/inode.c:1923 [inline] iput+0x521/0x880 fs/inode.c:1909 do_unlinkat+0x4e7/0x6d0 fs/namei.c:4657 __do_sys_unlink fs/namei.c:4696 [inline] __se_sys_unlink fs/namei.c:4694 [inline] __x64_sys_unlink+0xc5/0x110 fs/namei.c:4694 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 ffff88811800f888 which belongs to the cache shmem_inode_cache of size 1496 The buggy address is located 415 bytes to the right of allocated 1496-byte region [ffff88811800f888, ffff88811800fe60) The buggy address belongs to the physical page: page: refcount:0 mapcount:0 mapping:0000000000000000 index:0xffff88811800ebd8 pfn:0x118008 head: order:3 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0 memcg:ffff88810bf5c901 flags: 0x200000000000040(head|node=0|zone=2) page_type: f5(slab) raw: 0200000000000040 ffff8881012a1a00 dead000000000100 dead000000000122 raw: ffff88811800ebd8 0000000080140013 00000000f5000000 ffff88810bf5c901 head: 0200000000000040 ffff8881012a1a00 dead000000000100 dead000000000122 head: ffff88811800ebd8 0000000080140013 00000000f5000000 ffff88810bf5c901 head: 0200000000000003 ffffea0004600201 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 5235, tgid 5235 (udevd), ts 104937396704, free_ts 104923752748 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_lru_noprof+0x1f9/0x3a0 mm/slub.c:4259 shmem_alloc_inode+0x25/0x50 mm/shmem.c:5211 alloc_inode+0x64/0x240 fs/inode.c:346 new_inode+0x22/0x1c0 fs/inode.c:1145 __shmem_get_inode+0x19c/0xea0 mm/shmem.c:3110 shmem_get_inode mm/shmem.c:3209 [inline] shmem_symlink+0xf8/0x780 mm/shmem.c:4158 vfs_symlink fs/namei.c:4730 [inline] vfs_symlink+0x400/0x680 fs/namei.c:4714 do_symlinkat+0x16d/0x2e0 fs/namei.c:4756 __do_sys_symlink fs/namei.c:4777 [inline] __se_sys_symlink fs/namei.c:4775 [inline] __x64_sys_symlink+0x75/0x90 fs/namei.c:4775 page last free pid 5260 tgid 5258 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] __kmalloc_cache_noprof+0x14c/0x3c0 mm/slub.c:4402 kmalloc_noprof include/linux/slab.h:905 [inline] kzalloc_noprof include/linux/slab.h:1039 [inline] kobject_uevent_env+0x265/0x1870 lib/kobject_uevent.c:540 driver_bound+0x164/0x230 drivers/base/dd.c:422 really_probe+0x62b/0xa90 drivers/base/dd.c:709 __driver_probe_device+0x1de/0x440 drivers/base/dd.c:801 driver_probe_device+0x4c/0x1b0 drivers/base/dd.c:831 __driver_attach+0x283/0x580 drivers/base/dd.c:1217 bus_for_each_dev+0x13e/0x1d0 drivers/base/bus.c:370 bus_add_driver+0x2e9/0x690 drivers/base/bus.c:678 driver_register+0x15c/0x4b0 drivers/base/driver.c:249 usb_gadget_register_driver_owner+0x132/0x330 drivers/usb/gadget/udc/core.c:1704 Memory state around the buggy address: ffff88811800fe80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff88811800ff00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc >ffff88811800ff80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff888118010000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff888118010080: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ==================================================================