panic: kernel diagnostic assertion "ps->ps_uvncount == 0" failed: file "/syzkaller/managers/setuid/kernel/sys/kern/kern_unveil.c", line 196 Stopped at db_enter+0x18: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND 375486 11349 0 0x14000 0x200 0 reaper db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:398 panic() at panic+0x15c sys/kern/subr_prf.c:212 __assert(ffffffff81fa04ed,ffffffff81f59f4d,c4,ffffffff81f64412) at __assert+0x2e sys/kern/subr_prf.c:159 unveil_destroy(ffff800020b3a6a0) at unveil_destroy+0x19f sys/kern/kern_unveil.c:196 exit1(ffff800020b38720,0,1) at exit1+0x389 sys/kern/kern_exit.c:218 sys_exit(ffff800020b38720,ffff80002500bab0,ffff80002500bb20) at sys_exit+0x17 sys/kern/kern_exit.c:94 syscall(ffff80002500bb90) at syscall+0x552 mi_syscall sys/sys/syscall_mi.h:99 [inline] syscall(ffff80002500bb90) at syscall+0x552 sys/arch/amd64/amd64/trap.c:574 Xsyscall(6,1,0,1,0,7f7fffff4b34) at Xsyscall+0x128 end of kernel end trace frame: 0x7f7fffff4b00, count: 7 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{1}> ddb{1}> set $lines = 0 ddb{1}> set $maxwidth = 0 ddb{1}> show panic kernel diagnostic assertion "ps->ps_uvncount == 0" failed: file "/syzkaller/managers/setuid/kernel/sys/kern/kern_unveil.c", line 196 ddb{1}> trace db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:398 panic() at panic+0x15c sys/kern/subr_prf.c:212 __assert(ffffffff81fa04ed,ffffffff81f59f4d,c4,ffffffff81f64412) at __assert+0x2e sys/kern/subr_prf.c:159 unveil_destroy(ffff800020b3a6a0) at unveil_destroy+0x19f sys/kern/kern_unveil.c:196 exit1(ffff800020b38720,0,1) at exit1+0x389 sys/kern/kern_exit.c:218 sys_exit(ffff800020b38720,ffff80002500bab0,ffff80002500bb20) at sys_exit+0x17 sys/kern/kern_exit.c:94 syscall(ffff80002500bb90) at syscall+0x552 mi_syscall sys/sys/syscall_mi.h:99 [inline] syscall(ffff80002500bb90) at syscall+0x552 sys/arch/amd64/amd64/trap.c:574 Xsyscall(6,1,0,1,0,7f7fffff4b34) at Xsyscall+0x128 end of kernel end trace frame: 0x7f7fffff4b00, count: -8 ddb{1}> show registers rdi 0 rsi 0x1 rbp 0xffff80002500b8b0 rbx 0xffff80002500b960 rdx 0xffff800020b38720 rcx 0 rax 0 r8 0xffffffff81db9223 kprintf+0x173 r9 0x1 r10 0x25 r11 0x5207a2ac7c4151b r12 0x3000000008 r13 0xffff80002500b8c0 r14 0x100 r15 0x1 rip 0xffffffff816dbf58 db_enter+0x18 cs 0x8 rflags 0x246 rsp 0xffff80002500b8a0 ss 0 db_enter+0x18: addq $0x8,%rsp ddb{1}> show proc PROC (syz-executor.1) pid=488252 stat=onproc flags process=1018 proc=2000 pri=50, usrpri=75, nice=20 forw=0xffffffffffffffff, list=0xffff800020b384c8,0xffffffff8237fac0 process=0xffff800020b3a6a0 user=0xffff800025006000, vmspace=0xfffffd807f00b708 estcpu=25, cpticks=5, pctcpu=0.15 user=0, sys=1, intr=0 ddb{1}> ps PID TID PPID UID S FLAGS WAIT COMMAND 97513 498979 49061 32767 3 0x90 nanosleep syz-executor.1 49061 226354 48416 0 3 0x82 wait syz-executor.1 72394 278359 0 0 3 0x14200 bored sosplice 48416 97105 34025 0 3 0x82 thrsleep syz-fuzzer 48416 45146 34025 0 3 0x4000082 nanosleep syz-fuzzer 48416 434798 34025 0 3 0x4000082 thrsleep syz-fuzzer 48416 377579 34025 0 3 0x4000082 thrsleep syz-fuzzer 48416 154439 34025 0 3 0x4000082 thrsleep syz-fuzzer 48416 316471 34025 0 3 0x4000082 thrsleep syz-fuzzer 48416 74764 34025 0 2 0x4000002 syz-fuzzer 48416 68696 34025 0 3 0x4000082 thrsleep syz-fuzzer 48416 290457 34025 0 3 0x4000082 thrsleep syz-fuzzer 48416 410974 34025 0 3 0x4000082 kqread syz-fuzzer 34025 39555 51892 0 3 0x10008a pause ksh 51892 44512 78434 0 3 0x92 select sshd 32221 456924 1 0 3 0x100083 ttyin getty 78434 166821 1 0 3 0x80 select sshd 78113 43418 2386 73 3 0x100090 kqread syslogd 2386 413933 1 0 3 0x100082 netio syslogd 91277 24216 1 77 3 0x100090 poll dhclient 4251 75241 1 0 3 0x80 poll dhclient 94252 146460 0 0 2 0x14200 zerothread 15027 4492 0 0 3 0x14200 aiodoned aiodoned 40134 372832 0 0 3 0x14200 syncer update 14535 302169 0 0 3 0x14200 cleaner cleaner 11349 375486 0 0 7 0x14200 reaper 93351 267085 0 0 3 0x14200 pgdaemon pagedaemon 92940 209053 0 0 3 0x14200 bored crynlk 76746 427894 0 0 3 0x14200 bored crypto 55004 428894 0 0 3 0x40014200 acpi0 acpi0 35870 499811 0 0 3 0x40014200 idle1 15630 392452 0 0 3 0x14200 bored softnet 93261 268999 0 0 3 0x14200 bored systqmp 88257 309407 0 0 3 0x14200 bored systq 80207 442533 0 0 3 0x40014200 bored softclock 68365 406968 0 0 3 0x40014200 idle0 59489 500605 0 0 3 0x14200 bored smr 1 196481 0 0 3 0x82 wait init 0 0 -1 0 3 0x10200 scheduler swapper ddb{1}> show all locks ddb{1}> show malloc Type InUse MemUse HighUse Limit Requests Type Lim Kern Lim devbuf 9454 6319K 6321K 78643K 10656 0 0 pcb 23 9K 11K 78643K 790 0 0 rtable 83 2K 3K 78643K 1178 0 0 ifaddr 29 9K 10K 78643K 170 0 0 counters 39 33K 33K 78643K 39 0 0 ioctlops 0 0K 2K 78643K 74 0 0 iov 0 0K 16K 78643K 1094 0 0 mount 1 1K 1K 78643K 1 0 0 vnodes 1209 76K 76K 78643K 2012 0 0 UFS quota 1 32K 32K 78643K 1 0 0 UFS mount 5 36K 36K 78643K 5 0 0 shm 2 1K 5K 78643K 16 0 0 VM map 2 1K 1K 78643K 2 0 0 sem 12 0K 0K 78643K 615 0 0 dirhash 12 2K 2K 78643K 12 0 0 ACPI 1808 196K 290K 78643K 12628 0 0 file desc 4 9K 33K 78643K 4554 0 0 sigio 0 0K 0K 78643K 18 0 0 proc 44 50K 70K 78643K 1348 0 0 subproc 17 1K 2K 78643K 408 0 0 NFS srvsock 1 0K 0K 78643K 1 0 0 NFS daemon 1 16K 16K 78643K 1 0 0 ip_moptions 0 0K 0K 78643K 117 0 0 in_multi 22 1K 2K 78643K 308 0 0 ether_multi 1 0K 0K 78643K 8 0 0 ISOFS mount 1 32K 32K 78643K 1 0 0 MSDOSFS mount 1 16K 16K 78643K 1 0 0 ttys 54 238K 238K 78643K 54 0 0 exec 0 0K 1K 78643K 529 0 0 pagedep 1 8K 8K 78643K 1 0 0 inodedep 1 32K 32K 78643K 1 0 0 newblk 1 0K 0K 78643K 1 0 0 VM swap 7 26K 26K 78643K 7 0 0 UVM amap 86 12K 29K 78643K 14039 0 0 UVM aobj 61 2K 2K 78643K 68 0 0 memdesc 1 4K 4K 78643K 1 0 0 crypto data 1 1K 1K 78643K 1 0 0 ip6_options 0 0K 0K 78643K 65 0 0 NDP 4 0K 0K 78643K 75 0 0 temp 97 2733K 2800K 78643K 15474 0 0 kqueue 0 0K 0K 78643K 22 0 0 SYN cache 2 16K 16K 78643K 2 0 0 ddb{1}> show all pools Name Size Requests Fail Releases Pgreq Pgrel Npage Hiwat Minpg Maxpg Idle arp 64 50 0 46 1 0 1 1 0 8 0 inpcbpl 280 611 0 604 1 0 1 1 0 8 0 plimitpl 152 108 0 101 1 0 1 1 0 8 0 plcache 128 20 0 0 1 0 1 1 0 8 0 rtentry 112 287 0 254 2 0 2 2 0 8 0 syncache 264 4 0 4 1 1 0 1 0 8 0 tcpcb 544 227 0 223 1 0 1 1 0 8 0 nd6 48 72 0 69 1 0 1 1 0 8 0 art_heap8 4096 1 0 0 1 0 1 1 0 8 0 art_heap4 256 1187 0 1040 12 0 12 12 0 8 0 art_table 32 1188 0 1040 2 0 2 2 0 8 0 art_node 16 286 0 256 1 0 1 1 0 8 0 semapl 112 607 0 597 1 0 1 1 0 8 0 shmpl 112 66 0 7 2 0 2 2 0 8 0 dirhash 1024 17 0 0 3 0 3 3 0 8 0 dino1pl 128 6773 0 5336 47 0 47 47 0 8 0 ffsino 272 6773 0 5336 97 0 97 97 0 8 0 nchpl 144 12415 0 10801 61 0 61 61 0 8 0 uvmvnodes 72 5926 0 0 108 0 108 108 0 8 0 vnodes 200 5926 0 0 312 0 312 312 0 8 0 namei 1024 33285 0 33285 1 0 1 1 0 8 1 percpumem 16 30 0 0 1 0 1 1 0 8 0 scxspl 192 35325 0 35325 19 18 1 6 0 8 1 sigapl 432 4659 0 4646 3 1 2 3 0 8 0 futexpl 56 29773 0 29773 1 0 1 1 0 8 1 knotepl 112 753 0 740 1 0 1 1 0 8 0 kqueuepl 104 259 0 257 1 0 1 1 0 8 0 pipepl 112 1162 0 1149 5 4 1 2 0 8 0 fdescpl 488 4660 0 4647 3 0 3 3 0 8 1 filepl 152 14411 0 14339 10 5 5 7 0 8 1 lockfpl 104 264 0 264 7 6 1 1 0 8 1 lockfspl 48 89 0 89 7 6 1 1 0 8 1 sessionpl 112 39 0 30 1 0 1 1 0 8 0 pgrppl 48 58 0 49 1 0 1 1 0 8 0 ucredpl 96 3670 0 3662 1 0 1 1 0 8 0 zombiepl 144 4647 0 4646 1 0 1 1 0 8 0 processpl 840 4676 0 4646 4 0 4 4 0 8 0 procpl 600 12425 0 12384 4 0 4 4 0 8 0 srpgc 64 138 0 138 7 6 1 1 0 8 1 sosppl 128 20 0 20 7 7 0 1 0 8 0 sockpl 384 1426 0 1409 8 5 3 4 0 8 1 mcl64k 65536 3 0 0 1 0 1 1 0 8 0 mcl16k 16384 3 0 0 1 0 1 1 0 8 0 mcl12k 12288 11 0 0 2 0 2 2 0 8 0 mcl9k 9216 3 0 0 1 0 1 1 0 8 0 mcl8k 8192 4 0 0 1 0 1 1 0 8 0 mcl4k 4096 8 0 0 1 0 1 1 0 8 0 mcl2k2 2112 4 0 0 1 0 1 1 0 8 0 mcl2k 2048 117 0 0 14 0 14 14 0 8 0 mtagpl 80 1 0 0 1 0 1 1 0 8 0 mbufpl 256 253 0 0 11 0 11 11 0 8 0 bufpl 256 12006 0 5001 438 0 438 438 0 8 0 anonpl 16 343971 0 337718 62 34 28 42 0 125 0 amapchunkpl 152 25028 0 24938 21 16 5 9 0 158 1 amappl16 192 17859 0 17525 61 44 17 29 0 8 0 amappl15 184 174 0 171 4 3 1 1 0 8 0 amappl14 176 355 0 350 1 0 1 1 0 8 0 amappl13 168 731 0 731 4 3 1 1 0 8 1 amappl12 160 2828 0 2828 2 2 0 1 0 8 0 amappl11 152 228 0 214 1 0 1 1 0 8 0 amappl10 144 491 0 487 1 0 1 1 0 8 0 amappl9 136 867 0 865 1 0 1 1 0 8 0 amappl8 128 431 0 407 1 0 1 1 0 8 0 amappl7 120 483 0 475 1 0 1 1 0 8 0 amappl6 112 205 0 196 1 0 1 1 0 8 0 amappl5 104 3081 0 3071 1 0 1 1 0 8 0 amappl4 96 2568 0 2541 1 0 1 1 0 8 0 amappl3 88 3190 0 3173 1 0 1 1 0 8 0 amappl2 80 34819 0 34756 3 0 3 3 0 8 0 amappl1 72 123824 0 123408 23 13 10 19 0 8 0 amappl 80 13003 0 12968 1 0 1 1 0 84 0 dma4096 4096 1 0 1 1 1 0 1 0 8 0 dma256 256 6 0 6 1 1 0 1 0 8 0 dma64 64 259 0 259 1 1 0 1 0 8 0 dma32 32 7 0 7 1 1 0 1 0 8 0 dma16 16 17 0 17 1 1 0 1 0 8 0 aobjpl 64 67 0 7 1 0 1 1 0 8 0 uaddrrnd 24 4660 0 4646 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 4660 0 4646 1 0 1 1 0 8 0 vmmpekpl 168 33390 0 33362 2 0 2 2 0 8 0 vmmpepl 168 506829 0 505503 121 51 70 77 0 357 3 vmsppl 360 4659 0 4646 2 0 2 2 0 8 0 pdppl 4096 9328 0 9292 6 0 6 6 0 8 1 pvpl 32 976726 0 966839 185 103 82 114 0 265 0 pmappl 232 4659 0 4646 3 2 1 2 0 8 0 extentpl 40 41 0 26 1 0 1 1 0 8 0 phpool 112 590 0 2 17 0 17 17 0 8 0