* [syzbot] [bluetooth?] general protection fault in bcsp_recv
@ 2025-02-15 17:18 syzbot
2025-04-02 23:56 ` syzbot
` (4 more replies)
0 siblings, 5 replies; 12+ messages in thread
From: syzbot @ 2025-02-15 17:18 UTC (permalink / raw)
To: linux-bluetooth, linux-kernel, luiz.dentz, marcel, syzkaller-bugs
Hello,
syzbot found the following issue on:
HEAD commit: df5d6180169a Add linux-next specific files for 20250210
git tree: linux-next
console output: https://syzkaller.appspot.com/x/log.txt?x=17be8718580000
kernel config: https://syzkaller.appspot.com/x/.config?x=2cd616b6e736ca7
dashboard link: https://syzkaller.appspot.com/bug?extid=4ed6852d4da4606c93da
compiler: Debian clang version 15.0.6, GNU ld (GNU Binutils for Debian) 2.40
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=1480a3f8580000
Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/92495cf20271/disk-df5d6180.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/4b3656161842/vmlinux-df5d6180.xz
kernel image: https://storage.googleapis.com/syzbot-assets/7fbc4e7a0f5d/bzImage-df5d6180.xz
IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+4ed6852d4da4606c93da@syzkaller.appspotmail.com
Oops: general protection fault, probably for non-canonical address 0xdffffc0000000021: 0000 [#1] PREEMPT SMP KASAN PTI
KASAN: null-ptr-deref in range [0x0000000000000108-0x000000000000010f]
CPU: 0 UID: 0 PID: 6167 Comm: syz.3.45 Not tainted 6.14.0-rc2-next-20250210-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 12/27/2024
RIP: 0010:bcsp_recv+0xcd/0x16d0 drivers/bluetooth/hci_bcsp.c:590
Code: 38 4c 89 e8 48 c1 e8 03 48 89 44 24 28 48 89 4c 24 20 48 89 6c 24 18 4c 89 6c 24 10 4c 89 7c 24 08 89 5c 24 04 48 8b 44 24 38 <42> 80 3c 30 00 74 08 48 89 ef e8 94 d5 5c f9 48 8b 5d 00 31 ff 48
RSP: 0018:ffffc900034d7cd0 EFLAGS: 00010202
RAX: 0000000000000021 RBX: 0000000000000001 RCX: 0000000000000182
RDX: ffff888035fc8000 RSI: 0000000000000001 RDI: 0000000000000000
RBP: 0000000000000108 R08: ffffffff88c9aef5 R09: 1ffff1100ade3c03
R10: dffffc0000000000 R11: ffffffff88c9ae90 R12: ffffc900034d7e00
R13: 0000000000000178 R14: dffffc0000000000 R15: 0000000000000110
FS: 00007f0fbdf626c0(0000) GS:ffff8880b8600000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000000000000 CR3: 00000000348be000 CR4: 00000000003526f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
<TASK>
hci_uart_tty_receive+0x141/0x1c0 drivers/bluetooth/hci_ldisc.c:622
tiocsti+0x24d/0x300 drivers/tty/tty_io.c:2299
tty_ioctl+0x518/0xdc0 drivers/tty/tty_io.c:2716
vfs_ioctl fs/ioctl.c:51 [inline]
__do_sys_ioctl fs/ioctl.c:906 [inline]
__se_sys_ioctl+0xf1/0x160 fs/ioctl.c:892
do_syscall_x64 arch/x86/entry/common.c:52 [inline]
do_syscall_64+0xf3/0x230 arch/x86/entry/common.c:83
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f0fbd18cde9
Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 a8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f0fbdf62038 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
RAX: ffffffffffffffda RBX: 00007f0fbd3a6160 RCX: 00007f0fbd18cde9
RDX: 0000400000000240 RSI: 0000000000005412 RDI: 0000000000000007
RBP: 00007f0fbd20e2a0 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 0000000000000000 R14: 00007f0fbd3a6160 R15: 00007fffe8c957b8
</TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:bcsp_recv+0xcd/0x16d0 drivers/bluetooth/hci_bcsp.c:590
Code: 38 4c 89 e8 48 c1 e8 03 48 89 44 24 28 48 89 4c 24 20 48 89 6c 24 18 4c 89 6c 24 10 4c 89 7c 24 08 89 5c 24 04 48 8b 44 24 38 <42> 80 3c 30 00 74 08 48 89 ef e8 94 d5 5c f9 48 8b 5d 00 31 ff 48
RSP: 0018:ffffc900034d7cd0 EFLAGS: 00010202
RAX: 0000000000000021 RBX: 0000000000000001 RCX: 0000000000000182
RDX: ffff888035fc8000 RSI: 0000000000000001 RDI: 0000000000000000
RBP: 0000000000000108 R08: ffffffff88c9aef5 R09: 1ffff1100ade3c03
R10: dffffc0000000000 R11: ffffffff88c9ae90 R12: ffffc900034d7e00
R13: 0000000000000178 R14: dffffc0000000000 R15: 0000000000000110
FS: 00007f0fbdf626c0(0000) GS:ffff8880b8600000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f0fbdf40f98 CR3: 00000000348be000 CR4: 00000000003526f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
----------------
Code disassembly (best guess):
0: 38 4c 89 e8 cmp %cl,-0x18(%rcx,%rcx,4)
4: 48 c1 e8 03 shr $0x3,%rax
8: 48 89 44 24 28 mov %rax,0x28(%rsp)
d: 48 89 4c 24 20 mov %rcx,0x20(%rsp)
12: 48 89 6c 24 18 mov %rbp,0x18(%rsp)
17: 4c 89 6c 24 10 mov %r13,0x10(%rsp)
1c: 4c 89 7c 24 08 mov %r15,0x8(%rsp)
21: 89 5c 24 04 mov %ebx,0x4(%rsp)
25: 48 8b 44 24 38 mov 0x38(%rsp),%rax
* 2a: 42 80 3c 30 00 cmpb $0x0,(%rax,%r14,1) <-- trapping instruction
2f: 74 08 je 0x39
31: 48 89 ef mov %rbp,%rdi
34: e8 94 d5 5c f9 call 0xf95cd5cd
39: 48 8b 5d 00 mov 0x0(%rbp),%rbx
3d: 31 ff xor %edi,%edi
3f: 48 rex.W
---
This report is generated by a bot. It may contain errors.
See https://goo.gl/tpsmEJ for more information about syzbot.
syzbot engineers can be reached at syzkaller@googlegroups.com.
syzbot will keep track of this issue. See:
https://goo.gl/tpsmEJ#status for how to communicate with syzbot.
If the report is already addressed, let syzbot know by replying with:
#syz fix: exact-commit-title
If you want syzbot to run the reproducer, reply with:
#syz test: git://repo/address.git branch-or-commit-hash
If you attach or paste a git patch, syzbot will apply it before testing.
If you want to overwrite report's subsystems, reply with:
#syz set subsystems: new-subsystem
(See the list of subsystem names on the web dashboard)
If the report is a duplicate of another one, reply with:
#syz dup: exact-subject-of-another-report
If you want to undo deduplication, reply with:
#syz undup
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [syzbot] [bluetooth?] general protection fault in bcsp_recv
2025-02-15 17:18 [syzbot] [bluetooth?] general protection fault in bcsp_recv syzbot
@ 2025-04-02 23:56 ` syzbot
2025-06-30 8:03 ` Hillf Danton
2025-06-30 3:03 ` [syzbot] " syzbot
` (3 subsequent siblings)
4 siblings, 1 reply; 12+ messages in thread
From: syzbot @ 2025-04-02 23:56 UTC (permalink / raw)
To: linux-bluetooth, linux-kernel, luiz.dentz, marcel, syzkaller-bugs
syzbot has found a reproducer for the following issue on:
HEAD commit: acc4d5ff0b61 Merge tag 'net-6.15-rc0' of git://git.kernel...
git tree: upstream
console output: https://syzkaller.appspot.com/x/log.txt?x=135a6178580000
kernel config: https://syzkaller.appspot.com/x/.config?x=410c49aba9aeb859
dashboard link: https://syzkaller.appspot.com/bug?extid=4ed6852d4da4606c93da
compiler: gcc (Debian 12.2.0-14) 12.2.0, GNU ld (GNU Binutils for Debian) 2.40
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=134ec7cf980000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=13315274580000
Downloadable assets:
disk image (non-bootable): https://storage.googleapis.com/syzbot-assets/7feb34a89c2a/non_bootable_disk-acc4d5ff.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/aad60517b1c2/vmlinux-acc4d5ff.xz
kernel image: https://storage.googleapis.com/syzbot-assets/27bf64833684/bzImage-acc4d5ff.xz
IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+4ed6852d4da4606c93da@syzkaller.appspotmail.com
Oops: general protection fault, probably for non-canonical address 0xdffffc0000000021: 0000 [#1] SMP KASAN NOPTI
KASAN: null-ptr-deref in range [0x0000000000000108-0x000000000000010f]
CPU: 1 UID: 0 PID: 5945 Comm: syz-executor103 Not tainted 6.14.0-syzkaller-12456-gacc4d5ff0b61 #0 PREEMPT(full)
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2~bpo12+1 04/01/2014
RIP: 0010:bcsp_recv+0x10a/0x17f0 drivers/bluetooth/hci_bcsp.c:590
Code: 18 48 c1 e8 03 48 01 e8 48 89 04 24 48 8d 83 78 01 00 00 48 89 44 24 28 48 c1 e8 03 48 89 44 24 08 e8 aa ca 5c f9 48 8b 04 24 <80> 38 00 0f 85 d1 12 00 00 4c 8b ab 08 01 00 00 31 ff 4c 89 ee e8
RSP: 0018:ffffc90003467bf0 EFLAGS: 00010293
RAX: dffffc0000000021 RBX: 0000000000000000 RCX: ffffffff885e756a
RDX: ffff888024910000 RSI: ffffffff885e75b6 RDI: 0000000000000005
RBP: dffffc0000000000 R08: 0000000000000005 R09: 0000000000000000
R10: 0000000000000001 R11: 0000000000000001 R12: ffffc90003467d88
R13: ffffc90003467d88 R14: 0000000000000001 R15: ffff88810735a800
FS: 00007ffb5ce256c0(0000) GS:ffff8880d6abb000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007ffc59fa2f98 CR3: 0000000024ec0000 CR4: 0000000000352ef0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
<TASK>
hci_uart_tty_receive+0x251/0x7e0 drivers/bluetooth/hci_ldisc.c:627
tiocsti drivers/tty/tty_io.c:2299 [inline]
tty_ioctl+0x57b/0x15f0 drivers/tty/tty_io.c:2716
vfs_ioctl fs/ioctl.c:51 [inline]
__do_sys_ioctl fs/ioctl.c:906 [inline]
__se_sys_ioctl fs/ioctl.c:892 [inline]
__x64_sys_ioctl+0x190/0x200 fs/ioctl.c:892
do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
do_syscall_64+0xcd/0x260 arch/x86/entry/syscall_64.c:94
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7ffb5ce97899
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 51 1f 00 00 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007ffb5ce25168 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
RAX: ffffffffffffffda RBX: 00007ffb5cf1b418 RCX: 00007ffb5ce97899
RDX: 0000200000000140 RSI: 0000000000005412 RDI: 0000000000000004
RBP: 00007ffb5cf1b410 R08: 00007ffcd6d4fb07 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 00007ffb5cf1b41c
R13: 0000000000000010 R14: 00007ffcd6d4fa20 R15: 00007ffcd6d4fb08
</TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:bcsp_recv+0x10a/0x17f0 drivers/bluetooth/hci_bcsp.c:590
Code: 18 48 c1 e8 03 48 01 e8 48 89 04 24 48 8d 83 78 01 00 00 48 89 44 24 28 48 c1 e8 03 48 89 44 24 08 e8 aa ca 5c f9 48 8b 04 24 <80> 38 00 0f 85 d1 12 00 00 4c 8b ab 08 01 00 00 31 ff 4c 89 ee e8
RSP: 0018:ffffc90003467bf0 EFLAGS: 00010293
RAX: dffffc0000000021 RBX: 0000000000000000 RCX: ffffffff885e756a
RDX: ffff888024910000 RSI: ffffffff885e75b6 RDI: 0000000000000005
RBP: dffffc0000000000 R08: 0000000000000005 R09: 0000000000000000
R10: 0000000000000001 R11: 0000000000000001 R12: ffffc90003467d88
R13: ffffc90003467d88 R14: 0000000000000001 R15: ffff88810735a800
FS: 00007ffb5ce256c0(0000) GS:ffff8880d6abb000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007ffc59fa2f98 CR3: 0000000024ec0000 CR4: 0000000000352ef0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
----------------
Code disassembly (best guess):
0: 18 48 c1 sbb %cl,-0x3f(%rax)
3: e8 03 48 01 e8 call 0xe801480b
8: 48 89 04 24 mov %rax,(%rsp)
c: 48 8d 83 78 01 00 00 lea 0x178(%rbx),%rax
13: 48 89 44 24 28 mov %rax,0x28(%rsp)
18: 48 c1 e8 03 shr $0x3,%rax
1c: 48 89 44 24 08 mov %rax,0x8(%rsp)
21: e8 aa ca 5c f9 call 0xf95ccad0
26: 48 8b 04 24 mov (%rsp),%rax
* 2a: 80 38 00 cmpb $0x0,(%rax) <-- trapping instruction
2d: 0f 85 d1 12 00 00 jne 0x1304
33: 4c 8b ab 08 01 00 00 mov 0x108(%rbx),%r13
3a: 31 ff xor %edi,%edi
3c: 4c 89 ee mov %r13,%rsi
3f: e8 .byte 0xe8
---
If you want syzbot to run the reproducer, reply with:
#syz test: git://repo/address.git branch-or-commit-hash
If you attach or paste a git patch, syzbot will apply it before testing.
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [syzbot] Re: [syzbot] [bluetooth?] general protection fault in bcsp_recv
2025-02-15 17:18 [syzbot] [bluetooth?] general protection fault in bcsp_recv syzbot
2025-04-02 23:56 ` syzbot
@ 2025-06-30 3:03 ` syzbot
2025-08-27 14:29 ` Forwarded: " syzbot
` (2 subsequent siblings)
4 siblings, 0 replies; 12+ messages in thread
From: syzbot @ 2025-06-30 3:03 UTC (permalink / raw)
To: linux-kernel
For archival purposes, forwarding an incoming command email to
linux-kernel@vger.kernel.org.
***
Subject: Re: [syzbot] [bluetooth?] general protection fault in bcsp_recv
Author: ipravdin.official@gmail.com
#syz test
diff --git a/drivers/bluetooth/hci_bcsp.c b/drivers/bluetooth/hci_bcsp.c
index 610d0e3c36d4..de9a6ed3a8aa 100644
--- a/drivers/bluetooth/hci_bcsp.c
+++ b/drivers/bluetooth/hci_bcsp.c
@@ -739,8 +739,6 @@ static int bcsp_close(struct hci_uart *hu)
timer_shutdown_sync(&bcsp->tbcsp);
- hu->priv = NULL;
-
BT_DBG("hu %p", hu);
skb_queue_purge(&bcsp->unack);
@@ -753,6 +751,8 @@ static int bcsp_close(struct hci_uart *hu)
}
kfree(bcsp);
+ hu->priv = NULL;
+
return 0;
}
Ivan Pravdin
^ permalink raw reply related [flat|nested] 12+ messages in thread
* Re: [syzbot] [bluetooth?] general protection fault in bcsp_recv
[not found] <pxrxtntcuuqt5opsno55wx62yqafwhfqkqhylpbwwkqt4iabdv@2nmky356ufdo>
@ 2025-06-30 3:22 ` syzbot
0 siblings, 0 replies; 12+ messages in thread
From: syzbot @ 2025-06-30 3:22 UTC (permalink / raw)
To: ipravdin.official, linux-kernel, syzkaller-bugs
Hello,
syzbot tried to test the proposed patch but the build/boot failed:
failed to apply patch:
checking file drivers/bluetooth/hci_bcsp.c
patch: **** unexpected end of file in patch
Tested on:
commit: d0b3b7b2 Linux 6.16-rc4
git tree: upstream
kernel config: https://syzkaller.appspot.com/x/.config?x=efa83f9a6dd67d67
dashboard link: https://syzkaller.appspot.com/bug?extid=4ed6852d4da4606c93da
compiler:
patch: https://syzkaller.appspot.com/x/patch.diff?x=13eb2770580000
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [syzbot] [bluetooth?] general protection fault in bcsp_recv
2025-04-02 23:56 ` syzbot
@ 2025-06-30 8:03 ` Hillf Danton
2025-06-30 8:39 ` syzbot
0 siblings, 1 reply; 12+ messages in thread
From: Hillf Danton @ 2025-06-30 8:03 UTC (permalink / raw)
To: syzbot; +Cc: linux-kernel, syzkaller-bugs
> Date: Wed, 02 Apr 2025 16:56:20 -0700
> syzbot has found a reproducer for the following issue on:
>
> HEAD commit: acc4d5ff0b61 Merge tag 'net-6.15-rc0' of git://git.kernel...
> git tree: upstream
> console output: https://syzkaller.appspot.com/x/log.txt?x=135a6178580000
> kernel config: https://syzkaller.appspot.com/x/.config?x=410c49aba9aeb859
> dashboard link: https://syzkaller.appspot.com/bug?extid=4ed6852d4da4606c93da
> compiler: gcc (Debian 12.2.0-14) 12.2.0, GNU ld (GNU Binutils for Debian) 2.40
> syz repro: https://syzkaller.appspot.com/x/repro.syz?x=134ec7cf980000
> C reproducer: https://syzkaller.appspot.com/x/repro.c?x=13315274580000
#syz test
--- x/drivers/bluetooth/hci_ldisc.c
+++ y/drivers/bluetooth/hci_ldisc.c
@@ -615,7 +615,7 @@ static void hci_uart_tty_receive(struct
percpu_down_read(&hu->proto_lock);
- if (!test_bit(HCI_UART_PROTO_READY, &hu->flags) &&
+ if (!test_bit(HCI_UART_PROTO_READY, &hu->flags) ||
!test_bit(HCI_UART_PROTO_INIT, &hu->flags)) {
percpu_up_read(&hu->proto_lock);
return;
--
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [syzbot] [bluetooth?] general protection fault in bcsp_recv
2025-06-30 8:03 ` Hillf Danton
@ 2025-06-30 8:39 ` syzbot
0 siblings, 0 replies; 12+ messages in thread
From: syzbot @ 2025-06-30 8:39 UTC (permalink / raw)
To: hdanton, linux-kernel, syzkaller-bugs
Hello,
syzbot has tested the proposed patch and the reproducer did not trigger any issue:
Reported-by: syzbot+4ed6852d4da4606c93da@syzkaller.appspotmail.com
Tested-by: syzbot+4ed6852d4da4606c93da@syzkaller.appspotmail.com
Tested on:
commit: d0b3b7b2 Linux 6.16-rc4
git tree: upstream
console output: https://syzkaller.appspot.com/x/log.txt?x=15c9a770580000
kernel config: https://syzkaller.appspot.com/x/.config?x=2653dda68f72de50
dashboard link: https://syzkaller.appspot.com/bug?extid=4ed6852d4da4606c93da
compiler: gcc (Debian 12.2.0-14) 12.2.0, GNU ld (GNU Binutils for Debian) 2.40
patch: https://syzkaller.appspot.com/x/patch.diff?x=119ce3d4580000
Note: testing is done by a robot and is best-effort only.
^ permalink raw reply [flat|nested] 12+ messages in thread
* Forwarded: Re: [syzbot] [bluetooth?] general protection fault in bcsp_recv
2025-02-15 17:18 [syzbot] [bluetooth?] general protection fault in bcsp_recv syzbot
2025-04-02 23:56 ` syzbot
2025-06-30 3:03 ` [syzbot] " syzbot
@ 2025-08-27 14:29 ` syzbot
2025-08-27 14:36 ` syzbot
2025-08-30 18:37 ` Ivan Pravdin
4 siblings, 0 replies; 12+ messages in thread
From: syzbot @ 2025-08-27 14:29 UTC (permalink / raw)
To: linux-kernel
For archival purposes, forwarding an incoming command email to
linux-kernel@vger.kernel.org.
***
Subject: Re: [syzbot] [bluetooth?] general protection fault in bcsp_recv
Author: ipravdin.official@gmail.com
#syz test
Ivan Pravdin
^ permalink raw reply [flat|nested] 12+ messages in thread
* Forwarded: Re: [syzbot] [bluetooth?] general protection fault in bcsp_recv
2025-02-15 17:18 [syzbot] [bluetooth?] general protection fault in bcsp_recv syzbot
` (2 preceding siblings ...)
2025-08-27 14:29 ` Forwarded: " syzbot
@ 2025-08-27 14:36 ` syzbot
2025-08-30 18:37 ` Ivan Pravdin
4 siblings, 0 replies; 12+ messages in thread
From: syzbot @ 2025-08-27 14:36 UTC (permalink / raw)
To: linux-kernel
For archival purposes, forwarding an incoming command email to
linux-kernel@vger.kernel.org.
***
Subject: Re: [syzbot] [bluetooth?] general protection fault in bcsp_recv
Author: ipravdin.official@gmail.com
#syz test: git://git.kernel.org/pub/scm/linux/kernel/git/bluetooth/bluetooth-next.git master
Ivan Pravdin
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [syzbot] [bluetooth?] general protection fault in bcsp_recv
[not found] <nqdjhsx4cy3x64g3q6w6ffczvcwhh7aavelmrvqjtinqetusa4@4xdhtbpkhlse>
@ 2025-08-27 15:11 ` syzbot
0 siblings, 0 replies; 12+ messages in thread
From: syzbot @ 2025-08-27 15:11 UTC (permalink / raw)
To: ipravdin.official, linux-kernel, syzkaller-bugs
Hello,
syzbot has tested the proposed patch but the reproducer is still triggering an issue:
general protection fault in bcsp_recv
Oops: general protection fault, probably for non-canonical address 0xdffffc0000000021: 0000 [#1] SMP KASAN PTI
KASAN: null-ptr-deref in range [0x0000000000000108-0x000000000000010f]
CPU: 1 UID: 0 PID: 6475 Comm: syz.0.17 Not tainted syzkaller #0 PREEMPT(full)
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/12/2025
RIP: 0010:bcsp_recv+0x13d/0x1740 drivers/bluetooth/hci_bcsp.c:590
Code: 89 4c 24 40 48 89 54 24 28 48 c1 ea 03 48 89 54 24 68 48 89 5c 24 20 48 c1 eb 03 48 89 5c 24 60 4c 89 7c 24 38 48 8b 44 24 58 <42> 80 3c 30 00 74 08 4c 89 ff e8 44 b1 be f9 49 8b 1f 31 ff 48 89
RSP: 0018:ffffc90002fb7c00 EFLAGS: 00010206
RAX: 0000000000000021 RBX: 0000000000000030 RCX: 000000000000002f
RDX: 000000000000002f RSI: 0000000000000001 RDI: 0000000000000000
RBP: ffffc90002fb7d60 R08: ffff888062a12c1f R09: 1ffff1100c542583
R10: dffffc0000000000 R11: ffffffff88623580 R12: 0000000000000001
R13: ffffc90002fb7e00 R14: dffffc0000000000 R15: 0000000000000108
FS: 00007f4f2f09f6c0(0000) GS:ffff888125d53000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f4f2f09ef98 CR3: 0000000031000000 CR4: 00000000003526f0
Call Trace:
<TASK>
hci_uart_tty_receive+0x194/0x220 drivers/bluetooth/hci_ldisc.c:627
tiocsti+0x239/0x2c0 drivers/tty/tty_io.c:2290
tty_ioctl+0x626/0xde0 drivers/tty/tty_io.c:2706
vfs_ioctl fs/ioctl.c:51 [inline]
__do_sys_ioctl fs/ioctl.c:598 [inline]
__se_sys_ioctl+0xfc/0x170 fs/ioctl.c:584
do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
do_syscall_64+0xfa/0x3b0 arch/x86/entry/syscall_64.c:94
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f4f2e18e9a9
Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 a8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f4f2f09f038 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
RAX: ffffffffffffffda RBX: 00007f4f2e3b6080 RCX: 00007f4f2e18e9a9
RDX: 0000200000000140 RSI: 0000000000005412 RDI: 0000000000000004
RBP: 00007f4f2e210d69 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 0000000000000001 R14: 00007f4f2e3b6080 R15: 00007ffc2eba6848
</TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:bcsp_recv+0x13d/0x1740 drivers/bluetooth/hci_bcsp.c:590
Code: 89 4c 24 40 48 89 54 24 28 48 c1 ea 03 48 89 54 24 68 48 89 5c 24 20 48 c1 eb 03 48 89 5c 24 60 4c 89 7c 24 38 48 8b 44 24 58 <42> 80 3c 30 00 74 08 4c 89 ff e8 44 b1 be f9 49 8b 1f 31 ff 48 89
RSP: 0018:ffffc90002fb7c00 EFLAGS: 00010206
RAX: 0000000000000021 RBX: 0000000000000030 RCX: 000000000000002f
RDX: 000000000000002f RSI: 0000000000000001 RDI: 0000000000000000
RBP: ffffc90002fb7d60 R08: ffff888062a12c1f R09: 1ffff1100c542583
R10: dffffc0000000000 R11: ffffffff88623580 R12: 0000000000000001
R13: ffffc90002fb7e00 R14: dffffc0000000000 R15: 0000000000000108
FS: 00007f4f2f09f6c0(0000) GS:ffff888125d53000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f4f2f09ef98 CR3: 0000000031000000 CR4: 00000000003526f0
----------------
Code disassembly (best guess):
0: 89 4c 24 40 mov %ecx,0x40(%rsp)
4: 48 89 54 24 28 mov %rdx,0x28(%rsp)
9: 48 c1 ea 03 shr $0x3,%rdx
d: 48 89 54 24 68 mov %rdx,0x68(%rsp)
12: 48 89 5c 24 20 mov %rbx,0x20(%rsp)
17: 48 c1 eb 03 shr $0x3,%rbx
1b: 48 89 5c 24 60 mov %rbx,0x60(%rsp)
20: 4c 89 7c 24 38 mov %r15,0x38(%rsp)
25: 48 8b 44 24 58 mov 0x58(%rsp),%rax
* 2a: 42 80 3c 30 00 cmpb $0x0,(%rax,%r14,1) <-- trapping instruction
2f: 74 08 je 0x39
31: 4c 89 ff mov %r15,%rdi
34: e8 44 b1 be f9 call 0xf9beb17d
39: 49 8b 1f mov (%r15),%rbx
3c: 31 ff xor %edi,%edi
3e: 48 rex.W
3f: 89 .byte 0x89
Tested on:
commit: fab1beda Merge tag 'devicetree-fixes-for-6.17-1' of gi..
git tree: upstream
console output: https://syzkaller.appspot.com/x/log.txt?x=17af4fbc580000
kernel config: https://syzkaller.appspot.com/x/.config?x=16cf058b8ba89168
dashboard link: https://syzkaller.appspot.com/bug?extid=4ed6852d4da4606c93da
compiler: Debian clang version 20.1.7 (++20250616065708+6146a88f6049-1~exp1~20250616065826.132), Debian LLD 20.1.7
patch: https://syzkaller.appspot.com/x/patch.diff?x=14bc6462580000
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [syzbot] [bluetooth?] general protection fault in bcsp_recv
[not found] <cdfnb7ox7u3qogpyvxgti4ljpsa7ohvh2ilzy2tqygzsvxmh3a@cglm7naoohg5>
@ 2025-08-27 15:49 ` syzbot
0 siblings, 0 replies; 12+ messages in thread
From: syzbot @ 2025-08-27 15:49 UTC (permalink / raw)
To: ipravdin.official, linux-kernel, syzkaller-bugs
Hello,
syzbot has tested the proposed patch but the reproducer is still triggering an issue:
general protection fault in bcsp_recv
Oops: general protection fault, probably for non-canonical address 0xdffffc0000000021: 0000 [#1] SMP KASAN PTI
KASAN: null-ptr-deref in range [0x0000000000000108-0x000000000000010f]
CPU: 0 UID: 0 PID: 6616 Comm: syz.0.16 Not tainted syzkaller #0 PREEMPT(full)
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/12/2025
RIP: 0010:bcsp_recv+0x13d/0x1740 drivers/bluetooth/hci_bcsp.c:590
Code: 89 4c 24 40 48 89 54 24 28 48 c1 ea 03 48 89 54 24 68 48 89 5c 24 20 48 c1 eb 03 48 89 5c 24 60 4c 89 7c 24 38 48 8b 44 24 58 <42> 80 3c 30 00 74 08 4c 89 ff e8 d4 21 c9 f9 49 8b 1f 31 ff 48 89
RSP: 0018:ffffc90002f77c00 EFLAGS: 00010206
RAX: 0000000000000021 RBX: 0000000000000030 RCX: 000000000000002f
RDX: 000000000000002f RSI: 0000000000000001 RDI: 0000000000000000
RBP: ffffc90002f77d60 R08: ffff8880771ab81f R09: 1ffff1100ee35703
R10: dffffc0000000000 R11: ffffffff8856eb10 R12: 0000000000000001
R13: ffffc90002f77e00 R14: dffffc0000000000 R15: 0000000000000108
FS: 00007ff06020b6c0(0000) GS:ffff888125c47000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007ff06020af98 CR3: 0000000031284000 CR4: 00000000003526f0
Call Trace:
<TASK>
hci_uart_tty_receive+0x191/0x220 drivers/bluetooth/hci_ldisc.c:627
tiocsti+0x239/0x2c0 drivers/tty/tty_io.c:2290
tty_ioctl+0x626/0xde0 drivers/tty/tty_io.c:2706
vfs_ioctl fs/ioctl.c:51 [inline]
__do_sys_ioctl fs/ioctl.c:907 [inline]
__se_sys_ioctl+0xfc/0x170 fs/ioctl.c:893
do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
do_syscall_64+0xfa/0x3b0 arch/x86/entry/syscall_64.c:94
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7ff05f38e9a9
Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 a8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007ff06020b038 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
RAX: ffffffffffffffda RBX: 00007ff05f5b6080 RCX: 00007ff05f38e9a9
RDX: 0000200000000140 RSI: 0000000000005412 RDI: 0000000000000004
RBP: 00007ff05f410d69 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 0000000000000001 R14: 00007ff05f5b6080 R15: 00007ffd9bba04b8
</TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:bcsp_recv+0x13d/0x1740 drivers/bluetooth/hci_bcsp.c:590
Code: 89 4c 24 40 48 89 54 24 28 48 c1 ea 03 48 89 54 24 68 48 89 5c 24 20 48 c1 eb 03 48 89 5c 24 60 4c 89 7c 24 38 48 8b 44 24 58 <42> 80 3c 30 00 74 08 4c 89 ff e8 d4 21 c9 f9 49 8b 1f 31 ff 48 89
RSP: 0018:ffffc90002f77c00 EFLAGS: 00010206
RAX: 0000000000000021 RBX: 0000000000000030 RCX: 000000000000002f
RDX: 000000000000002f RSI: 0000000000000001 RDI: 0000000000000000
RBP: ffffc90002f77d60 R08: ffff8880771ab81f R09: 1ffff1100ee35703
R10: dffffc0000000000 R11: ffffffff8856eb10 R12: 0000000000000001
R13: ffffc90002f77e00 R14: dffffc0000000000 R15: 0000000000000108
FS: 00007ff06020b6c0(0000) GS:ffff888125c47000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007ff06020af98 CR3: 0000000031284000 CR4: 00000000003526f0
----------------
Code disassembly (best guess):
0: 89 4c 24 40 mov %ecx,0x40(%rsp)
4: 48 89 54 24 28 mov %rdx,0x28(%rsp)
9: 48 c1 ea 03 shr $0x3,%rdx
d: 48 89 54 24 68 mov %rdx,0x68(%rsp)
12: 48 89 5c 24 20 mov %rbx,0x20(%rsp)
17: 48 c1 eb 03 shr $0x3,%rbx
1b: 48 89 5c 24 60 mov %rbx,0x60(%rsp)
20: 4c 89 7c 24 38 mov %r15,0x38(%rsp)
25: 48 8b 44 24 58 mov 0x58(%rsp),%rax
* 2a: 42 80 3c 30 00 cmpb $0x0,(%rax,%r14,1) <-- trapping instruction
2f: 74 08 je 0x39
31: 4c 89 ff mov %r15,%rdi
34: e8 d4 21 c9 f9 call 0xf9c9220d
39: 49 8b 1f mov (%r15),%rbx
3c: 31 ff xor %edi,%edi
3e: 48 rex.W
3f: 89 .byte 0x89
Tested on:
commit: c49a788e Bluetooth: hci_sync: fix set_local_name race ..
git tree: git://git.kernel.org/pub/scm/linux/kernel/git/bluetooth/bluetooth-next.git master
console output: https://syzkaller.appspot.com/x/log.txt?x=12e35ef0580000
kernel config: https://syzkaller.appspot.com/x/.config?x=e320672d7f4a2ce9
dashboard link: https://syzkaller.appspot.com/bug?extid=4ed6852d4da4606c93da
compiler: Debian clang version 20.1.7 (++20250616065708+6146a88f6049-1~exp1~20250616065826.132), Debian LLD 20.1.7
patch: https://syzkaller.appspot.com/x/patch.diff?x=15026462580000
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [syzbot] [bluetooth?] general protection fault in bcsp_recv
2025-02-15 17:18 [syzbot] [bluetooth?] general protection fault in bcsp_recv syzbot
` (3 preceding siblings ...)
2025-08-27 14:36 ` syzbot
@ 2025-08-30 18:37 ` Ivan Pravdin
2025-08-30 19:46 ` syzbot
4 siblings, 1 reply; 12+ messages in thread
From: Ivan Pravdin @ 2025-08-30 18:37 UTC (permalink / raw)
To: syzbot+4ed6852d4da4606c93da; +Cc: linux-kernel, syzkaller-bugs
[-- Attachment #1: Type: text/plain, Size: 108 bytes --]
#syz test: git://git.kernel.org/pub/scm/linux/kernel/git/bluetooth/bluetooth-next.git master
Ivan Pravdin
[-- Attachment #2: diff.txt --]
[-- Type: text/plain, Size: 522 bytes --]
diff --git a/drivers/bluetooth/hci_bcsp.c b/drivers/bluetooth/hci_bcsp.c
index 664d82d1e613..591abe6d63dd 100644
--- a/drivers/bluetooth/hci_bcsp.c
+++ b/drivers/bluetooth/hci_bcsp.c
@@ -582,6 +582,9 @@ static int bcsp_recv(struct hci_uart *hu, const void *data, int count)
struct bcsp_struct *bcsp = hu->priv;
const unsigned char *ptr;
+ if (!test_bit(HCI_UART_REGISTERED, &hu->flags))
+ return -EUNATCH;
+
BT_DBG("hu %p count %d rx_state %d rx_count %ld",
hu, count, bcsp->rx_state, bcsp->rx_count);
^ permalink raw reply related [flat|nested] 12+ messages in thread
* Re: [syzbot] [bluetooth?] general protection fault in bcsp_recv
2025-08-30 18:37 ` Ivan Pravdin
@ 2025-08-30 19:46 ` syzbot
0 siblings, 0 replies; 12+ messages in thread
From: syzbot @ 2025-08-30 19:46 UTC (permalink / raw)
To: ipravdin.official, linux-kernel, syzkaller-bugs
Hello,
syzbot has tested the proposed patch and the reproducer did not trigger any issue:
Reported-by: syzbot+4ed6852d4da4606c93da@syzkaller.appspotmail.com
Tested-by: syzbot+4ed6852d4da4606c93da@syzkaller.appspotmail.com
Tested on:
commit: 02925b3b Bluetooth: Fix use-after-free in l2cap_sock_c..
git tree: git://git.kernel.org/pub/scm/linux/kernel/git/bluetooth/bluetooth-next.git master
console output: https://syzkaller.appspot.com/x/log.txt?x=110b8e34580000
kernel config: https://syzkaller.appspot.com/x/.config?x=c6b2ceaf54a94b5e
dashboard link: https://syzkaller.appspot.com/bug?extid=4ed6852d4da4606c93da
compiler: Debian clang version 20.1.8 (++20250708063551+0c9f909b7976-1~exp1~20250708183702.136), Debian LLD 20.1.8
patch: https://syzkaller.appspot.com/x/patch.diff?x=10ab2a62580000
Note: testing is done by a robot and is best-effort only.
^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2025-08-30 19:46 UTC | newest]
Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-02-15 17:18 [syzbot] [bluetooth?] general protection fault in bcsp_recv syzbot
2025-04-02 23:56 ` syzbot
2025-06-30 8:03 ` Hillf Danton
2025-06-30 8:39 ` syzbot
2025-06-30 3:03 ` [syzbot] " syzbot
2025-08-27 14:29 ` Forwarded: " syzbot
2025-08-27 14:36 ` syzbot
2025-08-30 18:37 ` Ivan Pravdin
2025-08-30 19:46 ` syzbot
[not found] <pxrxtntcuuqt5opsno55wx62yqafwhfqkqhylpbwwkqt4iabdv@2nmky356ufdo>
2025-06-30 3:22 ` syzbot
[not found] <nqdjhsx4cy3x64g3q6w6ffczvcwhh7aavelmrvqjtinqetusa4@4xdhtbpkhlse>
2025-08-27 15:11 ` syzbot
[not found] <cdfnb7ox7u3qogpyvxgti4ljpsa7ohvh2ilzy2tqygzsvxmh3a@cglm7naoohg5>
2025-08-27 15:49 ` syzbot
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).