==================================================================
BUG: KASAN: null-ptr-deref in instrument_atomic_read include/linux/instrumented.h:68 [inline]
BUG: KASAN: null-ptr-deref in _test_bit include/asm-generic/bitops/instrumented-non-atomic.h:141 [inline]
BUG: KASAN: null-ptr-deref in ida_free+0x218/0x2e0 lib/idr.c:511
Read of size 8 at addr 0000000000000000 by task syz-executor.3/17254
CPU: 1 PID: 17254 Comm: syz-executor.3 Not tainted 6.7.0-rc3-syzkaller-00024-g18d46e76d7c2 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 11/10/2023
Call Trace:
__dump_stack lib/dump_stack.c:88 [inline]
dump_stack_lvl+0xd9/0x1b0 lib/dump_stack.c:106
kasan_report+0xda/0x110 mm/kasan/report.c:588
check_region_inline mm/kasan/generic.c:181 [inline]
kasan_check_range+0xef/0x190 mm/kasan/generic.c:187
instrument_atomic_read include/linux/instrumented.h:68 [inline]
_test_bit include/asm-generic/bitops/instrumented-non-atomic.h:141 [inline]
ida_free+0x218/0x2e0 lib/idr.c:511
hci_conn_cleanup net/bluetooth/hci_conn.c:157 [inline]
hci_conn_del+0x78c/0xe10 net/bluetooth/hci_conn.c:1182
hci_conn_hash_flush+0x189/0x260 net/bluetooth/hci_conn.c:2615
hci_dev_close_sync+0x5a7/0x1160 net/bluetooth/hci_sync.c:5021
hci_dev_do_close+0x2e/0x90 net/bluetooth/hci_core.c:554
hci_unregister_dev+0x1eb/0x600 net/bluetooth/hci_core.c:2739
vhci_release+0x7f/0x100 drivers/bluetooth/hci_vhci.c:672
__fput+0x270/0xbb0 fs/file_table.c:394
task_work_run+0x14d/0x240 kernel/task_work.c:180
exit_task_work include/linux/task_work.h:38 [inline]
do_exit+0xa92/0x2ae0 kernel/exit.c:871
do_group_exit+0xd4/0x2a0 kernel/exit.c:1021
get_signal+0x23be/0x2790 kernel/signal.c:2904
arch_do_signal_or_restart+0x90/0x7f0 arch/x86/kernel/signal.c:309
exit_to_user_mode_loop kernel/entry/common.c:168 [inline]
exit_to_user_mode_prepare+0x121/0x240 kernel/entry/common.c:204
__syscall_exit_to_user_mode_work kernel/entry/common.c:285 [inline]
syscall_exit_to_user_mode+0x1e/0x60 kernel/entry/common.c:296
do_syscall_64+0x4d/0x110 arch/x86/entry/common.c:88
entry_SYSCALL_64_after_hwframe+0x63/0x6b
RIP: 0033:0x7faf918a7ef5
Code: Unable to access opcode bytes at 0x7faf918a7ecb.
RSP: 002b:00007faf925c7010 EFLAGS: 00000293 ORIG_RAX: 00000000000000e6
RAX: fffffffffffffdfc RBX: 00007faf9199bf80 RCX: 00007faf918a7ef5
RDX: 00007faf925c7050 RSI: 0000000000000000 RDI: 0000000000000000
RBP: 00007faf918c847a R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000293 R12: 0000000000000000
R13: 000000000000000b R14: 00007faf9199bf80 R15: 00007ffd50e80948
==================================================================
BUG: kernel NULL pointer dereference, address: 0000000000000000
#PF: supervisor read access in kernel mode
#PF: error_code(0x0000) - not-present page
PGD 0 P4D 0
Oops: 0000 [#1] PREEMPT SMP KASAN
CPU: 1 PID: 17254 Comm: syz-executor.3 Tainted: G B 6.7.0-rc3-syzkaller-00024-g18d46e76d7c2 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 11/10/2023
RIP: 0010:variable_test_bit arch/x86/include/asm/bitops.h:227 [inline]
RIP: 0010:arch_test_bit arch/x86/include/asm/bitops.h:239 [inline]
RIP: 0010:_test_bit include/asm-generic/bitops/instrumented-non-atomic.h:142 [inline]
RIP: 0010:ida_free+0x218/0x2e0 lib/idr.c:511
Code: 41 5c 41 5d 41 5e 41 5f c3 e8 c4 d6 1b f7 4c 89 e8 be 08 00 00 00 48 c1 e8 06 49 8d 04 c4 48 89 c7 48 89 04 24 e8 58 83 72 f7 <4d> 0f a3 2c 24 41 0f 92 c7 31 ff 44 89 fe e8 c5 d1 1b f7 45 84 ff
RSP: 0018:ffffc90003657840 EFLAGS: 00010046
RAX: 0000000000000000 RBX: 1ffff920006caf09 RCX: ffffffff814dc07f
RDX: ffff88801d4a3b80 RSI: ffffffff81de17d7 RDI: 0000000000000007
RBP: 0000000000002000 R08: 0000000000000007 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000001 R12: 0000000000000000
R13: 0000000000000000 R14: 0000000000000293 R15: 0000000000000000
FS: 0000000000000000(0000) GS:ffff8880b9900000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000000000000 CR3: 000000002825d000 CR4: 0000000000350ef0
Call Trace:
hci_conn_cleanup net/bluetooth/hci_conn.c:157 [inline]
hci_conn_del+0x78c/0xe10 net/bluetooth/hci_conn.c:1182
hci_conn_hash_flush+0x189/0x260 net/bluetooth/hci_conn.c:2615
hci_dev_close_sync+0x5a7/0x1160 net/bluetooth/hci_sync.c:5021
hci_dev_do_close+0x2e/0x90 net/bluetooth/hci_core.c:554
hci_unregister_dev+0x1eb/0x600 net/bluetooth/hci_core.c:2739
vhci_release+0x7f/0x100 drivers/bluetooth/hci_vhci.c:672
__fput+0x270/0xbb0 fs/file_table.c:394
task_work_run+0x14d/0x240 kernel/task_work.c:180
exit_task_work include/linux/task_work.h:38 [inline]
do_exit+0xa92/0x2ae0 kernel/exit.c:871
do_group_exit+0xd4/0x2a0 kernel/exit.c:1021
get_signal+0x23be/0x2790 kernel/signal.c:2904
arch_do_signal_or_restart+0x90/0x7f0 arch/x86/kernel/signal.c:309
exit_to_user_mode_loop kernel/entry/common.c:168 [inline]
exit_to_user_mode_prepare+0x121/0x240 kernel/entry/common.c:204
__syscall_exit_to_user_mode_work kernel/entry/common.c:285 [inline]
syscall_exit_to_user_mode+0x1e/0x60 kernel/entry/common.c:296
do_syscall_64+0x4d/0x110 arch/x86/entry/common.c:88
entry_SYSCALL_64_after_hwframe+0x63/0x6b
RIP: 0033:0x7faf918a7ef5
Code: Unable to access opcode bytes at 0x7faf918a7ecb.
RSP: 002b:00007faf925c7010 EFLAGS: 00000293 ORIG_RAX: 00000000000000e6
RAX: fffffffffffffdfc RBX: 00007faf9199bf80 RCX: 00007faf918a7ef5
RDX: 00007faf925c7050 RSI: 0000000000000000 RDI: 0000000000000000
RBP: 00007faf918c847a R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000293 R12: 0000000000000000
R13: 000000000000000b R14: 00007faf9199bf80 R15: 00007ffd50e80948
Modules linked in:
CR2: 0000000000000000
---[ end trace 0000000000000000 ]---
RIP: 0010:variable_test_bit arch/x86/include/asm/bitops.h:227 [inline]
RIP: 0010:arch_test_bit arch/x86/include/asm/bitops.h:239 [inline]
RIP: 0010:_test_bit include/asm-generic/bitops/instrumented-non-atomic.h:142 [inline]
RIP: 0010:ida_free+0x218/0x2e0 lib/idr.c:511
Code: 41 5c 41 5d 41 5e 41 5f c3 e8 c4 d6 1b f7 4c 89 e8 be 08 00 00 00 48 c1 e8 06 49 8d 04 c4 48 89 c7 48 89 04 24 e8 58 83 72 f7 <4d> 0f a3 2c 24 41 0f 92 c7 31 ff 44 89 fe e8 c5 d1 1b f7 45 84 ff
RSP: 0018:ffffc90003657840 EFLAGS: 00010046
RAX: 0000000000000000 RBX: 1ffff920006caf09 RCX: ffffffff814dc07f
RDX: ffff88801d4a3b80 RSI: ffffffff81de17d7 RDI: 0000000000000007
RBP: 0000000000002000 R08: 0000000000000007 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000001 R12: 0000000000000000
R13: 0000000000000000 R14: 0000000000000293 R15: 0000000000000000
FS: 0000000000000000(0000) GS:ffff8880b9900000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000000000000 CR3: 000000002825d000 CR4: 0000000000350ef0
----------------
Code disassembly (best guess):
0: 41 5c pop %r12
2: 41 5d pop %r13
4: 41 5e pop %r14
6: 41 5f pop %r15
8: c3 ret
9: e8 c4 d6 1b f7 call 0xf71bd6d2
e: 4c 89 e8 mov %r13,%rax
11: be 08 00 00 00 mov $0x8,%esi
16: 48 c1 e8 06 shr $0x6,%rax
1a: 49 8d 04 c4 lea (%r12,%rax,8),%rax
1e: 48 89 c7 mov %rax,%rdi
21: 48 89 04 24 mov %rax,(%rsp)
25: e8 58 83 72 f7 call 0xf7728382
* 2a: 4d 0f a3 2c 24 bt %r13,(%r12) <-- trapping instruction
2f: 41 0f 92 c7 setb %r15b
33: 31 ff xor %edi,%edi
35: 44 89 fe mov %r15d,%esi
38: e8 c5 d1 1b f7 call 0xf71bd202
3d: 45 84 ff test %r15b,%r15b