usb 3-1: New USB device found, idVendor=731e, idProduct=128c, bcdDevice=ed.06 usb 3-1: New USB device strings: Mfr=0, Product=0, SerialNumber=0 usb 3-1: MIDIStreaming interface descriptor not found ================================================================== BUG: KASAN: slab-out-of-bounds in snd_usbmidi_get_ms_info+0xeaf/0x10e0 sound/usb/midi.c:1982 Read of size 1 at addr ffff88812e91f0a2 by task kworker/1:2/27456 CPU: 1 PID: 27456 Comm: kworker/1:2 Not tainted 5.13.0-rc1-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+0x143/0x1db lib/dump_stack.c:120 print_address_description.constprop.0.cold+0x5b/0x2f8 mm/kasan/report.c:233 __kasan_report mm/kasan/report.c:419 [inline] kasan_report.cold+0x7c/0xd8 mm/kasan/report.c:436 snd_usbmidi_get_ms_info+0xeaf/0x10e0 sound/usb/midi.c:1982 __snd_usbmidi_create+0x393/0x1ba0 sound/usb/midi.c:2485 snd_usb_create_quirk+0xa5/0xe0 sound/usb/quirks.c:604 usb_audio_probe+0xcf0/0x2c90 sound/usb/card.c:796 usb_probe_interface+0x315/0x7f0 drivers/usb/core/driver.c:396 really_probe+0x291/0xf60 drivers/base/dd.c:576 driver_probe_device+0x298/0x410 drivers/base/dd.c:763 __device_attach_driver+0x203/0x2c0 drivers/base/dd.c:870 bus_for_each_drv+0x15f/0x1e0 drivers/base/bus.c:431 __device_attach+0x228/0x4b0 drivers/base/dd.c:938 bus_probe_device+0x1e4/0x290 drivers/base/bus.c:491 device_add+0xbe0/0x2100 drivers/base/core.c:3319 usb_set_configuration+0x113f/0x1910 drivers/usb/core/message.c:2164 usb_generic_driver_probe+0xba/0x100 drivers/usb/core/generic.c:238 usb_probe_device+0xd9/0x2c0 drivers/usb/core/driver.c:293 really_probe+0x291/0xf60 drivers/base/dd.c:576 driver_probe_device+0x298/0x410 drivers/base/dd.c:763 __device_attach_driver+0x203/0x2c0 drivers/base/dd.c:870 bus_for_each_drv+0x15f/0x1e0 drivers/base/bus.c:431 __device_attach+0x228/0x4b0 drivers/base/dd.c:938 bus_probe_device+0x1e4/0x290 drivers/base/bus.c:491 device_add+0xbe0/0x2100 drivers/base/core.c:3319 usb_new_device.cold+0x721/0x1058 drivers/usb/core/hub.c:2556 hub_port_connect drivers/usb/core/hub.c:5276 [inline] hub_port_connect_change drivers/usb/core/hub.c:5416 [inline] port_event drivers/usb/core/hub.c:5562 [inline] hub_event+0x2357/0x4330 drivers/usb/core/hub.c:5644 process_one_work+0x98d/0x1580 kernel/workqueue.c:2275 worker_thread+0x64c/0x1120 kernel/workqueue.c:2421 kthread+0x38c/0x460 kernel/kthread.c:313 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:294 Allocated by task 27456: kasan_save_stack+0x1b/0x40 mm/kasan/common.c:38 kasan_set_track mm/kasan/common.c:46 [inline] set_alloc_info mm/kasan/common.c:428 [inline] ____kasan_kmalloc mm/kasan/common.c:507 [inline] __kasan_kmalloc+0x7c/0x90 mm/kasan/common.c:516 kmalloc include/linux/slab.h:561 [inline] usb_get_configuration+0x321/0x3d60 drivers/usb/core/config.c:919 usb_enumerate_device drivers/usb/core/hub.c:2389 [inline] usb_new_device+0x42c/0x7a0 drivers/usb/core/hub.c:2525 hub_port_connect drivers/usb/core/hub.c:5276 [inline] hub_port_connect_change drivers/usb/core/hub.c:5416 [inline] port_event drivers/usb/core/hub.c:5562 [inline] hub_event+0x2357/0x4330 drivers/usb/core/hub.c:5644 process_one_work+0x98d/0x1580 kernel/workqueue.c:2275 worker_thread+0x64c/0x1120 kernel/workqueue.c:2421 kthread+0x38c/0x460 kernel/kthread.c:313 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:294 The buggy address belongs to the object at ffff88812e91f080 which belongs to the cache kmalloc-64 of size 64 The buggy address is located 34 bytes inside of 64-byte region [ffff88812e91f080, ffff88812e91f0c0) The buggy address belongs to the page: page:ffffea0004ba47c0 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x12e91f flags: 0x200000000000200(slab|node=0|zone=2) raw: 0200000000000200 ffffea00044df0c0 0000001800000016 ffff888100041640 raw: 0000000000000000 0000000000200020 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 0x12c40(GFP_NOFS|__GFP_NOWARN|__GFP_NORETRY), pid 31681, ts 3346092481707, free_ts 3345832189733 prep_new_page mm/page_alloc.c:2358 [inline] get_page_from_freelist+0xc97/0x26a0 mm/page_alloc.c:3994 __alloc_pages+0x1b2/0x4f0 mm/page_alloc.c:5200 alloc_pages+0x18c/0x2a0 mm/mempolicy.c:2272 alloc_slab_page mm/slub.c:1644 [inline] allocate_slab+0x2c5/0x4c0 mm/slub.c:1784 new_slab mm/slub.c:1847 [inline] new_slab_objects mm/slub.c:2593 [inline] ___slab_alloc+0x476/0x7b0 mm/slub.c:2756 __slab_alloc+0x68/0x80 mm/slub.c:2796 slab_alloc_node mm/slub.c:2878 [inline] slab_alloc mm/slub.c:2920 [inline] __kmalloc+0x2f4/0x310 mm/slub.c:4063 kmalloc include/linux/slab.h:561 [inline] kzalloc include/linux/slab.h:686 [inline] tomoyo_encode2.part.0+0xe9/0x3a0 security/tomoyo/realpath.c:45 tomoyo_encode2 security/tomoyo/realpath.c:31 [inline] tomoyo_encode+0x28/0x50 security/tomoyo/realpath.c:80 tomoyo_realpath_from_path+0x186/0x620 security/tomoyo/realpath.c:288 tomoyo_get_realpath security/tomoyo/file.c:151 [inline] tomoyo_path_perm+0x21b/0x400 security/tomoyo/file.c:822 security_inode_getattr+0xcf/0x140 security/security.c:1332 vfs_getattr fs/stat.c:139 [inline] vfs_statx+0x164/0x390 fs/stat.c:207 vfs_fstatat fs/stat.c:225 [inline] vfs_lstat include/linux/fs.h:3384 [inline] __do_sys_newlstat+0x91/0x110 fs/stat.c:380 do_syscall_64+0x3a/0xb0 arch/x86/entry/common.c:47 entry_SYSCALL_64_after_hwframe+0x44/0xae 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+0x216/0x390 mm/page_alloc.c:1342 free_unref_page_prepare mm/page_alloc.c:3250 [inline] free_unref_page_list+0x199/0x740 mm/page_alloc.c:3318 release_pages+0x4d5/0x1a00 mm/swap.c:972 tlb_batch_pages_flush mm/mmu_gather.c:49 [inline] tlb_flush_mmu_free mm/mmu_gather.c:242 [inline] tlb_flush_mmu mm/mmu_gather.c:249 [inline] tlb_finish_mmu+0x165/0x8c0 mm/mmu_gather.c:340 exit_mmap+0x2c2/0x590 mm/mmap.c:3210 __mmput kernel/fork.c:1096 [inline] mmput+0xce/0x3d0 kernel/fork.c:1117 exit_mm kernel/exit.c:502 [inline] do_exit+0xb0a/0x28d0 kernel/exit.c:813 do_group_exit+0x125/0x310 kernel/exit.c:923 __do_sys_exit_group kernel/exit.c:934 [inline] __se_sys_exit_group kernel/exit.c:932 [inline] __x64_sys_exit_group+0x3a/0x50 kernel/exit.c:932 do_syscall_64+0x3a/0xb0 arch/x86/entry/common.c:47 entry_SYSCALL_64_after_hwframe+0x44/0xae Memory state around the buggy address: ffff88812e91ef80: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff88812e91f000: fa fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc >ffff88812e91f080: 00 00 00 00 02 fc fc fc fc fc fc fc fc fc fc fc ^ ffff88812e91f100: fa fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc ffff88812e91f180: fa fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc ==================================================================