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 221167 12894 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(ffffffff81f987de,ffffffff81f523f2,c4,ffffffff81f5c7b8) at __assert+0x2e sys/kern/subr_prf.c:159 unveil_destroy(ffff800020b8d080) at unveil_destroy+0x19f sys/kern/kern_unveil.c:196 exit1(ffff800020b38e28,0,1) at exit1+0x354 sys/kern/kern_exit.c:216 sys_exit(ffff800020b38e28,ffff800020c29670,ffff800020c296e0) at sys_exit+0x17 sys/kern/kern_exit.c:94 syscall(ffff800020c29750) at syscall+0x552 mi_syscall sys/sys/syscall_mi.h:99 [inline] syscall(ffff800020c29750) at syscall+0x552 sys/arch/amd64/amd64/trap.c:574 Xsyscall(6,1,0,1,431bde82d7b634db,7f7ffffee308) at Xsyscall+0x128 end trace frame: 0x0, 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(ffffffff81f987de,ffffffff81f523f2,c4,ffffffff81f5c7b8) at __assert+0x2e sys/kern/subr_prf.c:159 unveil_destroy(ffff800020b8d080) at unveil_destroy+0x19f sys/kern/kern_unveil.c:196 exit1(ffff800020b38e28,0,1) at exit1+0x354 sys/kern/kern_exit.c:216 sys_exit(ffff800020b38e28,ffff800020c29670,ffff800020c296e0) at sys_exit+0x17 sys/kern/kern_exit.c:94 syscall(ffff800020c29750) at syscall+0x552 mi_syscall sys/sys/syscall_mi.h:99 [inline] syscall(ffff800020c29750) at syscall+0x552 sys/arch/amd64/amd64/trap.c:574 Xsyscall(6,1,0,1,431bde82d7b634db,7f7ffffee308) at Xsyscall+0x128 end trace frame: 0x0, count: -8 ddb{1}> show registers rdi 0 rsi 0x1 rbp 0xffff800020c29470 rbx 0xffff800020c29520 rdx 0xffff800020b38e28 rcx 0 rax 0 r8 0xffffffff81db28a3 kprintf+0x173 r9 0x1 r10 0x25 r11 0x51758137dd3d3856 r12 0x3000000008 r13 0xffff800020c29480 r14 0x100 r15 0x1 rip 0xffffffff81422368 db_enter+0x18 cs 0x8 rflags 0x246 rsp 0xffff800020c29460 ss 0x10 db_enter+0x18: addq $0x8,%rsp ddb{1}> show proc PROC (syz-executor.1) pid=242227 stat=onproc flags process=1018 proc=2000 pri=86, usrpri=86, nice=20 forw=0xffffffffffffffff, list=0xffff800020b38270,0xffffffff823745c0 process=0xffff800020b8d080 user=0xffff800020c24000, vmspace=0xfffffd806f22d5a8 estcpu=36, cpticks=3, pctcpu=0.0 user=0, sys=2, intr=0 ddb{1}> ps PID TID PPID UID S FLAGS WAIT COMMAND 35286 112608 77894 32767 3 0x90 nanosleep syz-executor.1 77894 322917 94823 0 3 0x82 wait syz-executor.1 45975 477555 0 0 3 0x14200 bored sosplice 94823 258012 91725 0 3 0x82 thrsleep syz-fuzzer 94823 275721 91725 0 3 0x4000082 nanosleep syz-fuzzer 94823 475082 91725 0 3 0x4000082 thrsleep syz-fuzzer 94823 273654 91725 0 3 0x4000082 thrsleep syz-fuzzer 94823 127328 91725 0 3 0x4000002 biowait syz-fuzzer 94823 342571 91725 0 3 0x4000082 thrsleep syz-fuzzer 94823 241202 91725 0 3 0x4000082 thrsleep syz-fuzzer 94823 187571 91725 0 3 0x4000082 thrsleep syz-fuzzer 94823 117549 91725 0 3 0x4000082 thrsleep syz-fuzzer 94823 342162 91725 0 3 0x4000082 kqread syz-fuzzer 94823 305771 91725 0 3 0x4000082 thrsleep syz-fuzzer 91725 435375 45869 0 3 0x10008a pause ksh 45869 308363 35915 0 3 0x92 select sshd 51701 488333 1 0 3 0x100083 ttyin getty 35915 179197 1 0 3 0x80 select sshd 20577 364409 53083 73 3 0x100090 kqread syslogd 53083 308955 1 0 3 0x100082 netio syslogd 53318 370569 1 77 3 0x100090 poll dhclient 81883 163908 1 0 3 0x80 poll dhclient 1269 359322 0 0 3 0x14200 pgzero zerothread 80569 497124 0 0 3 0x14200 aiodoned aiodoned 35779 403542 0 0 3 0x14200 syncer update 53814 271741 0 0 3 0x14200 cleaner cleaner 12894 221167 0 0 7 0x14200 reaper 81064 93478 0 0 3 0x14200 pgdaemon pagedaemon 87555 65625 0 0 3 0x14200 bored crynlk 37208 427367 0 0 3 0x14200 bored crypto 40833 57206 0 0 3 0x40014200 acpi0 acpi0 37373 78522 0 0 3 0x40014200 idle1 61020 22996 0 0 3 0x14200 bored softnet 91902 465722 0 0 3 0x14200 bored systqmp 21793 145508 0 0 3 0x14200 bored systq 89260 493127 0 0 3 0x40014200 bored softclock 33319 18228 0 0 3 0x40014200 idle0 35357 99282 0 0 3 0x14200 bored smr 1 46119 0 0 3 0x82 wait init 0 0 -1 0 3 0x10200 scheduler swapper ddb{1}> show all locks Process 94823 (syz-fuzzer) thread 0xffff800020b85078 (127328) exclusive rrwlock inode r = 0 (0xfffffd807ad37f78) #0 witness_lock+0x52e sys/kern/subr_witness.c:1161 #1 rw_enter+0x414 sys/kern/kern_rwlock.c:278 #2 rrw_enter+0x4f sys/kern/kern_rwlock.c:407 #3 VOP_LOCK+0x4b sys/kern/vfs_vops.c:602 #4 vn_lock+0x6e sys/kern/vfs_vnops.c:549 #5 vget+0x1c3 sys/kern/vfs_subr.c:672 #6 ufs_ihashget+0x141 sys/ufs/ufs/ufs_ihash.c:119 #7 ffs_vget+0x74 sys/ufs/ffs/ffs_vfsops.c:1323 #8 ufs_lookup+0x1575 sys/ufs/ufs/ufs_lookup.c:487 #9 VOP_LOOKUP+0x5b sys/kern/vfs_vops.c:90 #10 vfs_lookup+0x575 sys/kern/vfs_lookup.c:523 #11 namei+0x45f sys/kern/vfs_lookup.c:224 #12 dounlinkat+0x99 sys/kern/vfs_syscalls.c:1673 #13 syscall+0x552 mi_syscall sys/sys/syscall_mi.h:99 [inline] #13 syscall+0x552 sys/arch/amd64/amd64/trap.c:574 #14 Xsyscall+0x128 exclusive rrwlock inode r = 0 (0xfffffd807ad371a8) #0 witness_lock+0x52e sys/kern/subr_witness.c:1161 #1 rw_enter+0x414 sys/kern/kern_rwlock.c:278 #2 rrw_enter+0x4f sys/kern/kern_rwlock.c:407 #3 VOP_LOCK+0x4b sys/kern/vfs_vops.c:602 #4 vn_lock+0x6e sys/kern/vfs_vnops.c:549 #5 vfs_lookup+0xec sys/kern/vfs_lookup.c:387 #6 namei+0x45f sys/kern/vfs_lookup.c:224 #7 dounlinkat+0x99 sys/kern/vfs_syscalls.c:1673 #8 syscall+0x552 mi_syscall sys/sys/syscall_mi.h:99 [inline] #8 syscall+0x552 sys/arch/amd64/amd64/trap.c:574 #9 Xsyscall+0x128 ddb{1}> show malloc Type InUse MemUse HighUse Limit Requests Type Lim Kern Lim devbuf 9456 6319K 6321K 78643K 10618 0 0 pcb 23 9K 10K 78643K 382 0 0 rtable 83 2K 3K 78643K 828 0 0 ifaddr 30 9K 10K 78643K 125 0 0 counters 39 33K 33K 78643K 39 0 0 ioctlops 0 0K 2K 78643K 37 0 0 iov 0 0K 16K 78643K 73 0 0 mount 1 1K 1K 78643K 1 0 0 vnodes 1201 75K 75K 78643K 1524 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 5 0 0 VM map 2 1K 1K 78643K 2 0 0 sem 12 0K 0K 78643K 115 0 0 dirhash 12 2K 2K 78643K 12 0 0 ACPI 1808 196K 290K 78643K 12628 0 0 file desc 4 9K 33K 78643K 739 0 0 sigio 0 0K 0K 78643K 12 0 0 proc 44 50K 78K 78643K 916 0 0 subproc 34 34817K 69634K 78643K 544 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 92 0 0 in_multi 22 1K 2K 78643K 214 0 0 ether_multi 1 0K 0K 78643K 6 0 0 ISOFS mount 1 32K 32K 78643K 1 0 0 MSDOSFS mount 1 16K 16K 78643K 1 0 0 ttys 66 291K 291K 78643K 66 0 0 exec 0 0K 1K 78643K 410 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 73 12K 30K 78643K 3182 0 0 UVM aobj 20 2K 2K 78643K 20 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 50 0 0 NDP 4 0K 0K 78643K 51 0 0 temp 97 2729K 2858K 78643K 8676 0 0 kqueue 0 0K 0K 78643K 6 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 34 0 30 1 0 1 1 0 8 0 inpcbpl 280 373 0 366 1 0 1 1 0 8 0 plimitpl 152 93 0 86 1 0 1 1 0 8 0 plcache 128 20 0 0 1 0 1 1 0 8 0 rtentry 112 199 0 166 2 0 2 2 0 8 0 syncache 264 4 0 4 1 1 0 1 0 8 0 tcpcb 544 145 0 141 1 0 1 1 0 8 0 nd6 48 48 0 45 1 0 1 1 0 8 0 art_heap8 4096 1 0 0 1 0 1 1 0 8 0 art_heap4 256 822 0 675 12 0 12 12 0 8 1 art_table 32 823 0 675 2 0 2 2 0 8 0 art_node 16 198 0 168 1 0 1 1 0 8 0 sysvmsgpl 40 9 0 5 1 0 1 1 0 8 0 semupl 112 1 0 1 1 1 0 1 0 8 0 semapl 112 113 0 103 1 0 1 1 0 8 0 shmpl 112 18 0 0 1 0 1 1 0 8 0 dirhash 1024 17 0 0 3 0 3 3 0 8 0 dino1pl 128 2122 0 685 47 0 47 47 0 8 0 ffsino 272 2122 0 685 98 1 97 97 0 8 1 nchpl 144 3139 0 1506 61 0 61 61 0 8 0 uvmvnodes 72 2403 0 0 44 0 44 44 0 8 0 vnodes 200 2403 0 0 127 0 127 127 0 8 0 namei 1024 10370 0 10370 2 1 1 1 0 8 1 percpumem 16 30 0 0 1 0 1 1 0 8 0 scxspl 192 18024 0 18023 10 9 1 6 0 8 0 sigapl 432 867 0 854 6 4 2 3 0 8 0 futexpl 56 6528 0 6528 1 0 1 1 0 8 1 knotepl 112 469 0 444 1 0 1 1 0 8 0 kqueuepl 104 184 0 182 1 0 1 1 0 8 0 pipepl 112 586 0 571 3 2 1 2 0 8 0 fdescpl 488 868 0 855 3 0 3 3 0 8 0 filepl 152 4994 0 4916 6 1 5 5 0 8 1 lockfpl 104 241 0 241 2 1 1 1 0 8 1 lockfspl 48 72 0 72 2 1 1 1 0 8 1 sessionpl 112 31 0 22 1 0 1 1 0 8 0 pgrppl 48 41 0 32 1 0 1 1 0 8 0 ucredpl 96 1087 0 1079 1 0 1 1 0 8 0 zombiepl 144 855 0 854 2 1 1 1 0 8 0 processpl 840 884 0 854 4 0 4 4 0 8 0 procpl 600 1971 0 1930 5 1 4 5 0 8 0 srpgc 64 90 0 90 3 2 1 1 0 8 1 sosppl 128 13 0 13 4 3 1 1 0 8 1 sockpl 384 757 0 740 3 0 3 3 0 8 1 mcl64k 65536 6 0 0 1 0 1 1 0 8 0 mcl16k 16384 2 0 0 1 0 1 1 0 8 0 mcl12k 12288 9 0 0 1 0 1 1 0 8 0 mcl9k 9216 5 0 0 1 0 1 1 0 8 0 mcl8k 8192 3 0 0 1 0 1 1 0 8 0 mcl4k 4096 6 0 0 1 0 1 1 0 8 0 mcl2k2 2112 2 0 0 1 0 1 1 0 8 0 mcl2k 2048 123 0 0 15 0 15 15 0 8 0 mtagpl 80 1 0 0 1 0 1 1 0 8 0 mbufpl 256 214 0 0 13 0 13 13 0 8 0 bufpl 256 23240 0 17029 390 0 390 390 0 8 0 anonpl 16 107650 0 100606 52 19 33 43 0 125 2 amapchunkpl 152 6953 0 6869 22 16 6 11 0 158 0 amappl16 192 3566 0 3208 44 24 20 31 0 8 1 amappl15 184 103 0 98 2 1 1 1 0 8 0 amappl14 176 284 0 280 2 1 1 1 0 8 0 amappl13 168 47 0 47 4 4 0 1 0 8 0 amappl12 160 95 0 90 1 0 1 1 0 8 0 amappl11 152 175 0 161 1 0 1 1 0 8 0 amappl10 144 173 0 172 2 1 1 1 0 8 0 amappl9 136 806 0 803 1 0 1 1 0 8 0 amappl8 128 344 0 327 1 0 1 1 0 8 0 amappl7 120 176 0 168 1 0 1 1 0 8 0 amappl6 112 133 0 126 1 0 1 1 0 8 0 amappl5 104 274 0 264 1 0 1 1 0 8 0 amappl4 96 1001 0 969 2 1 1 2 0 8 0 amappl3 88 388 0 382 1 0 1 1 0 8 0 amappl2 80 5087 0 5032 2 0 2 2 0 8 0 amappl1 72 30967 0 30536 23 13 10 19 0 8 0 amappl 72 2423 0 2391 1 0 1 1 0 75 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 19 0 0 1 0 1 1 0 8 0 uaddrrnd 24 868 0 854 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 868 0 854 1 0 1 1 0 8 0 vmmpekpl 168 10883 0 10858 2 0 2 2 0 8 0 vmmpepl 168 102433 0 101114 105 32 73 80 0 357 9 vmsppl 360 867 0 854 2 0 2 2 0 8 0 pdppl 4096 1744 0 1708 6 0 6 6 0 8 0 pvpl 32 311671 0 301582 127 30 97 115 0 265 10 pmappl 232 867 0 854 4 3 1 2 0 8 0 extentpl 40 39 0 25 1 0 1 1 0 8 0 phpool 112 547 0 4 16 0 16 16 0 8 0