================================================================== BUG: KASAN: use-after-free in roccat_disconnect+0x236/0x240 drivers/hid/hid-roccat.c:382 Read of size 4 at addr ffff888077162008 by task kworker/1:4/4370 CPU: 1 PID: 4370 Comm: kworker/1:4 Not tainted syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/07/2026 Workqueue: usb_hub_wq hub_event Call Trace: dump_stack_lvl+0x188/0x24e lib/dump_stack.c:106 print_address_description mm/kasan/report.c:316 [inline] print_report+0xa8/0x210 mm/kasan/report.c:420 kasan_report+0x10b/0x140 mm/kasan/report.c:524 roccat_disconnect+0x236/0x240 drivers/hid/hid-roccat.c:382 savu_remove_specials drivers/hid/hid-roccat-savu.c:107 [inline] savu_remove+0xe5/0x160 drivers/hid/hid-roccat-savu.c:147 hid_device_remove+0xba/0x1b0 drivers/hid/hid-core.c:2762 device_remove drivers/base/dd.c:547 [inline] __device_release_driver drivers/base/dd.c:1279 [inline] device_release_driver_internal+0x47d/0x7c0 drivers/base/dd.c:1305 bus_remove_device+0x2dd/0x400 drivers/base/bus.c:531 device_del+0x63f/0xa80 drivers/base/core.c:3901 hid_remove_device drivers/hid/hid-core.c:2938 [inline] hid_destroy_device+0x66/0x100 drivers/hid/hid-core.c:2957 usbhid_disconnect+0x9b/0xc0 drivers/hid/usbhid/hid-core.c:1470 usb_unbind_interface+0x200/0x870 drivers/usb/core/driver.c:457 device_remove drivers/base/dd.c:549 [inline] __device_release_driver drivers/base/dd.c:1279 [inline] device_release_driver_internal+0x4cf/0x7c0 drivers/base/dd.c:1305 bus_remove_device+0x2dd/0x400 drivers/base/bus.c:531 device_del+0x63f/0xa80 drivers/base/core.c:3901 usb_disable_device+0x3e7/0x8a0 drivers/usb/core/message.c:1478 usb_disconnect+0x33c/0x8a0 drivers/usb/core/hub.c:2324 hub_port_connect drivers/usb/core/hub.c:5371 [inline] hub_port_connect_change drivers/usb/core/hub.c:5667 [inline] port_event drivers/usb/core/hub.c:5827 [inline] hub_event+0x1d27/0x5200 drivers/usb/core/hub.c:5909 process_one_work+0x8ab/0x1160 kernel/workqueue.c:2292 worker_thread+0xaf5/0x12a0 kernel/workqueue.c:2439 kthread+0x29d/0x330 kernel/kthread.c:376 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:295 Allocated by task 4364: kasan_save_stack mm/kasan/common.c:46 [inline] kasan_set_track+0x4b/0x70 mm/kasan/common.c:53 ____kasan_kmalloc mm/kasan/common.c:375 [inline] __kasan_kmalloc+0x8e/0xa0 mm/kasan/common.c:384 kmalloc include/linux/slab.h:563 [inline] kzalloc include/linux/slab.h:699 [inline] roccat_connect+0x59/0x490 drivers/hid/hid-roccat.c:315 savu_init_specials drivers/hid/hid-roccat-savu.c:81 [inline] savu_probe+0x1af/0x350 drivers/hid/hid-roccat-savu.c:131 __hid_device_probe drivers/hid/hid-core.c:2704 [inline] hid_device_probe+0x2b8/0x520 drivers/hid/hid-core.c:2743 call_driver_probe drivers/base/dd.c:-1 [inline] really_probe+0x24a/0xb40 drivers/base/dd.c:638 __driver_probe_device+0x1f5/0x390 drivers/base/dd.c:804 driver_probe_device+0x4f/0x420 drivers/base/dd.c:834 __device_attach_driver+0x2c6/0x510 drivers/base/dd.c:962 bus_for_each_drv+0x184/0x210 drivers/base/bus.c:429 __device_attach+0x2a7/0x480 drivers/base/dd.c:1034 bus_probe_device+0xba/0x1d0 drivers/base/bus.c:489 device_add+0xbcf/0x1050 drivers/base/core.c:3713 hid_add_device+0x361/0x500 drivers/hid/hid-core.c:2889 usbhid_probe+0xc3f/0x1010 drivers/hid/usbhid/hid-core.c:1443 usb_probe_interface+0x6e7/0xcf0 drivers/usb/core/driver.c:395 call_driver_probe drivers/base/dd.c:-1 [inline] really_probe+0x24a/0xb40 drivers/base/dd.c:638 __driver_probe_device+0x1f5/0x390 drivers/base/dd.c:804 driver_probe_device+0x4f/0x420 drivers/base/dd.c:834 __device_attach_driver+0x2c6/0x510 drivers/base/dd.c:962 bus_for_each_drv+0x184/0x210 drivers/base/bus.c:429 __device_attach+0x2a7/0x480 drivers/base/dd.c:1034 bus_probe_device+0xba/0x1d0 drivers/base/bus.c:489 device_add+0xbcf/0x1050 drivers/base/core.c:3713 usb_set_configuration+0x1ad8/0x2140 drivers/usb/core/message.c:2229 usb_generic_driver_probe+0x89/0x150 drivers/usb/core/generic.c:238 usb_probe_device+0x126/0x250 drivers/usb/core/driver.c:291 call_driver_probe drivers/base/dd.c:-1 [inline] really_probe+0x24a/0xb40 drivers/base/dd.c:638 __driver_probe_device+0x1f5/0x390 drivers/base/dd.c:804 driver_probe_device+0x4f/0x420 drivers/base/dd.c:834 __device_attach_driver+0x2c6/0x510 drivers/base/dd.c:962 bus_for_each_drv+0x184/0x210 drivers/base/bus.c:429 __device_attach+0x2a7/0x480 drivers/base/dd.c:1034 bus_probe_device+0xba/0x1d0 drivers/base/bus.c:489 device_add+0xbcf/0x1050 drivers/base/core.c:3713 usb_new_device+0xa01/0x15e0 drivers/usb/core/hub.c:2669 hub_port_connect drivers/usb/core/hub.c:5527 [inline] hub_port_connect_change drivers/usb/core/hub.c:5667 [inline] port_event drivers/usb/core/hub.c:5827 [inline] hub_event+0x2b2f/0x5200 drivers/usb/core/hub.c:5909 process_one_work+0x8ab/0x1160 kernel/workqueue.c:2292 worker_thread+0xaf5/0x12a0 kernel/workqueue.c:2439 kthread+0x29d/0x330 kernel/kthread.c:376 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:295 Freed by task 4827: kasan_save_stack mm/kasan/common.c:46 [inline] kasan_set_track+0x4b/0x70 mm/kasan/common.c:53 kasan_save_free_info+0x27/0x40 mm/kasan/generic.c:516 ____kasan_slab_free+0x126/0x1f0 mm/kasan/common.c:237 kasan_slab_free include/linux/kasan.h:177 [inline] slab_free_hook mm/slub.c:1735 [inline] slab_free_freelist_hook+0x133/0x1b0 mm/slub.c:1761 slab_free mm/slub.c:3694 [inline] __kmem_cache_free+0xb6/0x200 mm/slub.c:3707 roccat_release+0x2a6/0x370 drivers/hid/hid-roccat.c:238 __fput+0x20a/0x8b0 fs/file_table.c:320 task_work_run+0x1d0/0x260 kernel/task_work.c:203 resume_user_mode_work include/linux/resume_user_mode.h:49 [inline] exit_to_user_mode_loop+0xe6/0x110 kernel/entry/common.c:180 exit_to_user_mode_prepare+0xee/0x180 kernel/entry/common.c:213 __syscall_exit_to_user_mode_work kernel/entry/common.c:295 [inline] syscall_exit_to_user_mode+0x16/0x40 kernel/entry/common.c:306 do_syscall_64+0x58/0xa0 arch/x86/entry/common.c:82 entry_SYSCALL_64_after_hwframe+0x68/0xd2 The buggy address belongs to the object at ffff888077162000 which belongs to the cache kmalloc-1k of size 1024 The buggy address is located 8 bytes inside of 1024-byte region [ffff888077162000, ffff888077162400) The buggy address belongs to the physical page: page:ffffea0001dc5800 refcount:1 mapcount:0 mapping:0000000000000000 index:0xffff888077163800 pfn:0x77160 head:ffffea0001dc5800 order:3 compound_mapcount:0 compound_pincount:0 flags: 0xfff00000010200(slab|head|node=0|zone=1|lastcpupid=0x7ff) raw: 00fff00000010200 ffffea00015cf008 ffffea0001f50a08 ffff888018441dc0 raw: ffff888077163800 000000000010000f 00000001ffffffff 0000000000000000 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 3, migratetype Unmovable, gfp_mask 0xd2a20(GFP_ATOMIC|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC), pid 665, tgid 665 (kworker/u4:5), ts 88020538644, free_ts 88019434018 set_page_owner include/linux/page_owner.h:31 [inline] post_alloc_hook+0x173/0x1a0 mm/page_alloc.c:2560 prep_new_page mm/page_alloc.c:2567 [inline] get_page_from_freelist+0x206b/0x2180 mm/page_alloc.c:4358 __alloc_pages+0x1ec/0x4f0 mm/page_alloc.c:5658 alloc_slab_page+0x5d/0x180 mm/slub.c:1805 allocate_slab mm/slub.c:1950 [inline] new_slab+0x87/0x2d0 mm/slub.c:2003 ___slab_alloc+0xbc5/0x1240 mm/slub.c:3161 __slab_alloc mm/slub.c:3247 [inline] slab_alloc_node mm/slub.c:3332 [inline] __kmem_cache_alloc_node+0x126/0x270 mm/slub.c:3405 __do_kmalloc_node mm/slab_common.c:935 [inline] __kmalloc_node_track_caller+0xa0/0x240 mm/slab_common.c:956 kmalloc_reserve net/core/skbuff.c:446 [inline] __alloc_skb+0x226/0x7d0 net/core/skbuff.c:515 alloc_skb include/linux/skbuff.h:1303 [inline] nlmsg_new include/net/netlink.h:998 [inline] inet6_rt_notify+0xb0/0x240 net/ipv6/route.c:6250 fib6_add_rt2node net/ipv6/ip6_fib.c:1260 [inline] fib6_add+0x1e9a/0x3ed0 net/ipv6/ip6_fib.c:1489 __ip6_ins_rt net/ipv6/route.c:1350 [inline] ip6_route_add+0x86/0x130 net/ipv6/route.c:3900 addrconf_prefix_route net/ipv6/addrconf.c:2450 [inline] addrconf_add_linklocal+0x449/0x6d0 net/ipv6/addrconf.c:3274 addrconf_addr_gen+0x55e/0x6a0 net/ipv6/addrconf.c:3403 addrconf_dev_config net/ipv6/addrconf.c:3448 [inline] addrconf_init_auto_addrs+0x6f7/0xaa0 net/ipv6/addrconf.c:3527 addrconf_notify+0xacd/0xf60 net/ipv6/addrconf.c:3700 page last free stack trace: reset_page_owner include/linux/page_owner.h:24 [inline] free_pages_prepare mm/page_alloc.c:1487 [inline] free_pcp_prepare mm/page_alloc.c:1537 [inline] free_unref_page_prepare+0x8e5/0x9e0 mm/page_alloc.c:3414 free_unref_page+0x2e/0x3f0 mm/page_alloc.c:3509 free_slab mm/slub.c:2042 [inline] discard_slab mm/slub.c:2048 [inline] __unfreeze_partials+0x188/0x1e0 mm/slub.c:2598 put_cpu_partial+0x17c/0x250 mm/slub.c:2674 qlink_free mm/kasan/quarantine.c:166 [inline] qlist_free_all+0x76/0xe0 mm/kasan/quarantine.c:185 kasan_quarantine_reduce+0x144/0x160 mm/kasan/quarantine.c:292 __kasan_slab_alloc+0x1e/0x80 mm/kasan/common.c:306 kasan_slab_alloc include/linux/kasan.h:201 [inline] slab_post_alloc_hook+0x4b/0x490 mm/slab.h:742 slab_alloc_node mm/slub.c:3366 [inline] __kmem_cache_alloc_node+0x19d/0x270 mm/slub.c:3405 __do_kmalloc_node mm/slab_common.c:935 [inline] __kmalloc+0xa3/0x240 mm/slab_common.c:949 kmalloc include/linux/slab.h:568 [inline] kzalloc include/linux/slab.h:699 [inline] fib6_info_alloc+0x2e/0xe0 net/ipv6/ip6_fib.c:156 ip6_route_info_create+0x455/0x1220 net/ipv6/route.c:3800 ip6_route_add+0x24/0x130 net/ipv6/route.c:3896 addrconf_add_mroute net/ipv6/addrconf.c:2514 [inline] addrconf_add_dev+0x298/0x3a0 net/ipv6/addrconf.c:2532 addrconf_dev_config net/ipv6/addrconf.c:3439 [inline] addrconf_init_auto_addrs+0x63e/0xaa0 net/ipv6/addrconf.c:3527 addrconf_notify+0xacd/0xf60 net/ipv6/addrconf.c:3700 Memory state around the buggy address: ffff888077161f00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff888077161f80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc >ffff888077162000: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff888077162080: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff888077162100: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ==================================================================