BUG: soft lockup in hci_sock_sendmsg (2)

14 views
Skip to first unread message

syzbot

unread,
May 4, 2022, 4:18:29 AM5/4/22
to syzkaller...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: e3a56aaade89 Linux 4.14.277
git tree: linux-4.14.y
console output: https://syzkaller.appspot.com/x/log.txt?x=123b8dfcf00000
kernel config: https://syzkaller.appspot.com/x/.config?x=24efab1c7c06be56
dashboard link: https://syzkaller.appspot.com/bug?extid=8e7fd0be1d8dc16daf4d
compiler: gcc version 10.2.1 20210110 (Debian 10.2.1-6)

Unfortunately, I don't have any reproducer for this issue yet.

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+8e7fd0...@syzkaller.appspotmail.com

watchdog: BUG: soft lockup - CPU#0 stuck for 22s! [syz-executor.0:13747]
Modules linked in:
irq event stamp: 2824088
hardirqs last enabled at (2824087): [<ffffffff87400976>] restore_regs_and_return_to_kernel+0x0/0x2a
hardirqs last disabled at (2824088): [<ffffffff874018ae>] apic_timer_interrupt+0x8e/0xa0 arch/x86/entry/entry_64.S:793
softirqs last enabled at (3160): [<ffffffff8760068b>] __do_softirq+0x68b/0x9ff kernel/softirq.c:314
softirqs last disabled at (3031): [<ffffffff81321cf3>] invoke_softirq kernel/softirq.c:368 [inline]
softirqs last disabled at (3031): [<ffffffff81321cf3>] irq_exit+0x193/0x240 kernel/softirq.c:409
CPU: 0 PID: 13747 Comm: syz-executor.0 Not tainted 4.14.277-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
task: ffff888055e2c540 task.stack: ffff88809bcb8000
RIP: 0010:pv_wait_head_or_lock kernel/locking/qspinlock_paravirt.h:411 [inline]
RIP: 0010:__pv_queued_spin_lock_slowpath+0x265/0x910 kernel/locking/qspinlock.c:465
RSP: 0018:ffff88809bcbf988 EFLAGS: 00000206 ORIG_RAX: ffffffffffffff10
RAX: 0000000000000003 RBX: ffff8880ba434f00 RCX: fffffbfff13bb6b5
RDX: 0000000000004229 RSI: 0000000000000004 RDI: 0000000000000286
RBP: ffffffff89ddb5ac R08: 0000000000000001 R09: 0000000000000000
R10: 0000000000000001 R11: 0000000000000000 R12: 0000000000000000
R13: dffffc0000000000 R14: ffffffff89ddb5ad R15: ffffed10174869e8
FS: 00007f58dce1c700(0000) GS:ffff8880ba400000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f1e71e5bff8 CR3: 00000000b573d000 CR4: 00000000003406f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
pv_queued_spin_lock_slowpath arch/x86/include/asm/paravirt.h:669 [inline]
queued_spin_lock_slowpath arch/x86/include/asm/qspinlock.h:52 [inline]
queued_spin_lock include/asm-generic/qspinlock.h:90 [inline]
queued_read_lock_slowpath+0x150/0x190 kernel/locking/qrwlock.c:90
hci_send_to_channel+0x3c/0x200 net/bluetooth/hci_sock.c:272
hci_send_monitor_ctrl_event+0x3dd/0x500 net/bluetooth/hci_sock.c:402
mgmt_send_event+0x2b3/0x330 net/bluetooth/mgmt_util.c:86
mgmt_event net/bluetooth/mgmt.c:270 [inline]
unblock_device+0x135/0x1f0 net/bluetooth/mgmt.c:3840
hci_mgmt_cmd net/bluetooth/hci_sock.c:1590 [inline]
hci_sock_sendmsg+0x175b/0x1d00 net/bluetooth/hci_sock.c:1725
sock_sendmsg_nosec net/socket.c:646 [inline]
sock_sendmsg+0xb5/0x100 net/socket.c:656
sock_write_iter+0x22c/0x370 net/socket.c:925
call_write_iter include/linux/fs.h:1780 [inline]
new_sync_write fs/read_write.c:469 [inline]
__vfs_write+0x44c/0x630 fs/read_write.c:482
vfs_write+0x17f/0x4d0 fs/read_write.c:544
SYSC_write fs/read_write.c:590 [inline]
SyS_write+0xf2/0x210 fs/read_write.c:582
do_syscall_64+0x1d5/0x640 arch/x86/entry/common.c:292
entry_SYSCALL_64_after_hwframe+0x46/0xbb
RIP: 0033:0x7f58de4a70e9
RSP: 002b:00007f58dce1c168 EFLAGS: 00000246 ORIG_RAX: 0000000000000001
RAX: ffffffffffffffda RBX: 00007f58de5b9f60 RCX: 00007f58de4a70e9
RDX: 000000000000000d RSI: 00000000200000c0 RDI: 0000000000000013
RBP: 00007f58de50108d R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007fff41d83bef R14: 00007f58dce1c300 R15: 0000000000022000
Code: 84 c0 0f 85 2e 04 00 00 48 89 e9 48 89 ee c6 45 01 01 ba 00 80 00 00 48 c1 e9 03 83 e6 07 41 b8 01 00 00 00 4c 01 e9 eb 0b f3 90 <83> ea 01 0f 84 42 04 00 00 0f b6 01 40 38 f0 7f 08 84 c0 0f 85
Sending NMI from CPU 0 to CPUs 1:
NMI backtrace for cpu 1
CPU: 1 PID: 13749 Comm: syz-executor.1 Not tainted 4.14.277-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
task: ffff88809c6fc340 task.stack: ffff88809cc90000
RIP: 0010:native_apic_mem_write+0x8/0x10 arch/x86/include/asm/apic.h:100
RSP: 0018:ffff8880ba507eb8 EFLAGS: 00000046
RAX: dffffc0000000000 RBX: ffffffff88cca000 RCX: 0000000000000020
RDX: 1ffffffff119941d RSI: 0000000000000186 RDI: 0000000000000380
RBP: ffff8880ba5282c0 R08: ffff88823fff7058 R09: ffff88823fff704f
R10: ffff88823fff7057 R11: 00000033d570b758 R12: 0000000000000186
R13: 0000000000000003 R14: 0000003270a844a6 R15: 0000350ff440e698
FS: 00007f5903236700(0000) GS:ffff8880ba500000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f9761dd7000 CR3: 00000000970f2000 CR4: 00000000003406e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
<IRQ>
apic_write arch/x86/include/asm/apic.h:385 [inline]
lapic_next_event+0x53/0x80 arch/x86/kernel/apic/apic.c:468
clockevents_program_event+0x1f1/0x2d0 kernel/time/clockevents.c:339
tick_program_event+0x78/0xd0 kernel/time/tick-oneshot.c:47
hrtimer_interrupt+0x336/0x5e0 kernel/time/hrtimer.c:1334
local_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1079 [inline]
smp_apic_timer_interrupt+0x117/0x5e0 arch/x86/kernel/apic/apic.c:1104
apic_timer_interrupt+0x93/0xa0 arch/x86/entry/entry_64.S:793
</IRQ>
RIP: 0010:__read_once_size include/linux/compiler.h:185 [inline]
RIP: 0010:atomic_read arch/x86/include/asm/atomic.h:27 [inline]
RIP: 0010:queued_write_lock_slowpath+0xcb/0x1d0 kernel/locking/qrwlock.c:139
RSP: 0018:ffff88809cc97d38 EFLAGS: 00000206 ORIG_RAX: ffffffffffffff10
RAX: 0000000000000101 RBX: ffffffff89ddb5a8 RCX: 00000000000032ee
RDX: 0000000000000000 RSI: 0000000000000001 RDI: ffffffff89ddb5a8
RBP: ffffffff89ddb5ac R08: ffffffff8b9bf230 R09: 000000000004059f
R10: ffff88809c6fcbf0 R11: ffff88809c6fc340 R12: 0000000000000003
R13: fffffbfff13bb6b5 R14: 00000000000000ff R15: ffffffff8863e740
queued_write_lock include/asm-generic/qrwlock.h:134 [inline]
do_raw_write_lock+0xc2/0x1d0 kernel/locking/spinlock_debug.c:203
bt_sock_link+0x1f/0x120 net/bluetooth/af_bluetooth.c:143
hci_sock_create+0x15c/0x1d0 net/bluetooth/hci_sock.c:2034
bt_sock_create+0x13b/0x280 net/bluetooth/af_bluetooth.c:130
__sock_create+0x303/0x620 net/socket.c:1275
sock_create net/socket.c:1315 [inline]
SYSC_socket net/socket.c:1345 [inline]
SyS_socket+0xd1/0x1b0 net/socket.c:1325
do_syscall_64+0x1d5/0x640 arch/x86/entry/common.c:292
entry_SYSCALL_64_after_hwframe+0x46/0xbb
RIP: 0033:0x7f59048c10e9
RSP: 002b:00007f5903236108 EFLAGS: 00000246 ORIG_RAX: 0000000000000029
RAX: ffffffffffffffda RBX: 00007f59049d3f60 RCX: 00007f59048c10e9
RDX: 0000000000000001 RSI: 0000000000000003 RDI: 000000000000001f
RBP: 0000000000000004 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007fff00bde3df R14: 00007f5903236300 R15: 0000000000022000
Code: 83 3d 0c 1c 0c 0a 01 7f 02 5d c3 89 ef 5d e9 02 5f df 05 48 c7 c7 c0 a3 2e 8b e8 84 76 5c 00 eb df 66 90 89 ff 89 b7 00 c0 5f ff <c3> 0f 1f 80 00 00 00 00 48 b8 00 00 00 00 00 fc ff df 53 89 fb
----------------
Code disassembly (best guess):
0: 84 c0 test %al,%al
2: 0f 85 2e 04 00 00 jne 0x436
8: 48 89 e9 mov %rbp,%rcx
b: 48 89 ee mov %rbp,%rsi
e: c6 45 01 01 movb $0x1,0x1(%rbp)
12: ba 00 80 00 00 mov $0x8000,%edx
17: 48 c1 e9 03 shr $0x3,%rcx
1b: 83 e6 07 and $0x7,%esi
1e: 41 b8 01 00 00 00 mov $0x1,%r8d
24: 4c 01 e9 add %r13,%rcx
27: eb 0b jmp 0x34
29: f3 90 pause
* 2b: 83 ea 01 sub $0x1,%edx <-- trapping instruction
2e: 0f 84 42 04 00 00 je 0x476
34: 0f b6 01 movzbl (%rcx),%eax
37: 40 38 f0 cmp %sil,%al
3a: 7f 08 jg 0x44
3c: 84 c0 test %al,%al
3e: 0f .byte 0xf
3f: 85 .byte 0x85


