syzbot
general protection fault in rfcomm_dev_shutdown
Status:
upstream: reported on 2026/10/02 05:32
Subsystems:
bluetooth
Labels:
prio:low
[Documentation on labels]
Reported-by: syzbot+4a807caf7680652d53b6@syzkaller.appspotmail.com
Fix commit:
08e90633377f
Bluetooth: RFCOMM: Fix NULL tty_dev dereference in rfcomm_dev_shutdown
Patched on: [ci-qemu-gce-upstream-auto ci-qemu-upstream ci-qemu-upstream-386 ci-qemu2-arm32 ci-qemu2-arm64 ci-qemu2-arm64-compat ci-qemu2-arm64-mte ci-qemu2-riscv64 ci-snapshot-upstream-root ci-upstream-bpf-kasan-gce ci-upstream-bpf-next-kasan-gce ci-upstream-gce-arm64 ci-upstream-gce-leak ci-upstream-kasan-badwrites-root ci-upstream-kasan-gce ci-upstream-kasan-gce-386 ci-upstream-kasan-gce-root ci-upstream-kasan-gce-selinux-root ci-upstream-kasan-gce-smack-root ci-upstream-linux-next-kasan-gce-root ci-upstream-net-kasan-gce ci-upstream-net-this-kasan-gce ci-upstream-rust-kasan-gce ci2-upstream-fs ci2-upstream-kcsan-gce ci2-upstream-usb], missing on: [ci-qemu-native-arm64-kvm ci-upstream-kmsan-gce-386-root ci-upstream-kmsan-gce-root]
First crash: 49d, last: 40d
Sample crash report:
Oops: general protection fault, probably for non-canonical address 0xdffffc0000000008: 0000 [#1] SMP KASAN NOPTI
KASAN: null-ptr-deref in range [0x0000000000000040-0x0000000000000047]
CPU: 1 UID: 0 PID: 18692 Comm: syz.7.3060 Tainted: G L syzkaller #0 PREEMPT(full)
Tainted: [L]=SOFTLOCKUP
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/16/2026
RIP: 0010:rfcomm_dev_shutdown+0x48/0xc0 net/bluetooth/rfcomm/tty.c:131
Code: df 48 89 fa 48 c1 ea 03 80 3c 02 00 75 70 48 8b ab e0 03 00 00 48 b8 00 00 00 00 00 fc ff df 48 8d 7d 40 48 89 fa 48 c1 ea 03 <80> 3c 02 00 75 5c 48 83 7d 40 00 74 14 e8 e6 5e 2e f7 ba 03 00 00
RSP: 0018:ffffc90006c1f7c0 EFLAGS: 00010202
RAX: dffffc0000000000 RBX: ffff88803bea1000 RCX: ffffc90020028000
RDX: 0000000000000008 RSI: ffffffff8adde8be RDI: 0000000000000040
RBP: 0000000000000000 R08: 0000000000000005 R09: 0000000000000000
R10: 0000000000000400 R11: 0000000000000000 R12: 0000000000000000
R13: ffff88803bea1130 R14: 0000000000000000 R15: 0000000000000000
FS: 00007f66d22976c0(0000) GS:ffff888123c4e000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000001b304f0ff8 CR3: 0000000034ad9000 CR4: 00000000003526f0
Call Trace:
<TASK>
tty_port_shutdown_locked+0x22a/0x2e0 drivers/tty/tty_port.c:362
tty_port_shutdown drivers/tty/tty_port.c:379 [inline]
tty_port_close drivers/tty/tty_port.c:734 [inline]
tty_port_close+0x68/0x180 drivers/tty/tty_port.c:729
tty_release+0x40e/0x1300 drivers/tty/tty_io.c:1720
tty_open+0x31d/0xe20 drivers/tty/tty_io.c:2121
chrdev_open+0x234/0x6a0 fs/char_dev.c:411
do_dentry_open+0x6ab/0x14d0 fs/open.c:996
vfs_open+0x82/0x3f0 fs/open.c:1101
do_open fs/namei.c:4837 [inline]
path_openat+0x19fa/0x2440 fs/namei.c:5000
do_file_open+0x20e/0x430 fs/namei.c:5029
do_sys_openat2+0x10f/0x1e0 fs/open.c:1417
do_sys_open fs/open.c:1423 [inline]
__do_sys_open fs/open.c:1431 [inline]
__se_sys_open fs/open.c:1427 [inline]
__x64_sys_open+0xfe/0x1d0 fs/open.c:1427
do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline]
do_syscall_64+0x123/0x790 arch/x86/entry/syscall_64.c:84
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f66d139e199
Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 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 e8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f66d2297028 EFLAGS: 00000246 ORIG_RAX: 0000000000000002
RAX: ffffffffffffffda RBX: 00007f66d1626180 RCX: 00007f66d139e199
RDX: 0000000000000235 RSI: 0000000000040000 RDI: 0000200000000580
RBP: 00007f66d14350b8 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007f66d1626218 R14: 00007f66d1626180 R15: 00007fff40a7b6a8
</TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:rfcomm_dev_shutdown+0x48/0xc0 net/bluetooth/rfcomm/tty.c:131
Code: df 48 89 fa 48 c1 ea 03 80 3c 02 00 75 70 48 8b ab e0 03 00 00 48 b8 00 00 00 00 00 fc ff df 48 8d 7d 40 48 89 fa 48 c1 ea 03 <80> 3c 02 00 75 5c 48 83 7d 40 00 74 14 e8 e6 5e 2e f7 ba 03 00 00
RSP: 0018:ffffc90006c1f7c0 EFLAGS: 00010202
RAX: dffffc0000000000 RBX: ffff88803bea1000 RCX: ffffc90020028000
RDX: 0000000000000008 RSI: ffffffff8adde8be RDI: 0000000000000040
RBP: 0000000000000000 R08: 0000000000000005 R09: 0000000000000000
R10: 0000000000000400 R11: 0000000000000000 R12: 0000000000000000
R13: ffff88803bea1130 R14: 0000000000000000 R15: 0000000000000000
FS: 00007f66d22976c0(0000) GS:ffff888123c4e000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000564e3796fdb8 CR3: 0000000034ad9000 CR4: 00000000003526f0
----------------
Code disassembly (best guess):
0: df 48 89 fisttps -0x77(%rax)
3: fa cli
4: 48 c1 ea 03 shr $0x3,%rdx
8: 80 3c 02 00 cmpb $0x0,(%rdx,%rax,1)
c: 75 70 jne 0x7e
e: 48 8b ab e0 03 00 00 mov 0x3e0(%rbx),%rbp
15: 48 b8 00 00 00 00 00 movabs $0xdffffc0000000000,%rax
1c: fc ff df
1f: 48 8d 7d 40 lea 0x40(%rbp),%rdi
23: 48 89 fa mov %rdi,%rdx
26: 48 c1 ea 03 shr $0x3,%rdx
* 2a: 80 3c 02 00 cmpb $0x0,(%rdx,%rax,1) <-- trapping instruction
2e: 75 5c jne 0x8c
30: 48 83 7d 40 00 cmpq $0x0,0x40(%rbp)
35: 74 14 je 0x4b
37: e8 e6 5e 2e f7 call 0xf72e5f22
3c: ba .byte 0xba
3d: 03 00 add (%rax),%eax
* Struck through repros no longer work on HEAD.