================================================================== BUG: KASAN: slab-out-of-bounds in read_descriptors+0x23c/0x290 drivers/usb/core/sysfs.c:883 Read of size 2 at addr ffff0000d8e96aaa by task udevd/4228 CPU: 1 PID: 4228 Comm: udevd Not tainted 6.1.34-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/25/2023 Call trace: dump_backtrace+0x1c8/0x1f4 arch/arm64/kernel/stacktrace.c:158 show_stack+0x2c/0x3c arch/arm64/kernel/stacktrace.c:165 __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0x108/0x170 lib/dump_stack.c:106 print_address_description mm/kasan/report.c:284 [inline] print_report+0x174/0x4c0 mm/kasan/report.c:395 kasan_report+0xd4/0x130 mm/kasan/report.c:495 __asan_report_load2_noabort+0x2c/0x38 mm/kasan/report_generic.c:349 read_descriptors+0x23c/0x290 drivers/usb/core/sysfs.c:883 sysfs_kf_bin_read+0x19c/0x1d4 fs/sysfs/file.c:97 kernfs_file_read_iter fs/kernfs/file.c:247 [inline] kernfs_fop_read_iter+0x3ac/0x5c8 fs/kernfs/file.c:276 call_read_iter include/linux/fs.h:2199 [inline] new_sync_read fs/read_write.c:389 [inline] vfs_read+0x5bc/0x8ac fs/read_write.c:470 ksys_read+0x15c/0x26c fs/read_write.c:613 __do_sys_read fs/read_write.c:623 [inline] __se_sys_read fs/read_write.c:621 [inline] __arm64_sys_read+0x7c/0x90 fs/read_write.c:621 __invoke_syscall arch/arm64/kernel/syscall.c:38 [inline] invoke_syscall+0x98/0x2c0 arch/arm64/kernel/syscall.c:52 el0_svc_common+0x138/0x258 arch/arm64/kernel/syscall.c:142 do_el0_svc+0x64/0x218 arch/arm64/kernel/syscall.c:206 el0_svc+0x58/0x168 arch/arm64/kernel/entry-common.c:637 el0t_64_sync_handler+0x84/0xf0 arch/arm64/kernel/entry-common.c:655 el0t_64_sync+0x18c/0x190 arch/arm64/kernel/entry.S:581 Allocated by task 4226: kasan_save_stack mm/kasan/common.c:45 [inline] kasan_set_track+0x4c/0x80 mm/kasan/common.c:52 kasan_save_alloc_info+0x24/0x30 mm/kasan/generic.c:505 ____kasan_kmalloc mm/kasan/common.c:374 [inline] __kasan_kmalloc+0xac/0xc4 mm/kasan/common.c:383 kasan_kmalloc include/linux/kasan.h:211 [inline] __do_kmalloc_node mm/slab_common.c:955 [inline] __kmalloc+0xd8/0x1c4 mm/slab_common.c:968 kmalloc include/linux/slab.h:558 [inline] kzalloc include/linux/slab.h:689 [inline] usb_get_configuration+0xd8/0x4048 drivers/usb/core/config.c:882 usb_enumerate_device drivers/usb/core/hub.c:2407 [inline] usb_new_device+0x134/0x142c drivers/usb/core/hub.c:2545 hub_port_connect drivers/usb/core/hub.c:5355 [inline] hub_port_connect_change drivers/usb/core/hub.c:5499 [inline] port_event drivers/usb/core/hub.c:5655 [inline] hub_event+0x23dc/0x44a0 drivers/usb/core/hub.c:5737 process_one_work+0x7ac/0x1404 kernel/workqueue.c:2289 worker_thread+0x8e4/0xfec kernel/workqueue.c:2436 kthread+0x250/0x2d8 kernel/kthread.c:376 ret_from_fork+0x10/0x20 arch/arm64/kernel/entry.S:860 The buggy address belongs to the object at ffff0000d8e96800 which belongs to the cache kmalloc-1k of size 1024 The buggy address is located 682 bytes inside of 1024-byte region [ffff0000d8e96800, ffff0000d8e96c00) The buggy address belongs to the physical page: page:000000003eb4bdce refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x118e90 head:000000003eb4bdce order:3 compound_mapcount:0 compound_pincount:0 flags: 0x5ffc00000010200(slab|head|node=0|zone=2|lastcpupid=0x7ff) raw: 05ffc00000010200 0000000000000000 dead000000000122 ffff0000c0002780 raw: 0000000000000000 0000000000100010 00000001ffffffff 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff0000d8e96980: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff0000d8e96a00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff0000d8e96a80: 00 00 00 00 00 fc fc fc fc fc fc fc fc fc fc fc ^ ffff0000d8e96b00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff0000d8e96b80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ==================================================================