---
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 syzk...@googlegroups.com.

syzbot will keep track of this issue. See:
https://goo.gl/tpsmEJ#status for how to communicate with syzbot.

syzbot

unread,
May 24, 2022, 12:52:33 PM5/24/22
to syzkaller...@googlegroups.com
syzbot has found a reproducer for the following issue on:

HEAD commit: dffb5c6ff09c Linux 4.14.280
git tree: linux-4.14.y
console output: https://syzkaller.appspot.com/x/log.txt?x=12a189c3f00000
kernel config: https://syzkaller.appspot.com/x/.config?x=9bde605ce69ece2e
dashboard link: https://syzkaller.appspot.com/bug?extid=8e7fd0be1d8dc16daf4d
compiler: gcc version 10.2.1 20210110 (Debian 10.2.1-6)
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=11fea2f9f00000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=10079e61f00000

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+8e7fd0...@syzkaller.appspotmail.com

IPVS: ftp: loaded support on port[0] = 21
IPVS: ftp: loaded support on port[0] = 21
IPVS: ftp: loaded support on port[0] = 21
IPVS: ftp: loaded support on port[0] = 21
IPVS: ftp: loaded support on port[0] = 21
watchdog: BUG: soft lockup - CPU#1 stuck for 22s! [syz-executor777:8974]
Modules linked in:
irq event stamp: 9662
hardirqs last enabled at (9661): [<ffffffff812307db>] kvm_wait arch/x86/kernel/kvm.c:600 [inline]
hardirqs last enabled at (9661): [<ffffffff812307db>] kvm_wait+0x14b/0x240 arch/x86/kernel/kvm.c:580
hardirqs last disabled at (9662): [<ffffffff874018ae>] apic_timer_interrupt+0x8e/0xa0 arch/x86/entry/entry_64.S:793
softirqs last enabled at (662): [<ffffffff8760068b>] __do_softirq+0x68b/0x9ff kernel/softirq.c:314
softirqs last disabled at (477): [<ffffffff81321cf3>] invoke_softirq kernel/softirq.c:368 [inline]
softirqs last disabled at (477): [<ffffffff81321cf3>] irq_exit+0x193/0x240 kernel/softirq.c:409
CPU: 1 PID: 8974 Comm: syz-executor777 Not tainted 4.14.280-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
task: ffff888092d7a100 task.stack: ffff888093ac8000
RIP: 0010:native_safe_halt+0xe/0x10 arch/x86/include/asm/irqflags.h:61
RSP: 0018:ffff888093acf960 EFLAGS: 00000282 ORIG_RAX: ffffffffffffff10
RAX: 1ffffffff11e1314 RBX: ffffffff89ddb66c RCX: 1ffff110125af549
RDX: dffffc0000000000 RSI: ffff888092d7aa28 RDI: ffff888092d7a984
RBP: 0000000000000003 R08: 0000000000000001 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000282
R13: dffffc0000000000 R14: ffffffff89ddb66d R15: ffffed10174a69e8
FS: 0000555555a80300(0000) GS:ffff8880ba500000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000020000040 CR3: 0000000092df0000 CR4: 00000000003406e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
arch_safe_halt arch/x86/include/asm/paravirt.h:94 [inline]
kvm_wait arch/x86/kernel/kvm.c:600 [inline]
kvm_wait+0x179/0x240 arch/x86/kernel/kvm.c:580
pv_wait arch/x86/include/asm/paravirt.h:679 [inline]
pv_wait_head_or_lock kernel/locking/qspinlock_paravirt.h:447 [inline]
__pv_queued_spin_lock_slowpath+0x722/0x910 kernel/locking/qspinlock.c:465
pv_queued_spin_lock_slowpath arch/x86/include/asm/paravirt.h:669 [inline]
queued_spin_lock_slowpath arch/x86/include/asm/qspinlock.h:52 [inline]
queued_spin_lock include/asm-generic/qspinlock.h:90 [inline]
queued_read_lock_slowpath+0x150/0x190 kernel/locking/qrwlock.c:90
hci_send_to_channel+0x3c/0x200 net/bluetooth/hci_sock.c:272
hci_send_monitor_ctrl_event+0x3dd/0x500 net/bluetooth/hci_sock.c:402
mgmt_send_event+0x2b3/0x330 net/bluetooth/mgmt_util.c:86
mgmt_event net/bluetooth/mgmt.c:270 [inline]
unblock_device+0x135/0x1f0 net/bluetooth/mgmt.c:3840
hci_mgmt_cmd net/bluetooth/hci_sock.c:1590 [inline]
hci_sock_sendmsg+0x175b/0x1d00 net/bluetooth/hci_sock.c:1725
sock_sendmsg_nosec net/socket.c:646 [inline]
sock_sendmsg+0xb5/0x100 net/socket.c:656
sock_write_iter+0x22c/0x370 net/socket.c:925
call_write_iter include/linux/fs.h:1780 [inline]
new_sync_write fs/read_write.c:469 [inline]
__vfs_write+0x44c/0x630 fs/read_write.c:482
vfs_write+0x17f/0x4d0 fs/read_write.c:544
SYSC_write fs/read_write.c:590 [inline]
SyS_write+0xf2/0x210 fs/read_write.c:582
do_syscall_64+0x1d5/0x640 arch/x86/entry/common.c:292
entry_SYSCALL_64_after_hwframe+0x46/0xbb
RIP: 0033:0x7fadfd73e419
RSP: 002b:00007ffc00326878 EFLAGS: 00000246 ORIG_RAX: 0000000000000001
RAX: ffffffffffffffda RBX: 0000000000000003 RCX: 00007fadfd73e419
RDX: 000000000000000d RSI: 00000000200000c0 RDI: 0000000000000004
RBP: 0000000000000003 R08: 0000000000000150 R09: 0000000000000150
R10: 0000000000000150 R11: 0000000000000246 R12: 0000555555a802b8
R13: 0000000000000011 R14: 00007ffc003268e0 R15: 00007ffc00326898
Code: 94 5a fa e9 4f ff ff ff 48 89 ef e8 bd 94 5a fa eb 93 90 90 90 90 90 90 90 90 90 90 90 e9 07 00 00 00 0f 00 2d 24 23 63 00 fb f4 <c3> 90 e9 07 00 00 00 0f 00 2d 14 23 63 00 f4 c3 90 90 41 55 41
----------------
Code disassembly (best guess):
0: 94 xchg %eax,%esp
1: 5a pop %rdx
2: fa cli
3: e9 4f ff ff ff jmpq 0xffffff57
8: 48 89 ef mov %rbp,%rdi
b: e8 bd 94 5a fa callq 0xfa5a94cd
10: eb 93 jmp 0xffffffa5
12: 90 nop
13: 90 nop
14: 90 nop
15: 90 nop
16: 90 nop
17: 90 nop
18: 90 nop
19: 90 nop
1a: 90 nop
1b: 90 nop
1c: 90 nop
1d: e9 07 00 00 00 jmpq 0x29
22: 0f 00 2d 24 23 63 00 verw 0x632324(%rip) # 0x63234d
29: fb sti
2a: f4 hlt
* 2b: c3 retq <-- trapping instruction
2c: 90 nop
2d: e9 07 00 00 00 jmpq 0x39
32: 0f 00 2d 14 23 63 00 verw 0x632314(%rip) # 0x63234d
39: f4 hlt
3a: c3 retq
3b: 90 nop
3c: 90 nop
3d: 41 55 push %r13
3f: 41 rex.B

Reply all
Reply to author
Forward
0 new messages