usb 1-1: config 0 interface 0 altsetting 0 has 1 endpoint descriptor, different from the interface descriptor's value: 9 usb 1-1: New USB device found, idVendor=11c0, idProduct=5506, bcdDevice= 0.00 usb 1-1: New USB device strings: Mfr=0, Product=0, SerialNumber=0 usb 1-1: config 0 descriptor?? betop 0003:11C0:5506.0001: hidraw0: USB HID v0.00 Device [HID 11c0:5506] on usb-dummy_hcd.0-1/input0 ================================================================== BUG: KASAN: slab-out-of-bounds in instrument_atomic_write include/linux/instrumented.h:86 [inline] BUG: KASAN: slab-out-of-bounds in set_bit include/asm-generic/bitops/instrumented-atomic.h:28 [inline] BUG: KASAN: slab-out-of-bounds in betopff_init drivers/hid/hid-betopff.c:99 [inline] BUG: KASAN: slab-out-of-bounds in betop_probe+0x3e4/0x5b0 drivers/hid/hid-betopff.c:134 Write of size 8 at addr ffff8880180fcbc0 by task kworker/1:0/20 CPU: 1 PID: 20 Comm: kworker/1:0 Not tainted 5.13.0-rc4-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Workqueue: usb_hub_wq hub_event Call Trace: __dump_stack lib/dump_stack.c:79 [inline] dump_stack+0x202/0x31e lib/dump_stack.c:120 print_address_description+0x5f/0x3b0 mm/kasan/report.c:233 __kasan_report mm/kasan/report.c:419 [inline] kasan_report+0x15c/0x200 mm/kasan/report.c:436 check_region_inline mm/kasan/generic.c:135 [inline] kasan_check_range+0x2b5/0x2f0 mm/kasan/generic.c:186 instrument_atomic_write include/linux/instrumented.h:86 [inline] set_bit include/asm-generic/bitops/instrumented-atomic.h:28 [inline] betopff_init drivers/hid/hid-betopff.c:99 [inline] betop_probe+0x3e4/0x5b0 drivers/hid/hid-betopff.c:134 hid_device_probe+0x26c/0x410 drivers/hid/hid-core.c:2287 really_probe+0x385/0x1020 drivers/base/dd.c:576 driver_probe_device+0x178/0x350 drivers/base/dd.c:763 bus_for_each_drv+0x16a/0x1f0 drivers/base/bus.c:431 __device_attach+0x301/0x560 drivers/base/dd.c:938 bus_probe_device+0xb8/0x1f0 drivers/base/bus.c:491 device_add+0x11fc/0x1670 drivers/base/core.c:3324 hid_add_device+0xd4f/0xfa0 drivers/hid/hid-core.c:2443 usbhid_probe+0xb4c/0xed0 drivers/hid/usbhid/hid-core.c:1409 usb_probe_interface+0x633/0xb40 drivers/usb/core/driver.c:396 really_probe+0x3cb/0x1020 drivers/base/dd.c:580 driver_probe_device+0x178/0x350 drivers/base/dd.c:763 bus_for_each_drv+0x16a/0x1f0 drivers/base/bus.c:431 __device_attach+0x301/0x560 drivers/base/dd.c:938 bus_probe_device+0xb8/0x1f0 drivers/base/bus.c:491 device_add+0x11fc/0x1670 drivers/base/core.c:3324 usb_set_configuration+0x1a86/0x2100 drivers/usb/core/message.c:2164 usb_generic_driver_probe+0x83/0x140 drivers/usb/core/generic.c:238 usb_probe_device+0x13a/0x260 drivers/usb/core/driver.c:293 really_probe+0x3cb/0x1020 drivers/base/dd.c:580 driver_probe_device+0x178/0x350 drivers/base/dd.c:763 bus_for_each_drv+0x16a/0x1f0 drivers/base/bus.c:431 __device_attach+0x301/0x560 drivers/base/dd.c:938 bus_probe_device+0xb8/0x1f0 drivers/base/bus.c:491 device_add+0x11fc/0x1670 drivers/base/core.c:3324 usb_new_device+0xd45/0x1790 drivers/usb/core/hub.c:2556 hub_port_connect+0x1055/0x27a0 drivers/usb/core/hub.c:5276 hub_port_connect_change+0x5d0/0xbf0 drivers/usb/core/hub.c:5416 port_event+0xaee/0x1140 drivers/usb/core/hub.c:5562 hub_event+0x48d/0xd90 drivers/usb/core/hub.c:5644 process_one_work+0x833/0x10c0 kernel/workqueue.c:2276 worker_thread+0xac1/0x1300 kernel/workqueue.c:2422 kthread+0x39a/0x3c0 kernel/kthread.c:313 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:294 Allocated by task 20: kasan_save_stack mm/kasan/common.c:38 [inline] kasan_set_track mm/kasan/common.c:46 [inline] set_alloc_info mm/kasan/common.c:428 [inline] ____kasan_kmalloc+0xc4/0xf0 mm/kasan/common.c:507 kasan_kmalloc include/linux/kasan.h:246 [inline] kmem_cache_alloc_trace+0x96/0x340 mm/slub.c:2940 kmalloc include/linux/slab.h:556 [inline] kzalloc include/linux/slab.h:686 [inline] hidraw_connect+0x54/0x420 drivers/hid/hidraw.c:543 hid_connect+0x55a/0xda0 drivers/hid/hid-core.c:1960 hid_hw_start+0x99/0x100 drivers/hid/hid-core.c:2059 betop_probe+0xa0/0x5b0 drivers/hid/hid-betopff.c:128 hid_device_probe+0x26c/0x410 drivers/hid/hid-core.c:2287 really_probe+0x385/0x1020 drivers/base/dd.c:576 driver_probe_device+0x178/0x350 drivers/base/dd.c:763 bus_for_each_drv+0x16a/0x1f0 drivers/base/bus.c:431 __device_attach+0x301/0x560 drivers/base/dd.c:938 bus_probe_device+0xb8/0x1f0 drivers/base/bus.c:491 device_add+0x11fc/0x1670 drivers/base/core.c:3324 hid_add_device+0xd4f/0xfa0 drivers/hid/hid-core.c:2443 usbhid_probe+0xb4c/0xed0 drivers/hid/usbhid/hid-core.c:1409 usb_probe_interface+0x633/0xb40 drivers/usb/core/driver.c:396 really_probe+0x3cb/0x1020 drivers/base/dd.c:580 driver_probe_device+0x178/0x350 drivers/base/dd.c:763 bus_for_each_drv+0x16a/0x1f0 drivers/base/bus.c:431 __device_attach+0x301/0x560 drivers/base/dd.c:938 bus_probe_device+0xb8/0x1f0 drivers/base/bus.c:491 device_add+0x11fc/0x1670 drivers/base/core.c:3324 usb_set_configuration+0x1a86/0x2100 drivers/usb/core/message.c:2164 usb_generic_driver_probe+0x83/0x140 drivers/usb/core/generic.c:238 usb_probe_device+0x13a/0x260 drivers/usb/core/driver.c:293 really_probe+0x3cb/0x1020 drivers/base/dd.c:580 driver_probe_device+0x178/0x350 drivers/base/dd.c:763 bus_for_each_drv+0x16a/0x1f0 drivers/base/bus.c:431 __device_attach+0x301/0x560 drivers/base/dd.c:938 bus_probe_device+0xb8/0x1f0 drivers/base/bus.c:491 device_add+0x11fc/0x1670 drivers/base/core.c:3324 usb_new_device+0xd45/0x1790 drivers/usb/core/hub.c:2556 hub_port_connect+0x1055/0x27a0 drivers/usb/core/hub.c:5276 hub_port_connect_change+0x5d0/0xbf0 drivers/usb/core/hub.c:5416 port_event+0xaee/0x1140 drivers/usb/core/hub.c:5562 hub_event+0x48d/0xd90 drivers/usb/core/hub.c:5644 process_one_work+0x833/0x10c0 kernel/workqueue.c:2276 worker_thread+0xac1/0x1300 kernel/workqueue.c:2422 kthread+0x39a/0x3c0 kernel/kthread.c:313 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:294 Last potentially related work creation: kasan_save_stack+0x27/0x50 mm/kasan/common.c:38 kasan_record_aux_stack+0xee/0x120 mm/kasan/generic.c:345 insert_work+0x54/0x400 kernel/workqueue.c:1332 __queue_work+0x90e/0xc40 kernel/workqueue.c:1498 queue_work_on+0x111/0x200 kernel/workqueue.c:1525 queue_work include/linux/workqueue.h:507 [inline] call_usermodehelper_exec+0x283/0x470 kernel/umh.c:435 kobject_uevent_env+0x133d/0x1700 lib/kobject_uevent.c:618 device_add+0x1020/0x1670 drivers/base/core.c:3305 device_create_groups_vargs drivers/base/core.c:3983 [inline] device_create+0x241/0x2d0 drivers/base/core.c:4025 vcs_make_sysfs+0x33/0x90 drivers/tty/vt/vc_screen.c:786 vc_allocate+0x66a/0x780 drivers/tty/vt/vt.c:1157 con_install+0x9f/0x880 drivers/tty/vt/vt.c:3349 tty_driver_install_tty drivers/tty/tty_io.c:1323 [inline] tty_init_dev+0xc6/0x4c0 drivers/tty/tty_io.c:1437 tty_open_by_driver drivers/tty/tty_io.c:2102 [inline] tty_open+0x89a/0xdd0 drivers/tty/tty_io.c:2150 chrdev_open+0x53b/0x5f0 fs/char_dev.c:414 do_dentry_open+0x7cb/0x1010 fs/open.c:826 do_open fs/namei.c:3361 [inline] path_openat+0x28e6/0x39b0 fs/namei.c:3494 do_filp_open+0x221/0x460 fs/namei.c:3521 do_sys_openat2+0x124/0x460 fs/open.c:1187 do_sys_open fs/open.c:1203 [inline] __do_sys_open fs/open.c:1211 [inline] __se_sys_open fs/open.c:1207 [inline] __x64_sys_open+0x221/0x270 fs/open.c:1207 do_syscall_64+0x3f/0xb0 arch/x86/entry/common.c:47 entry_SYSCALL_64_after_hwframe+0x44/0xae Second to last potentially related work creation: kasan_save_stack+0x27/0x50 mm/kasan/common.c:38 kasan_record_aux_stack+0xee/0x120 mm/kasan/generic.c:345 insert_work+0x54/0x400 kernel/workqueue.c:1332 __queue_work+0x90e/0xc40 kernel/workqueue.c:1498 queue_work_on+0x111/0x200 kernel/workqueue.c:1525 queue_work include/linux/workqueue.h:507 [inline] call_usermodehelper_exec+0x283/0x470 kernel/umh.c:435 cgroup1_release_agent+0x30b/0x3a0 kernel/cgroup/cgroup-v1.c:808 process_one_work+0x833/0x10c0 kernel/workqueue.c:2276 worker_thread+0xac1/0x1300 kernel/workqueue.c:2422 kthread+0x39a/0x3c0 kernel/kthread.c:313 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:294 The buggy address belongs to the object at ffff8880180fcb00 which belongs to the cache kmalloc-192 of size 192 The buggy address is located 0 bytes to the right of 192-byte region [ffff8880180fcb00, ffff8880180fcbc0) The buggy address belongs to the page: page:ffffea0000603f00 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x180fc flags: 0xfff00000000200(slab|node=0|zone=1|lastcpupid=0x7ff) raw: 00fff00000000200 ffffea00005aeec0 0000000200000002 ffff888011841a00 raw: 0000000000000000 0000000080100010 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 0x12cc0(GFP_KERNEL|__GFP_NOWARN|__GFP_NORETRY), pid 1, ts 2955159711, free_ts 2878953912 prep_new_page mm/page_alloc.c:2358 [inline] get_page_from_freelist+0x779/0xa20 mm/page_alloc.c:3994 __alloc_pages+0x26c/0x5f0 mm/page_alloc.c:5200 alloc_page_interleave+0x22/0x1b0 mm/mempolicy.c:2147 alloc_slab_page mm/slub.c:1645 [inline] allocate_slab+0xf1/0x5b0 mm/slub.c:1785 new_slab mm/slub.c:1848 [inline] new_slab_objects mm/slub.c:2594 [inline] ___slab_alloc+0x1cf/0x350 mm/slub.c:2757 __slab_alloc mm/slub.c:2797 [inline] slab_alloc_node mm/slub.c:2879 [inline] slab_alloc mm/slub.c:2921 [inline] __kmalloc_track_caller+0x2eb/0x390 mm/slub.c:4565 __do_krealloc mm/slab_common.c:1175 [inline] krealloc+0x5c/0xf0 mm/slab_common.c:1208 add_sysfs_param+0xc8/0x7f0 kernel/params.c:633 kernel_add_sysfs_param+0xb0/0x126 kernel/params.c:794 param_sysfs_builtin+0x145/0x1b9 kernel/params.c:833 param_sysfs_init+0x68/0x6c kernel/params.c:952 do_one_initcall+0x1a7/0x400 init/main.c:1249 do_initcall_level+0x14a/0x1f5 init/main.c:1322 do_initcalls+0x4b/0x8c init/main.c:1338 kernel_init_freeable+0x3fd/0x58a init/main.c:1560 kernel_init+0xd/0x290 init/main.c:1447 page last free stack trace: reset_page_owner include/linux/page_owner.h:24 [inline] free_pages_prepare mm/page_alloc.c:1298 [inline] free_pcp_prepare+0x3ea/0x420 mm/page_alloc.c:1342 free_unref_page_prepare mm/page_alloc.c:3250 [inline] free_unref_page+0x7b/0x280 mm/page_alloc.c:3298 __vunmap+0x926/0xa60 mm/vmalloc.c:2566 free_work+0x66/0x90 mm/vmalloc.c:80 process_one_work+0x833/0x10c0 kernel/workqueue.c:2276 worker_thread+0xac1/0x1300 kernel/workqueue.c:2422 kthread+0x39a/0x3c0 kernel/kthread.c:313 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:294 Memory state around the buggy address: ffff8880180fca80: fb fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc ffff8880180fcb0