hid-thrustmaster 0003:044F:B65D.0009: unknown main item tag 0x0 hid-thrustmaster 0003:044F:B65D.0009: hidraw0: USB HID v0.00 Device [HID 044f:b65d] on usb-dummy_hcd.0-1/input0 ================================================================== BUG: KASAN: stack-out-of-bounds in usb_check_int_endpoints+0x242/0x264 drivers/usb/core/usb.c:277 Read of size 1 at addr ffff8f800d266221 by task kworker/1:2/3749 CPU: 1 UID: 0 PID: 3749 Comm: kworker/1:2 Not tainted 6.14.0-rc1-syzkaller-g245aece3750d #0 Hardware name: riscv-virtio,qemu (DT) Workqueue: usb_hub_wq hub_event Call Trace: [] dump_backtrace+0x2e/0x3c arch/riscv/kernel/stacktrace.c:132 [] show_stack+0x30/0x3c arch/riscv/kernel/stacktrace.c:138 [] __dump_stack lib/dump_stack.c:94 [inline] [] dump_stack_lvl+0x12e/0x1a6 lib/dump_stack.c:120 [] print_address_description mm/kasan/report.c:378 [inline] [] print_report+0x28e/0x5aa mm/kasan/report.c:489 [] kasan_report+0xf0/0x214 mm/kasan/report.c:602 [] __asan_report_load1_noabort+0x12/0x1a mm/kasan/report_generic.c:378 [] usb_check_int_endpoints+0x242/0x264 drivers/usb/core/usb.c:277 [] thrustmaster_interrupts drivers/hid/hid-thrustmaster.c:176 [inline] [] thrustmaster_probe+0x45c/0xb9a drivers/hid/hid-thrustmaster.c:347 [] __hid_device_probe drivers/hid/hid-core.c:2713 [inline] [] hid_device_probe+0x312/0x668 drivers/hid/hid-core.c:2750 [] call_driver_probe drivers/base/dd.c:579 [inline] [] really_probe+0x232/0x9be drivers/base/dd.c:658 [] __driver_probe_device+0x1d4/0x3f2 drivers/base/dd.c:800 [] driver_probe_device+0x60/0x1ce drivers/base/dd.c:830 [] __device_attach_driver+0x1e2/0x2fc drivers/base/dd.c:958 [] bus_for_each_drv+0x142/0x1da drivers/base/bus.c:462 [] __device_attach+0x1c4/0x462 drivers/base/dd.c:1030 [] device_initial_probe+0x1c/0x26 drivers/base/dd.c:1079 [] bus_probe_device+0x15c/0x192 drivers/base/bus.c:537 [] device_add+0x10da/0x181c drivers/base/core.c:3665 [] hid_add_device+0x366/0x9d8 drivers/hid/hid-core.c:2896 [] usbhid_probe+0xa6e/0xf88 drivers/hid/usbhid/hid-core.c:1431 [] usb_probe_interface+0x2d6/0x8c4 drivers/usb/core/driver.c:396 [] call_driver_probe drivers/base/dd.c:579 [inline] [] really_probe+0x232/0x9be drivers/base/dd.c:658 [] __driver_probe_device+0x1d4/0x3f2 drivers/base/dd.c:800 [] driver_probe_device+0x60/0x1ce drivers/base/dd.c:830 [] __device_attach_driver+0x1e2/0x2fc drivers/base/dd.c:958 [] bus_for_each_drv+0x142/0x1da drivers/base/bus.c:462 [] __device_attach+0x1c4/0x462 drivers/base/dd.c:1030 [] device_initial_probe+0x1c/0x26 drivers/base/dd.c:1079 [] bus_probe_device+0x15c/0x192 drivers/base/bus.c:537 [] device_add+0x10da/0x181c drivers/base/core.c:3665 [] usb_set_configuration+0xf08/0x19dc drivers/usb/core/message.c:2210 [] usb_generic_driver_probe+0xae/0x128 drivers/usb/core/generic.c:250 [] usb_probe_device+0xd6/0x360 drivers/usb/core/driver.c:291 [] call_driver_probe drivers/base/dd.c:579 [inline] [] really_probe+0x232/0x9be drivers/base/dd.c:658 [] __driver_probe_device+0x1d4/0x3f2 drivers/base/dd.c:800 [] driver_probe_device+0x60/0x1ce drivers/base/dd.c:830 [] __device_attach_driver+0x1e2/0x2fc drivers/base/dd.c:958 [] bus_for_each_drv+0x142/0x1da drivers/base/bus.c:462 [] __device_attach+0x1c4/0x462 drivers/base/dd.c:1030 [] device_initial_probe+0x1c/0x26 drivers/base/dd.c:1079 [] bus_probe_device+0x15c/0x192 drivers/base/bus.c:537 [] device_add+0x10da/0x181c drivers/base/core.c:3665 [] usb_new_device+0x964/0x1778 drivers/usb/core/hub.c:2652 [] hub_port_connect drivers/usb/core/hub.c:5523 [inline] [] hub_port_connect_change drivers/usb/core/hub.c:5663 [inline] [] port_event drivers/usb/core/hub.c:5823 [inline] [] hub_event+0x2716/0x48de drivers/usb/core/hub.c:5905 [] process_one_work+0x96a/0x1f3a kernel/workqueue.c:3236 [] process_scheduled_works kernel/workqueue.c:3317 [inline] [] worker_thread+0x5be/0xdc6 kernel/workqueue.c:3398 [] kthread+0x37e/0x7b6 kernel/kthread.c:464 [] ret_from_fork+0xe/0x18 arch/riscv/kernel/entry.S:327 The buggy address belongs to stack of task kworker/1:2/3749 and is located at offset 65 in frame: usb_fill_control_urb include/linux/usb.h:1679 [inline] thrustmaster_probe+0x0/0xb9a drivers/hid/hid-thrustmaster.c:253 This frame has 2 objects: [48, 52) 'trans' [64, 65) 'ep_addr' The buggy address belongs to the virtual mapping at [ffff8f800d260000, ffff8f800d269000) created by: kernel_clone+0x11e/0xc3c kernel/fork.c:2815 The buggy address belongs to the physical page: page: refcount:1 mapcount:0 mapping:0000000000000000 index:0xffffaf8014adb500 pfn:0x94adb flags: 0xffe000000000000(node=0|zone=0|lastcpupid=0x7ff) raw: 0ffe000000000000 0000000000000000 dead000000000122 0000000000000000 raw: ffffaf8014adb500 0000000000000000 00000001ffffffff 0000000000000000 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 0, migratetype Unmovable, gfp_mask 0x2dc2(GFP_KERNEL|__GFP_HIGHMEM|__GFP_NOWARN|__GFP_ZERO), pid 1117, tgid 1117 (kworker/u10:6), ts 456462234100, free_ts 455878349800 __set_page_owner+0xa2/0x710 mm/page_owner.c:320 set_page_owner include/linux/page_owner.h:32 [inline] post_alloc_hook+0xea/0x1e2 mm/page_alloc.c:1551 prep_new_page mm/page_alloc.c:1559 [inline] get_page_from_freelist+0xf78/0x2bd6 mm/page_alloc.c:3477 __alloc_frozen_pages_noprof+0x1e8/0x20fc mm/page_alloc.c:4739 alloc_pages_mpol+0x1fa/0x5b8 mm/mempolicy.c:2270 alloc_frozen_pages_noprof+0x174/0x2f0 mm/mempolicy.c:2341 alloc_pages_noprof+0x20/0x48 mm/mempolicy.c:2361 vm_area_alloc_pages mm/vmalloc.c:3591 [inline] __vmalloc_area_node mm/vmalloc.c:3669 [inline] __vmalloc_node_range_noprof+0x640/0x120a mm/vmalloc.c:3846 alloc_thread_stack_node kernel/fork.c:314 [inline] dup_task_struct kernel/fork.c:1127 [inline] copy_process+0x2c08/0x6c9a kernel/fork.c:2233 kernel_clone+0x11e/0xc3c kernel/fork.c:2815 user_mode_thread+0xea/0x11a kernel/fork.c:2893 call_usermodehelper_exec_work kernel/umh.c:171 [inline] call_usermodehelper_exec_work+0xd4/0x1ac kernel/umh.c:157 process_one_work+0x96a/0x1f3a kernel/workqueue.c:3236 process_scheduled_works kernel/workqueue.c:3317 [inline] worker_thread+0x5be/0xdc6 kernel/workqueue.c:3398 kthread+0x37e/0x7b6 kernel/kthread.c:464 ret_from_fork+0xe/0x18 arch/riscv/kernel/entry.S:327 page last free pid 3177 tgid 3177 stack trace: __reset_page_owner+0x8c/0x400 mm/page_owner.c:297 reset_page_owner include/linux/page_owner.h:25 [inline] free_pages_prepare mm/page_alloc.c:1127 [inline] free_frozen_pages+0x96a/0x155c mm/page_alloc.c:2660 __free_slab+0xcc/0x172 mm/slub.c:2655 free_slab+0x38/0x1ae mm/slub.c:2678 discard_slab+0x42/0x5e mm/slub.c:2684 __slab_free+0x34a/0x3fa mm/slub.c:4520 do_slab_free mm/slub.c:4561 [inline] ___cache_free+0x1a4/0x1de mm/slub.c:4667 qlink_free mm/kasan/quarantine.c:163 [inline] qlist_free_all+0x76/0x168 mm/kasan/quarantine.c:179 kasan_quarantine_reduce+0x158/0x1ba mm/kasan/quarantine.c:286 __kasan_slab_alloc+0x5c/0x82 mm/kasan/common.c:329 kasan_slab_alloc include/linux/kasan.h:250 [inline] slab_post_alloc_hook mm/slub.c:4115 [inline] slab_alloc_node mm/slub.c:4164 [inline] kmem_cache_alloc_node_noprof+0x10a/0x3f0 mm/slub.c:4216 __alloc_skb+0x32c/0x42a net/core/skbuff.c:668 alloc_skb include/linux/skbuff.h:1331 [inline] netlink_alloc_large_skb+0x7a/0x13e net/netlink/af_netlink.c:1196 netlink_sendmsg+0x660/0xdc6 net/netlink/af_netlink.c:1867 sock_sendmsg_nosec net/socket.c:713 [inline] __sock_sendmsg+0xcc/0x160 net/socket.c:728 __sys_sendto+0x27a/0x34c net/socket.c:2182 Memory state around the buggy address: ffff8f800d266100: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff8f800d266180: 00 00 00 00 00 00 00 00 00 00 00 00 f1 f1 f1 f1 >ffff8f800d266200: f1 f1 04 f2 01 f3 f3 f3 00 00 00 00 00 00 00 00 ^ ffff8f800d266280: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff8f800d266300: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ==================================================================