panic: kernel diagnostic assertion "pr->ps_threadcnt == 0" failed: file "/syzkaller/managers/main/kernel/sys/kern/kern_exit.c", line 886 Stopped at db_enter+0x25: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND *401190 33781 0 0x14000 0x200 0 reaper db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:438 panic(ffffffff833766a7) at panic+0x1cf sys/kern/subr_prf.c:198 __assert(ffffffff833b52e7,ffffffff833d8e44,376,ffffffff833d8e79) at __assert+0x29 sys/kern/subr_prf.c:-1 process_zap(ffff8000ffffad18) at process_zap+0x31d sys/kern/kern_exit.c:887 reaper(ffff80002a72cf90) at reaper+0x270 sys/kern/kern_exit.c:521 end trace frame: 0x0, count: 10 https://www.openbsd.org/ddb.html describes the minimum info required in bug reports. Insufficient info makes it difficult to find and fix bugs. ddb> ddb> set $lines = 0 ddb> set $maxwidth = 0 ddb> show panic *cpu0: kernel diagnostic assertion "pr->ps_threadcnt == 0" failed: file "/syzkaller/managers/main/kernel/sys/kern/kern_exit.c", line 886 ddb> trace db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:438 panic(ffffffff833766a7) at panic+0x1cf sys/kern/subr_prf.c:198 __assert(ffffffff833b52e7,ffffffff833d8e44,376,ffffffff833d8e79) at __assert+0x29 sys/kern/subr_prf.c:-1 process_zap(ffff8000ffffad18) at process_zap+0x31d sys/kern/kern_exit.c:887 reaper(ffff80002a72cf90) at reaper+0x270 sys/kern/kern_exit.c:521 end trace frame: 0x0, count: -5 ddb> show registers rdi 0 rsi 0x1 rbp 0xffff80002a763cb0 rbx 0x40000 acpi_pdirpa+0x2be71 rdx 0 rcx 0 rax 0xffff80002a72cf90 r8 0x101010101010101 r9 0x8080808080808080 r10 0xc0d41f4dd6f5cb80 r11 0x2c945b503c7b105f r12 0 r13 0 r14 0 r15 0x1 rip 0xffffffff8102a245 db_enter+0x25 cs 0x8 rflags 0x246 rsp 0xffff80002a763ca0 ss 0x10 db_enter+0x25: addq $0x8,%rsp ddb> show proc PROC (reaper) tid=401190 pid=33781 tcnt=1 stat=onproc flags process=14000 proc=200 runpri=32, usrpri=50, slppri=32, nice=20 wchan=0x0, wmesg=, ps_single=0x0 scnt=0 ecnt=0 forw=0xffffffffffffffff, list=0xffff80002a72ca60,0xffff80002a72d768 process=0xffff8000ffffdb00 user=0xffff80002a75e000, vmspace=0xffffffff83977a98 estcpu=0, cpticks=6, pctcpu=0.0, user=0, sys=0, intr=0 ddb> ps PID TID PPID UID S FLAGS WAIT COMMAND 95933 379421 3835 0 2 0 syz-executor 95933 255785 3835 0 3 0x4000080 fsleep syz-executor 23786 347854 96110 0 2 0 syz-executor 23786 353266 96110 0 3 0x4000080 fsleep syz-executor 5317 222375 0 0 3 0x14280 nfsidl nfsio 45040 68115 97768 0 2 0 syz-executor 45040 163045 97768 0 3 0x4000080 fsleep syz-executor 65437 255392 79496 0 2 0 syz-executor 65437 217757 79496 0 3 0x4000080 fsleep syz-executor 59226 133004 71021 0 2 0 syz-executor 59226 253301 71021 0 2 0x4000000 syz-executor 59226 517873 71021 0 3 0x4000080 sysctllk syz-executor 19060 164747 46820 60929 3 0x3010 suspend syz-executor 19060 40312 46820 60929 2 0x4081010 syz-executor 19060 227773 46820 60929 3 0x4081010 inode syz-executor 46820 267609 18524 0 2 0xc82 syz-executor 96110 60940 18524 0 2 0x2 syz-executor 53783 511013 18524 0 3 0x82 nanoslp syz-executor 3835 494067 18524 0 3 0x2 kqpsl syz-executor 79496 35782 18524 0 3 0x82 nanoslp syz-executor 29376 334270 18524 0 2 0x2 syz-executor 97768 484362 18524 0 3 0x82 nanoslp syz-executor 71021 82193 18524 0 3 0x82 nanoslp syz-executor 18524 235556 46487 0 3 0x82 kqread syz-executor 46487 521371 55317 0 3 0x10008a sigsusp ksh 55317 214939 46408 0 3 0x98 kqread sshd-session 46408 477793 36130 0 3 0x92 kqread sshd-session 48822 494773 1 0 3 0x100083 ttyin getty 36130 126089 1 0 3 0x88 kqread sshd 67001 125617 69992 73 3 0x1100090 kqread syslogd 69992 283265 1 0 3 0x100082 sbwait syslogd 52883 440785 1 0 3 0x100080 kqread resolvd 82562 457908 72076 77 3 0x100092 kqread dhcpleased 45272 30691 72076 77 3 0x100092 kqread dhcpleased 72076 21130 1 0 3 0x80 kqread dhcpleased 34146 226036 0 0 3 0x14200 bored smr 65960 120098 0 0 2 0x14200 zerothread 5826 122911 0 0 3 0x14200 aiodoned aiodoned 9537 522173 0 0 3 0x14200 syncer update 97645 81653 0 0 3 0x14200 cleaner cleaner *33781 401190 0 0 7 0x14200 reaper 32171 293605 0 0 3 0x14200 pgdaemon pagedaemon 74597 456334 0 0 3 0x14200 bored viomb 54442 371819 0 0 3 0x40014200 acpi0 acpi0 67289 19992 0 0 3 0x14200 bored softnet0 12886 85011 0 0 3 0x14200 bored systqmp 51363 183254 0 0 3 0x14200 bored systq 8347 65425 0 0 3 0x40014200 tmoslp softclock 10427 194688 0 0 3 0x40014200 idle0 1 139750 0 0 3 0x80082 wait init 0 0 -1 0 3 0x10200 scheduler swapper ddb> show all locks No such command ddb> show malloc Type InUse MemUse HighUse Limit Requests Type Lim devbuf 10178 11050K 11649K 166960K 12635 0 pcb 18 14K 18K 166960K 326 0 rtable 234 9K 10K 166960K 626 0 pf 29 12K 20K 166960K 113 0 ifaddr 39 7K 8K 166960K 83 0 ifgroup 46 2K 2K 166960K 118 0 sysctl 1 1K 9K 166960K 8 0 counters 32 17K 18K 166960K 67 0 ioctlops 0 0K 4K 166960K 315 0 iov 0 0K 16K 166960K 103 0 mount 1 1K 1K 166960K 1 0 log 0 0K 0K 166960K 4 0 vnodes 1402 88K 89K 166960K 2098 0 UFS quota 1 32K 32K 166960K 1 0 UFS mount 5 36K 36K 166960K 5 0 shm 2 1K 9K 166960K 14 0 VM map 2 1K 1K 166960K 2 0 sem 12 0K 0K 166960K 86 0 dirhash 12 2K 2K 166960K 24 0 ACPI 1692 195K 286K 166960K 12470 0 file desc 16 57K 97K 166960K 705 0 sigio 0 0K 0K 166960K 76 0 proc 60 59K 124K 166960K 564 0 subproc 72 4K 4K 166960K 81 0 NFS srvsock 1 0K 0K 166960K 1 0 NFS daemon 1 16K 16K 166960K 1 0 ip_moptions 2 0K 0K 166960K 80 0 in_multi 89 6K 7K 166960K 143 0 ether_multi 1 0K 0K 166960K 4 0 mrt 0 0K 0K 166960K 5 0 ISOFS mount 1 32K 32K 166960K 1 0 MSDOSFS mount 1 16K 16K 166960K 1 0 ttys 115 519K 519K 166960K 115 0 exec 0 0K 1K 166960K 463 0 fusefs mount 1 32K 32K 166960K 1 0 pfkey data 0 0K 0K 166960K 1 0 tdb 3 0K 0K 166960K 3 0 VM swap 8 62K 64K 166960K 10 0 UVM amap 224 143K 160K 166960K 8017 0 UVM aobj 27 8K 8K 166960K 31 0 pinsyscall 37 74K 96K 166960K 1799 0 memdesc 1 4K 4K 166960K 1 0 crypto data 1 1K 1K 166960K 1 0 ip6_options 2 0K 0K 166960K 27 0 NDP 10 0K 2K 166960K 53 0 temp 61 8663K 8729K 166960K 26504 0 kqueue 16 22K 30K 166960K 115 0 SYN cache 2 16K 16K 166960K 2 0 ddb> show all pools Name Size Requests Fail Releases Pgreq Pgrel Npage Hiwat Minpg Maxpg Idle rtpcb 120 129 0 125 2 0 2 2 0 8 1 rtentry 136 213 0 115 4 0 4 4 0 8 0 unpcb 144 494 0 476 6 4 2 6 0 8 1 syncache 336 4 0 4 1 1 0 1 0 8 0 tcpcb 736 213 0 209 8 6 2 7 0 8 1 arp 96 24 0 5 1 0 1 1 0 8 0 ipq 40 2 0 0 1 0 1 1 0 8 0 ipqe 40 3 0 1 1 0 1 1 0 8 0 inpcb 328 787 0 774 12 8 4 10 0 8 2 ip6q 72 6 0 2 1 0 1 1 0 8 0 ip6af 40 9 0 5 1 0 1 1 0 8 0 nd6 112 31 0 9 1 0 1 1 0 8 0 pkpcb 40 3 0 3 1 1 0 1 0 8 0 kcovpl 48 9 0 1 1 0 1 1 0 8 0 ppxss 1072 25 0 25 1 0 1 1 0 8 1 pppxif 1384 4 0 4 2 1 1 1 0 8 1 pfrktable 1344 1 0 1 1 1 0 1 0 8 0 pfanchor 1288 6 0 0 1 0 1 1 0 8 0 pfstkey 128 1 0 1 1 1 0 1 0 8 0 pfstate 384 1 0 1 1 1 0 1 0 8 0 pfrule 1344 4 0 4 2 1 1 1 0 8 1 rttmr 136 1 0 1 1 1 0 1 0 8 0 art_heap8 4096 3 0 0 3 0 3 3 0 8 0 art_heap4 256 1066 0 660 51 22 29 51 0 8 1 art_table 40 1069 0 660 9 3 6 9 0 8 0 art_node 32 213 0 127 2 0 2 2 0 8 0 sysvmsgpl 40 8 0 7 1 0 1 1 0 8 0 semapl 112 84 0 74 1 0 1 1 0 8 0 shmpl 112 26 0 4 1 0 1 1 0 8 0 dirhash 1024 25 0 8 3 0 3 3 0 8 0 dino2pl 256 2710 0 1215 95 0 95 95 0 8 0 ffsino 256 2710 0 1215 95 0 95 95 0 8 0 nchpl 144 3697 0 2006 64 0 64 64 0 8 0 rtmask 32 8 0 8 1 1 0 1 0 8 0 vnodes 216 3239 0 0 180 0 180 180 0 8 0 namei 1024 13004 0 13003 2 1 1 2 0 8 0 vcpupl 3904 2 0 0 1 0 1 1 0 8 0 vmpool 800 2 0 0 1 0 1 1 0 8 0 kstatmem 264 66 0 46 2 0 2 2 0 8 0 scsiplug 72 1 0 1 1 1 0 1 0 8 0 scxspl 216 12331 0 12331 9 7 2 8 1 8 2 plimitpl 152 251 0 233 1 0 1 1 0 8 0 sigapl 424 990 0 947 6 1 5 6 0 8 0 knotepl 120 25390 0 25340 25 15 10 17 0 8 8 kqueuepl 184 317 0 305 4 3 1 4 0 8 0 pipepl 304 185 0 158 5 0 5 5 0 8 2 fdescpl 448 976 0 948 5 1 4 5 0 8 0 filepl 120 6295 0 6078 15 5 10 14 0 8 2 lockfpl 104 308 0 306 1 0 1 1 0 8 0 lockfspl 48 96 0 94 1 0 1 1 0 8 0 sessionpl 144 22 0 14 1 0 1 1 0 8 0 pgrppl 48 46 0 30 1 0 1 1 0 8 0 ucredpl 104 1094 0 1079 1 0 1 1 0 8 0 zombiepl 144 1063 0 1061 2 1 1 1 0 8 0 processpl 1152 990 0 947 4 0 4 4 0 8 0 procpl 664 1916 0 1862 7 1 6 6 0 8 0 sosppl 176 5 0 5 2 1 1 1 0 8 1 sockpl 552 1469 0 1434 14 9 5 12 0 8 2 mcl64k 65536 93 0 92 2 1 1 1 0 8 0 mcl8k 8192 8 0 8 2 1 1 1 0 8 1 mcl4k 4096 3227 0 3174 16 8 8 15 0 8 0 mcl2k 2048 1427 0 1419 4 2 2 4 0 8 0 mtagpl 96 60 0 5 2 0 2 2 0 8 0 mbufpl 256 99399 0 99163 225 201 24 118 0 8 7 bufpl 280 3809 0 127 263 0 263 263 0 8 0 anonpl 24 159099 0 155049 54 21 33 44 0 187 7 amapchunkpl 152 26752 0 26247 54 18 36 38 0 158 10 amappl16 200 2650 0 2595 15 11 4 14 0 8 0 amappl15 192 7 0 7 1 1 0 1 0 8 0 amappl14 184 8 0 8 1 1 0 1 0 8 0 amappl13 176 417 0 416 1 0 1 1 0 8 0 amappl12 168 1317 0 1279 3 1 2 3 0 8 0 amappl11 160 7 0 7 1 1 0 1 0 8 0 amappl10 152 45 0 35 1 0 1 1 0 8 0 amappl9 144 250 0 250 1 1 0 1 0 8 0 amappl8 136 51 0 49 1 0 1 1 0 8 0 amappl7 128 82 0 81 1 0 1 1 0 8 0 amappl6 120 275 0 264 1 0 1 1 0 8 0 amappl5 112 79 0 71 1 0 1 1 0 8 0 amappl4 104 399 0 375 1 0 1 1 0 8 0 amappl3 96 5099 0 4997 4 0 4 4 0 8 0 amappl2 88 510 0 456 2 0 2 2 0 8 0 amappl1 80 11068 0 10532 13 1 12 13 0 8 0 amappl 88 7231 0 7074 5 0 5 5 0 92 0 uvmvnodes 80 108 0 0 3 0 3 3 0 8 0 dma4096 4096 1 0 1 1 1 0 1 0 8 0 dma1024 1024 1 0 0 1 0 1 1 0 8 0 dma256 256 6 0 6 1 1 0 1 0 8 0 dma128 128 253 0 253 1 1 0 1 0 8 0 dma64 64 7 0 7 2 1 1 1 0 8 1 dma32 32 7 0 7 1 1 0 1 0 8 0 dma16 16 19 0 18 1 0 1 1 0 8 0 aobjpl 72 30 0 4 1 0 1 1 0 8 0 uaddrrnd 24 976 0 948 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 976 0 948 1 0 1 1 0 8 0 vmmpekpl 168 9153 0 9115 3 0 3 3 0 8 0 vmmpepl 168 67187 0 65427 90 8 82 88 0 357 1 vmsppl 368 975 0 947 4 1 3 4 0 8 0 rwobjpl 40 19847 0 18846 12 0 12 12 0 8 0 pdppl 4096 1962 0 1896 103 35 68 82 0 8 2 pvpl 32 434359 0 425001 126 31 95 110 0 265 13 pmappl 216 977 0 947 3 0 3 3 0 8 0 extentpl 40 45 0 27 1 0 1 1 0 8 0 phpool 112 622 0 282 14 1 13 14 0 8 0 ddb> machine ddbcpu 0 No such command ddb> trace db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:438 panic(ffffffff833766a7) at panic+0x1cf sys/kern/subr_prf.c:198 __assert(ffffffff833b52e7,ffffffff833d8e44,376,ffffffff833d8e79) at __assert+0x29 sys/kern/subr_prf.c:-1 process_zap(ffff8000ffffad18) at process_zap+0x31d sys/kern/kern_exit.c:887 reaper(ffff80002a72cf90) at reaper+0x270 sys/kern/kern_exit.c:521 end trace frame: 0x0, count: -5 ddb> machine ddbcpu 1 No such command ddb> trace db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:438 panic(ffffffff833766a7) at panic+0x1cf sys/kern/subr_prf.c:198 __assert(ffffffff833b52e7,ffffffff833d8e44,376,ffffffff833d8e79) at __assert+0x29 sys/kern/subr_prf.c:-1 process_zap(ffff8000ffffad18) at process_zap+0x31d sys/kern/kern_exit.c:887 reaper(ffff80002a72cf90) at reaper+0x270 sys/kern/kern_exit.c:521 end trace frame: 0x0, count: -5