==================================================================
BUG: KASAN: use-after-free in bpf_tree_comp kernel/bpf/core.c:437 [inline]
BUG: KASAN: use-after-free in __lt_find include/linux/rbtree_latch.h:115 [inline]
BUG: KASAN: use-after-free in latch_tree_find include/linux/rbtree_latch.h:208 [inline]
BUG: KASAN: use-after-free in bpf_prog_kallsyms_find.part.0+0x21e/0x270 kernel/bpf/core.c:511
Read of size 8 at addr ffff888053bb8500 by task systemd-udevd/3715

CPU: 0 PID: 3715 Comm: systemd-udevd Not tainted 4.19.139-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
 __dump_stack lib/dump_stack.c:77 [inline]
 dump_stack+0x1fc/0x2fe lib/dump_stack.c:118
 print_address_description.cold+0x54/0x219 mm/kasan/report.c:256
 kasan_report_error.cold+0x8a/0x1c7 mm/kasan/report.c:354
 kasan_report mm/kasan/report.c:412 [inline]
 __asan_report_load8_noabort+0x88/0x90 mm/kasan/report.c:433
 bpf_tree_comp kernel/bpf/core.c:437 [inline]
 __lt_find include/linux/rbtree_latch.h:115 [inline]
 latch_tree_find include/linux/rbtree_latch.h:208 [inline]
 bpf_prog_kallsyms_find.part.0+0x21e/0x270 kernel/bpf/core.c:511
 bpf_prog_kallsyms_find include/linux/rcupdate.h:628 [inline]
 is_bpf_text_address+0x196/0x1b0 kernel/bpf/core.c:546
 kernel_text_address kernel/extable.c:152 [inline]
 kernel_text_address+0xbd/0xf0 kernel/extable.c:122
 __kernel_text_address+0x9/0x30 kernel/extable.c:107
 unwind_get_return_address arch/x86/kernel/unwind_orc.c:297 [inline]
 unwind_get_return_address+0x51/0x90 arch/x86/kernel/unwind_orc.c:292
 __save_stack_trace+0xaf/0x190 arch/x86/kernel/stacktrace.c:45
 save_stack mm/kasan/kasan.c:448 [inline]
 set_track mm/kasan/kasan.c:460 [inline]
 kasan_kmalloc+0xeb/0x160 mm/kasan/kasan.c:553
 slab_post_alloc_hook mm/slab.h:445 [inline]
 slab_alloc mm/slab.c:3397 [inline]
 kmem_cache_alloc+0x110/0x370 mm/slab.c:3557
 getname_flags+0xce/0x590 fs/namei.c:140
 user_path_at_empty+0x2a/0x50 fs/namei.c:2609
 user_path_at include/linux/namei.h:57 [inline]
 vfs_statx+0x113/0x210 fs/stat.c:185
 vfs_stat include/linux/fs.h:3129 [inline]
 __do_sys_newstat fs/stat.c:337 [inline]
 __se_sys_newstat+0x96/0x120 fs/stat.c:333
 do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293
 entry_SYSCALL_64_after_hwframe+0x49/0xbe
RIP: 0033:0x7f90c78d6295
Code: 00 00 00 e8 5d 01 00 00 48 83 c4 18 c3 0f 1f 84 00 00 00 00 00 83 ff 01 48 89 f0 77 30 48 89 c7 48 89 d6 b8 04 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 03 f3 c3 90 48 8b 15 d1 db 2b 00 f7 d8 64 89
RSP: 002b:00007ffc2f9fd208 EFLAGS: 00000246 ORIG_RAX: 0000000000000004
RAX: ffffffffffffffda RBX: 000055d1942bec30 RCX: 00007f90c78d6295
RDX: 00007ffc2f9fd210 RSI: 00007ffc2f9fd210 RDI: 000055d1942bec18
RBP: 00054486b145c780 R08: c0fffe8100000000 R09: 0000000000000000
R10: 0005a1ac222dab38 R11: 0000000000000246 R12: 000055d194364c40
R13: 000055d1942bea60 R14: 0000000000000000 R15: 000055d1942bea78

Allocated by task 24180:
 kmem_cache_alloc_trace+0x12f/0x380 mm/slab.c:3625
 kmalloc include/linux/slab.h:515 [inline]
 kzalloc include/linux/slab.h:709 [inline]
 bpf_prog_alloc+0x20b/0x290 kernel/bpf/core.c:90
 jit_subprogs kernel/bpf/verifier.c:5849 [inline]
 fixup_call_args kernel/bpf/verifier.c:5968 [inline]
 bpf_check+0x599b/0x9aaa kernel/bpf/verifier.c:6375
 bpf_prog_load+0xcca/0x1240 kernel/bpf/syscall.c:1445
 __do_sys_bpf kernel/bpf/syscall.c:2418 [inline]
 __se_sys_bpf+0xf22/0x3a20 kernel/bpf/syscall.c:2379
 do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293
 entry_SYSCALL_64_after_hwframe+0x49/0xbe

Freed by task 7354:
 __cache_free mm/slab.c:3503 [inline]
 kfree+0xcc/0x210 mm/slab.c:3822
 bpf_jit_free+0x9b/0x300
 bpf_prog_free_deferred+0x18f/0x410 kernel/bpf/core.c:1809
 process_one_work+0x864/0x1570 kernel/workqueue.c:2155
 worker_thread+0x64c/0x1130 kernel/workqueue.c:2298
 kthread+0x30b/0x410 kernel/kthread.c:246
 ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:415

The buggy address belongs to the object at ffff888053bb8480
 which belongs to the cache kmalloc-256 of size 256
The buggy address is located 128 bytes inside of
 256-byte region [ffff888053bb8480, ffff888053bb8580)
The buggy address belongs to the page:
page:ffffea00014eee00 count:1 mapcount:0 mapping:ffff88812c39c7c0 index:0x0
flags: 0xfffe0000000100(slab)
raw: 00fffe0000000100 ffffea0002439c08 ffffea00014eeec8 ffff88812c39c7c0
raw: 0000000000000000 ffff888053bb80c0 000000010000000c 0000000000000000
page dumped because: kasan: bad access detected

Memory state around the buggy address:
 ffff888053bb8400: fb fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc
 ffff888053bb8480: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
>ffff888053bb8500: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
                   ^
 ffff888053bb8580: fc fc fc fc fc fc fc fc fb fb fb fb fb fb fb fb
 ffff888053bb8600: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
==================================================================