audit: type=1804 audit(1643444338.152:620): pid=23628 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=open_writers comm="syz-executor.1" name="/root/syzkaller-testdir703355814/syzkaller.KU8bmK/52/file0/bus" dev="sda1" ino=14097 res=1 ================================================================== BUG: KASAN: use-after-free in __lock_acquire+0x2cb4/0x3ff0 kernel/locking/lockdep.c:3295 Read of size 8 at addr ffff8880a9cc8360 by task kworker/0:0/20332 CPU: 0 PID: 20332 Comm: kworker/0:0 Not tainted 4.19.211-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Workqueue: events sco_sock_timeout Call Trace: __dump_stack lib/dump_stack.c:77 [inline] dump_stack+0x1fc/0x2ef lib/dump_stack.c:118 print_address_description.cold+0x54/0x219 mm/kasan/report.c:256 kasan_report_error.cold+0x8a/0x1b9 mm/kasan/report.c:354 kasan_report mm/kasan/report.c:412 [inline] __asan_report_load8_noabort+0x88/0x90 mm/kasan/report.c:433 __lock_acquire+0x2cb4/0x3ff0 kernel/locking/lockdep.c:3295 lock_acquire+0x170/0x3c0 kernel/locking/lockdep.c:3908 __raw_spin_lock include/linux/spinlock_api_smp.h:142 [inline] _raw_spin_lock+0x2a/0x40 kernel/locking/spinlock.c:144 spin_lock include/linux/spinlock.h:329 [inline] sco_sock_timeout+0x7b/0x1b0 net/bluetooth/sco.c:95 process_one_work+0x864/0x1570 kernel/workqueue.c:2153 worker_thread+0x64c/0x1130 kernel/workqueue.c:2296 kthread+0x33f/0x460 kernel/kthread.c:259 ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:415 Allocated by task 22519: kmem_cache_alloc_trace+0x12f/0x380 mm/slab.c:3625 kmalloc include/linux/slab.h:515 [inline] kzalloc include/linux/slab.h:709 [inline] perf_event_alloc.part.0+0xb9/0x2eb0 kernel/events/core.c:10072 perf_event_alloc kernel/events/core.c:10559 [inline] __do_sys_perf_event_open kernel/events/core.c:10660 [inline] __se_sys_perf_event_open+0x550/0x2720 kernel/events/core.c:10549 do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe Freed by task 22540: __cache_free mm/slab.c:3503 [inline] kfree+0xcc/0x210 mm/slab.c:3822 __rcu_reclaim kernel/rcu/rcu.h:236 [inline] rcu_do_batch kernel/rcu/tree.c:2584 [inline] invoke_rcu_callbacks kernel/rcu/tree.c:2897 [inline] __rcu_process_callbacks kernel/rcu/tree.c:2864 [inline] rcu_process_callbacks+0x8ff/0x18b0 kernel/rcu/tree.c:2881 __do_softirq+0x265/0x980 kernel/softirq.c:292 The buggy address belongs to the object at ffff8880a9cc82c0 which belongs to the cache kmalloc-2048 of size 2048 The buggy address is located 160 bytes inside of 2048-byte region [ffff8880a9cc82c0, ffff8880a9cc8ac0) The buggy address belongs to the page: page:ffffea0002a73200 count:1 mapcount:0 mapping:ffff88813bff0c40 index:0xffff8880a9cc93c0 compound_mapcount: 0 flags: 0xfff00000008100(slab|head) raw: 00fff00000008100 ffffea000266f508 ffffea00026f7a08 ffff88813bff0c40 raw: ffff8880a9cc93c0 ffff8880a9cc82c0 0000000100000001 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff8880a9cc8200: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff8880a9cc8280: fc fc fc fc fc fc fc fc fb fb fb fb fb fb fb fb >ffff8880a9cc8300: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff8880a9cc8380: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff8880a9cc8400: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb Started in network mode ==================================================================