==================================================================
BUG: KASAN: slab-use-after-free in find_endpoint drivers/usb/gadget/udc/dummy_hcd.c:1618 [inline]
BUG: KASAN: slab-use-after-free in dummy_timer+0xcdb/0x4cf0 drivers/usb/gadget/udc/dummy_hcd.c:1890
Read of size 1 at addr ffff888058af18e8 by task udevd/21271
CPU: 1 UID: 0 PID: 21271 Comm: udevd Tainted: G L syzkaller #0 PREEMPT(full)
Tainted: [L]=SOFTLOCKUP
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/24/2026
Call Trace:
dump_stack_lvl+0xe8/0x150 lib/dump_stack.c:120
print_address_description+0x55/0x1e0 mm/kasan/report.c:378
print_report+0x58/0x70 mm/kasan/report.c:482
kasan_report+0x117/0x150 mm/kasan/report.c:595
find_endpoint drivers/usb/gadget/udc/dummy_hcd.c:1618 [inline]
dummy_timer+0xcdb/0x4cf0 drivers/usb/gadget/udc/dummy_hcd.c:1890
__run_hrtimer kernel/time/hrtimer.c:2068 [inline]
__hrtimer_run_queues+0x3bc/0xa10 kernel/time/hrtimer.c:2125
hrtimer_run_softirq+0x1e3/0x2e0 kernel/time/hrtimer.c:2142
handle_softirqs+0x226/0x860 kernel/softirq.c:645
__do_softirq kernel/softirq.c:679 [inline]
invoke_softirq kernel/softirq.c:519 [inline]
__irq_exit_rcu+0xcb/0x220 kernel/softirq.c:767
irq_exit_rcu+0x9/0x30 kernel/softirq.c:784
instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1062 [inline]
sysvec_apic_timer_interrupt+0xa6/0xc0 arch/x86/kernel/apic/apic.c:1062
asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:674
RIP: 0010:lock_release+0x2e1/0x3c0 kernel/locking/lockdep.c:5934
Code: 2f f1 11 00 00 00 00 eb b5 e8 9b 7e 3f 0a f7 c3 00 02 00 00 74 b9 65 48 8b 05 f3 e9 f0 11 48 3b 44 24 28 75 48 fb 48 83 c4 30 <5b> 41 5c 41 5d 41 5e 41 5f 5d e9 50 85 42 0a cc 48 8d 3d b8 1b da
RSP: 0018:ffffc9001018f468 EFLAGS: 00000282
RAX: 281683beb785be00 RBX: 0000000000000206 RCX: 0000000000000046
RDX: ffffc9001018f501 RSI: ffffffff8e6fcfc8 RDI: ffffffff8c6d8280
RBP: ffff88802073ca58 R08: ffffc9001018fee0 R09: 0000000000000000
R10: ffffc9001018f598 R11: fffff52002031eb5 R12: 0000000000000001
R13: 0000000000000001 R14: ffffffff8ed5ca60 R15: ffff88802073be80
rcu_lock_release include/linux/rcupdate.h:319 [inline]
rcu_read_unlock include/linux/rcupdate.h:880 [inline]
class_rcu_destructor include/linux/rcupdate.h:1216 [inline]
unwind_next_frame+0x1baa/0x2550 arch/x86/kernel/unwind_orc.c:709
arch_stack_walk+0x11b/0x150 arch/x86/kernel/stacktrace.c:25
stack_trace_save+0xa9/0x100 kernel/stacktrace.c:122
kasan_save_stack mm/kasan/common.c:57 [inline]
kasan_save_track+0x3e/0x80 mm/kasan/common.c:78
kasan_save_free_info+0x40/0x50 mm/kasan/generic.c:584
poison_slab_object mm/kasan/common.c:253 [inline]
__kasan_slab_free+0x5c/0x80 mm/kasan/common.c:285
kasan_slab_free include/linux/kasan.h:235 [inline]
slab_free_hook mm/slub.c:2748 [inline]
slab_free mm/slub.c:6499 [inline]
kfree+0x1c5/0x650 mm/slub.c:6792
tomoyo_path_perm+0x403/0x560 security/tomoyo/file.c:847
security_inode_getattr+0x12b/0x310 security/security.c:1895
vfs_getattr+0x23/0x70 fs/stat.c:259
vfs_statx_path+0x2b/0x230 fs/stat.c:299
vfs_statx+0x12e/0x200 fs/stat.c:356
vfs_fstatat+0x11b/0x170 fs/stat.c:373
__do_sys_newfstatat fs/stat.c:538 [inline]
__se_sys_newfstatat fs/stat.c:532 [inline]
__x64_sys_newfstatat+0x151/0x200 fs/stat.c:532
do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline]
do_syscall_64+0x166/0x520 arch/x86/entry/syscall_64.c:84
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f8ed5b11b0a
Code: 48 8b 15 f1 f2 0d 00 f7 d8 64 89 02 b8 ff ff ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 41 89 ca b8 06 01 00 00 0f 05 <3d> 00 f0 ff ff 77 07 31 c0 c3 0f 1f 40 00 48 8b 15 b9 f2 0d 00 f7
RSP: 002b:00007fff86fbedc8 EFLAGS: 00000246 ORIG_RAX: 0000000000000106
RAX: ffffffffffffffda RBX: 0000000000006180 RCX: 00007f8ed5b11b0a
RDX: 00007fff86fbedf0 RSI: 000056021fbdbe70 RDI: 00000000ffffff9c
RBP: 0000000000000000 R08: 0000000000000000 R09: 000056021fbdb590
R10: 0000000000000100 R11: 0000000000000246 R12: 0000000000000000
R13: 0000000000000000 R14: 000056021fbdbe70 R15: 000056021fbf5ed0
Allocated by task 27564:
kasan_save_stack mm/kasan/common.c:57 [inline]
kasan_save_track+0x3e/0x80 mm/kasan/common.c:78
poison_kmalloc_redzone mm/kasan/common.c:398 [inline]
__kasan_kmalloc+0x93/0xb0 mm/kasan/common.c:415
kasan_kmalloc include/linux/kasan.h:263 [inline]
__do_kmalloc_node mm/slub.c:5414 [inline]
__kmalloc_noprof+0x36b/0x720 mm/slub.c:5439
_kmalloc_noprof include/linux/slab.h:995 [inline]
_kzalloc_noprof include/linux/slab.h:1312 [inline]
copy_splice_read+0x16f/0xaa0 fs/splice.c:336
do_splice_read fs/splice.c:979 [inline]
splice_direct_to_actor+0x4b6/0xcb0 fs/splice.c:1084
do_splice_direct_actor fs/splice.c:1202 [inline]
do_splice_direct+0x195/0x290 fs/splice.c:1228
do_sendfile+0x52e/0x7c0 fs/read_write.c:1371
__do_sys_sendfile64 fs/read_write.c:1432 [inline]
__se_sys_sendfile64+0x144/0x1a0 fs/read_write.c:1418
do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline]
do_syscall_64+0x166/0x520 arch/x86/entry/syscall_64.c:84
entry_SYSCALL_64_after_hwframe+0x77/0x7f
Freed by task 27564:
kasan_save_stack mm/kasan/common.c:57 [inline]
kasan_save_track+0x3e/0x80 mm/kasan/common.c:78
kasan_save_free_info+0x40/0x50 mm/kasan/generic.c:584
poison_slab_object mm/kasan/common.c:253 [inline]
__kasan_slab_free+0x5c/0x80 mm/kasan/common.c:285
kasan_slab_free include/linux/kasan.h:235 [inline]
slab_free_hook mm/slub.c:2748 [inline]
slab_free mm/slub.c:6499 [inline]
kfree+0x1c5/0x650 mm/slub.c:6792
copy_splice_read+0x92a/0xaa0 fs/splice.c:396
do_splice_read fs/splice.c:979 [inline]
splice_direct_to_actor+0x4b6/0xcb0 fs/splice.c:1084
do_splice_direct_actor fs/splice.c:1202 [inline]
do_splice_direct+0x195/0x290 fs/splice.c:1228
do_sendfile+0x52e/0x7c0 fs/read_write.c:1371
__do_sys_sendfile64 fs/read_write.c:1432 [inline]
__se_sys_sendfile64+0x144/0x1a0 fs/read_write.c:1418
do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline]
do_syscall_64+0x166/0x520 arch/x86/entry/syscall_64.c:84
entry_SYSCALL_64_after_hwframe+0x77/0x7f
The buggy address belongs to the object at ffff888058af1800
which belongs to the cache kmalloc-512 of size 512
The buggy address is located 232 bytes inside of
freed 512-byte region [ffff888058af1800, ffff888058af1a00)
The buggy address belongs to the physical page:
page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x58af0
head: order:2 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0
flags: 0xfff00000000040(head|node=0|zone=1|lastcpupid=0x7ff)
page_type: f5(slab)
raw: 00fff00000000040 ffff88801b041c80 dead000000000100 dead000000000122
raw: 0000000000000000 0000000000100010 00000000f5000000 0000000000000000
head: 00fff00000000040 ffff88801b041c80 dead000000000100 dead000000000122
head: 0000000000000000 0000000000100010 00000000f5000000 0000000000000000
head: 00fff00000000002 ffffffffffffff01 00000000ffffffff 00000000ffffffff
head: ffffffffffffffff 0000000000000000 00000000ffffffff 0000000000000004
page dumped because: kasan: bad access detected
page_owner tracks the page as allocated
page last allocated via order 2, migratetype Unmovable, gfp_mask 0xd20c0(__GFP_IO|__GFP_FS|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC), pid 5617, tgid 5617 (syz-executor), ts 77033927958
set_page_owner include/linux/page_owner.h:33 [inline]
post_alloc_hook+0x1f9/0x250 mm/page_alloc.c:1871
prep_new_page mm/page_alloc.c:1879 [inline]
get_page_from_freelist+0x2209/0x2280 mm/page_alloc.c:3943
__alloc_frozen_pages_noprof+0x217/0x5a0 mm/page_alloc.c:5436
alloc_slab_page mm/slub.c:3347 [inline]
allocate_slab+0x7d/0x620 mm/slub.c:3462
new_slab mm/slub.c:3513 [inline]
refill_objects+0x2d5/0x350 mm/slub.c:7410
refill_sheaf mm/slub.c:2885 [inline]
__pcs_replace_empty_main+0x2c8/0x6c0 mm/slub.c:4774
alloc_from_pcs mm/slub.c:4850 [inline]
slab_alloc_node mm/slub.c:4984 [inline]
__kmalloc_cache_noprof+0x39b/0x600 mm/slub.c:5559
_kmalloc_noprof include/linux/slab.h:991 [inline]
_kzalloc_noprof include/linux/slab.h:1312 [inline]
inetdev_init+0x6c/0x4d0 net/ipv4/devinet.c:273
inetdev_event+0x307/0x15e0 net/ipv4/devinet.c:1590
notifier_call_chain+0x1a5/0x3d0 kernel/notifier.c:85
call_netdevice_notifiers_extack net/core/dev.c:2313 [inline]
call_netdevice_notifiers net/core/dev.c:2327 [inline]
register_netdevice+0x18a4/0x1eb0 net/core/dev.c:11515
veth_newlink+0x4d7/0xdd0 drivers/net/veth.c:1870
rtnl_newlink_create+0x305/0x7b0 net/core/rtnetlink.c:3969
__rtnl_newlink net/core/rtnetlink.c:4098 [inline]
rtnl_newlink+0x166d/0x1c30 net/core/rtnetlink.c:4215
rtnetlink_rcv_msg+0x802/0xc00 net/core/rtnetlink.c:7132
netlink_rcv_skb+0x226/0x4a0 net/netlink/af_netlink.c:2556
page last free pid 1 tgid 1 ts 21346073637 stack trace:
reset_page_owner include/linux/page_owner.h:26 [inline]
__free_pages_prepare mm/page_alloc.c:1418 [inline]
free_pages_prepare+0x9eb/0xaf0 mm/page_alloc.c:1463
__free_contig_range_common+0x174/0x340 mm/page_alloc.c:7072
destroy_args+0x4e5/0x570 mm/debug_vm_pgtable.c:993
debug_vm_pgtable+0x3f8/0x410 mm/debug_vm_pgtable.c:1368
do_one_initcall+0x250/0x870 init/main.c:1359
do_initcall_level+0x10a/0x1a0 init/main.c:1421
do_initcalls+0x59/0xa0 init/main.c:1437
kernel_init_freeable+0x29d/0x3e0 init/main.c:1672
kernel_init+0x22/0x1d0 init/main.c:1562
ret_from_fork+0x514/0xb70 arch/x86/kernel/process.c:158
ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245
Memory state around the buggy address:
ffff888058af1780: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
ffff888058af1800: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
>ffff888058af1880: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
^
ffff888058af1900: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
ffff888058af1980: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
==================================================================
----------------
Code disassembly (best guess), 1 bytes skipped:
0: f1 int1
1: 11 00 adc %eax,(%rax)
3: 00 00 add %al,(%rax)
5: 00 eb add %ch,%bl
7: b5 e8 mov $0xe8,%ch
9: 9b fwait
a: 7e 3f jle 0x4b
c: 0a f7 or %bh,%dh
e: c3 ret
f: 00 02 add %al,(%rdx)
11: 00 00 add %al,(%rax)
13: 74 b9 je 0xffffffce
15: 65 48 8b 05 f3 e9 f0 mov %gs:0x11f0e9f3(%rip),%rax # 0x11f0ea10
1c: 11
1d: 48 3b 44 24 28 cmp 0x28(%rsp),%rax
22: 75 48 jne 0x6c
24: fb sti
25: 48 83 c4 30 add $0x30,%rsp
* 29: 5b pop %rbx <-- trapping instruction
2a: 41 5c pop %r12
2c: 41 5d pop %r13
2e: 41 5e pop %r14
30: 41 5f pop %r15
32: 5d pop %rbp
33: e9 50 85 42 0a jmp 0xa428588
38: cc int3
39: 48 rex.W
3a: 8d .byte 0x8d
3b: 3d .byte 0x3d
3c: b8 .byte 0xb8
3d: 1b da sbb %edx,%ebx