panic: kernel diagnostic assertion "pg->wire_count == 1" failed: file "/syzkaller/managers/main/kernel/sys/kern/vfs_biomem.c", line 310 Stopped at db_enter+0x25: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND *378361 32491 0 0x2 0x1 0 syz-executor db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:437 panic(ffffffff830b2cf8) at panic+0x1cf sys/kern/subr_prf.c:198 __assert(ffffffff83067aec,ffffffff83077779,136,ffffffff82ff1e56) at __assert+0x29 buf_free_pages(fffffd8064660260) at buf_free_pages+0x23d sys/kern/vfs_biomem.c:299 buf_dealloc_mem(fffffd8064660260) at buf_dealloc_mem+0x14e sys/kern/vfs_biomem.c:179 buf_put(fffffd8064660260) at buf_put+0x1dc sys/kern/vfs_bio.c:127 brelse(fffffd8064660260) at brelse+0x395 sys/kern/vfs_bio.c:944 vinvalbuf(fffffd8067d58b48,2,ffffffffffffffff,ffff80002f3e4f58,0,ffffffffffffffff) at vinvalbuf+0x52c sys/kern/vfs_subr.c:2022 ffs_truncate(fffffd8062a39970,0,0,ffffffffffffffff) at ffs_truncate+0xf63 ufs_inactive(ffff80002a519478) at ufs_inactive+0x203 sys/ufs/ufs/ufs_inode.c:84 VOP_INACTIVE(fffffd8067d58b48,ffff80002f3e4f58) at VOP_INACTIVE+0xfe sys/kern/vfs_vops.c:495 vrele(fffffd8067d58b48) at vrele+0x120 sys/kern/vfs_subr.c:824 ktrwriteraw(ffff80002f3e4f58,fffffd8067d58b48,fffffd807f7d7548,ffff80002a5196b0,ffff80002a519690) at ktrwriteraw+0x352 ktrcleartrace sys/kern/kern_ktrace.c:86 [inline] ktrwriteraw(ffff80002f3e4f58,fffffd8067d58b48,fffffd807f7d7548,ffff80002a5196b0,ffff80002a519690) at ktrwriteraw+0x352 sys/kern/kern_ktrace.c:701 ktrpsig(ffff80002f3e4f58,9,0,0,0,ffff80002a519780) at ktrpsig+0x1b2 sys/kern/kern_ktrace.c:292 end trace frame: 0xffff80002a519870, count: 0 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 "pg->wire_count == 1" failed: file "/syzkaller/managers/main/kernel/sys/kern/vfs_biomem.c", line 310 ddb> trace db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:437 panic(ffffffff830b2cf8) at panic+0x1cf sys/kern/subr_prf.c:198 __assert(ffffffff83067aec,ffffffff83077779,136,ffffffff82ff1e56) at __assert+0x29 buf_free_pages(fffffd8064660260) at buf_free_pages+0x23d sys/kern/vfs_biomem.c:299 buf_dealloc_mem(fffffd8064660260) at buf_dealloc_mem+0x14e sys/kern/vfs_biomem.c:179 buf_put(fffffd8064660260) at buf_put+0x1dc sys/kern/vfs_bio.c:127 brelse(fffffd8064660260) at brelse+0x395 sys/kern/vfs_bio.c:944 vinvalbuf(fffffd8067d58b48,2,ffffffffffffffff,ffff80002f3e4f58,0,ffffffffffffffff) at vinvalbuf+0x52c sys/kern/vfs_subr.c:2022 ffs_truncate(fffffd8062a39970,0,0,ffffffffffffffff) at ffs_truncate+0xf63 ufs_inactive(ffff80002a519478) at ufs_inactive+0x203 sys/ufs/ufs/ufs_inode.c:84 VOP_INACTIVE(fffffd8067d58b48,ffff80002f3e4f58) at VOP_INACTIVE+0xfe sys/kern/vfs_vops.c:495 vrele(fffffd8067d58b48) at vrele+0x120 sys/kern/vfs_subr.c:824 ktrwriteraw(ffff80002f3e4f58,fffffd8067d58b48,fffffd807f7d7548,ffff80002a5196b0,ffff80002a519690) at ktrwriteraw+0x352 ktrcleartrace sys/kern/kern_ktrace.c:86 [inline] ktrwriteraw(ffff80002f3e4f58,fffffd8067d58b48,fffffd807f7d7548,ffff80002a5196b0,ffff80002a519690) at ktrwriteraw+0x352 sys/kern/kern_ktrace.c:701 ktrpsig(ffff80002f3e4f58,9,0,0,0,ffff80002a519780) at ktrpsig+0x1b2 sys/kern/kern_ktrace.c:292 postsig(ffff80002f3e4f58,9,ffff80002a519888) at postsig+0x3b2 sys/kern/kern_sig.c:1567 userret(ffff80002f3e4f58) at userret+0x1fe sys/kern/kern_sig.c:2018 syscall(ffff80002a5199c0) at syscall+0xa72 mi_syscall_return sys/sys/syscall_mi.h:206 [inline] syscall(ffff80002a5199c0) at syscall+0xa72 sys/arch/amd64/amd64/trap.c:598 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x75236b433d20, count: -18 ddb> show registers rdi 0 rsi 0x1 rbp 0xffff80002a518f80 rbx 0 rdx 0 rcx 0 rax 0xffff80002f3e4f58 r8 0x101010101010101 r9 0x8080808080808080 r10 0x7aa3ef0dcf85620d r11 0x8ff857e6f7552b44 r12 0 r13 0xfffffd80063d3e80 r14 0 r15 0x1 rip 0xffffffff8143fa95 db_enter+0x25 cs 0x8 rflags 0x246 rsp 0xffff80002a518f70 ss 0 db_enter+0x25: addq $0x8,%rsp ddb> show proc PROC (syz-executor) tid=378361 pid=32491 tcnt=1 stat=onproc flags process=2 proc=1 runpri=17, usrpri=55, slppri=17, nice=20 wchan=0x0, wmesg=, ps_single=0x0 scnt=0 ecnt=0 forw=0xffffffffffffffff, list=0xffff80002f3e47c0,0xffff80002a4571d0 process=0xffff8000ffff59c8 user=0xffff80002a514000, vmspace=0xfffffd806c12bad0 estcpu=5, cpticks=2, pctcpu=0.0, user=0, sys=3, intr=0 ddb> ps PID TID PPID UID S FLAGS WAIT COMMAND 23903 245152 71825 0 2 0x2 syz-executor 81540 220952 2569 0 3 0x10008a sigsusp sh 2569 380975 71825 0 3 0x82 wait syz-executor 13983 176815 71825 0 3 0x82 piperd syz-executor 42384 298917 71825 0 3 0x82 piperd syz-executor 84307 140333 71825 0 3 0x82 piperd syz-executor 78783 340654 71825 0 3 0x82 piperd syz-executor 23651 455098 71825 0 3 0x82 piperd syz-executor 47945 496260 0 0 3 0x14200 acct acct *32491 378361 71825 0 7 0x3 syz-executor 49959 464781 1 0 3 0x100083 ttyopn getty 20822 398258 0 0 3 0x14200 bored sosplice 71825 387392 51348 0 3 0x82 wait syz-executor 51348 4791 46615 0 3 0x10008a sigsusp ksh 46615 468658 58512 0 3 0x98 kqread sshd-session 58512 28093 60146 0 3 0x92 kqread sshd-session 60146 314913 1 0 3 0x88 kqread sshd 45041 366254 39413 73 2 0x1100011 syslogd 39413 485686 1 0 3 0x100082 sbwait syslogd 77095 63311 1 0 3 0x100080 kqread resolvd 73731 424975 26552 77 3 0x100092 kqread dhcpleased 53015 50817 26552 77 3 0x100092 kqread dhcpleased 26552 324453 1 0 3 0x80 kqread dhcpleased 38392 230354 0 0 3 0x14200 bored smr 62774 276811 0 0 2 0x14200 zerothread 3603 164853 0 0 3 0x14200 aiodoned aiodoned 17613 18038 0 0 3 0x14200 syncer update 77707 253224 0 0 3 0x14200 cleaner cleaner 48194 7994 0 0 3 0x14200 reaper reaper 68369 369118 0 0 3 0x14200 pgdaemon pagedaemon 29182 128015 0 0 3 0x14200 bored viomb 48637 329691 0 0 3 0x40014200 acpi0 acpi0 47874 290555 0 0 3 0x14200 bored softnet3 56203 6239 0 0 3 0x14200 bored softnet2 61739 223399 0 0 3 0x14200 bored softnet1 58318 270884 0 0 3 0x14200 bored softnet0 34420 50439 0 0 3 0x14200 bored systqmp 95650 277132 0 0 3 0x14200 bored systq 13271 342697 0 0 3 0x40014200 tmoslp softclock 28450 391200 0 0 3 0x40014200 idle0 1 332260 0 0 3 0x82 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 10203 11069K 11335K 166960K 13224 0 pcb 17 14K 16K 166960K 391 0 rtable 182 8K 10K 166960K 4126 0 pf 31 13K 17K 166960K 313 0 ifaddr 34 7K 8K 166960K 541 0 ifgroup 46 2K 2K 166960K 520 0 sysctl 4 1K 2K 166960K 11 0 counters 29 17K 18K 166960K 151 0 ioctlops 0 0K 4K 166960K 443 0 iov 0 0K 16K 166960K 91 0 mount 1 1K 1K 166960K 1 0 log 0 0K 0K 166960K 4 0 vnodes 1516 95K 95K 166960K 3951 0 UFS quota 1 32K 32K 166960K 1 0 UFS mount 5 36K 36K 166960K 5 0 shm 2 1K 9K 166960K 29 0 VM map 2 1K 1K 166960K 2 0 sem 22 0K 0K 166960K 164 0 dirhash 18 3K 3K 166960K 51 0 ACPI 1690 195K 286K 166960K 12468 0 file desc 12 38K 97K 166960K 3109 0 sigio 0 0K 0K 166960K 47 0 proc 67 67K 124K 166960K 3400 0 subproc 91 5K 7K 166960K 1404 0 NFS srvsock 1 0K 0K 166960K 1 0 NFS daemon 1 16K 16K 166960K 1 0 ip_moptions 0 0K 0K 166960K 394 0 in_multi 74 5K 7K 166960K 1638 0 ether_multi 1 0K 0K 166960K 11 0 mrt 1 0K 0K 166960K 5 0 ISOFS mount 1 32K 32K 166960K 1 0 MSDOSFS mount 1 16K 16K 166960K 1 0 ttys 241 1076K 1076K 166960K 241 0 exec 0 0K 1K 166960K 2304 0 pfkey data 0 0K 0K 166960K 66 0 tdb 3 0K 0K 166960K 3 0 VM swap 8 62K 64K 166960K 10 0 UVM amap 161 62K 109K 166960K 24513 0 UVM aobj 43 2K 4K 166960K 51 0 pinsyscall 33 66K 96K 166960K 6720 0 memdesc 1 4K 4K 166960K 1 0 crypto data 1 1K 1K 166960K 1 0 ip6_options 0 0K 0K 166960K 99 0 NDP 18 1K 2K 166960K 415 0 temp 73 6815K 6890K 166960K 90607 0 kqueue 13 20K 28K 166960K 286 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 477 0 474 3 0 3 3 0 8 2 rtentry 112 1513 0 1435 4 0 4 4 0 8 1 unpcb 144 1672 0 1657 8 6 2 7 0 8 1 syncache 336 9 0 9 2 1 1 1 0 8 1 tcpqe 32 5 0 5 2 1 1 1 0 8 1 tcpcb 808 709 0 705 15 13 2 14 0 8 1 arp 88 226 0 211 1 0 1 1 0 8 0 ipq 40 12 0 10 1 0 1 1 0 8 0 ipqe 40 112 0 110 1 0 1 1 0 8 0 inpcb 336 2863 0 2855 21 14 7 15 0 8 6 nd6 104 401 0 383 1 0 1 1 0 8 0 pkpcb 40 72 0 72 2 1 1 1 0 8 1 kcovpl 48 108 0 101 1 0 1 1 0 8 0 ppxss 1072 14 0 14 2 1 1 1 0 8 1 pfstscr 40 5 0 4 1 0 1 1 0 8 0 pftag 88 2 0 0 1 0 1 1 0 8 0 pfstitem 24 4 0 0 1 0 1 1 0 8 0 pfstkey 128 16 0 12 1 0 1 1 0 8 0 pfstate 344 10 0 7 1 0 1 1 0 8 0 pfrule 1344 7 0 6 1 0 1 1 0 8 0 art_heap8 4096 4 0 0 4 0 4 4 0 8 0 art_heap4 256 6538 0 6205 30 3 27 30 0 8 4 art_table 32 6542 0 6205 4 0 4 4 0 8 0 art_node 16 1508 0 1438 1 0 1 1 0 8 0 sysvmsgpl 40 81 0 76 1 0 1 1 0 8 0 semupl 112 1 0 1 1 1 0 1 0 8 0 semapl 112 160 0 140 1 0 1 1 0 8 0 shmpl 112 48 0 8 2 0 2 2 0 8 0 dirhash 1024 44 0 23 3 0 3 3 0 8 0 dino2pl 256 4514 0 2827 106 0 106 106 0 8 0 ffsino 240 4514 0 2827 100 0 100 100 0 8 0 nchpl 144 6985 0 6318 66 39 27 66 0 8 0 uvmvnodes 80 6715 0 0 138 0 138 138 0 8 0 vnodes 216 6715 0 0 374 0 374 374 0 8 0 namei 1024 33535 0 33535 2 1 1 2 0 8 1 kstatmem 264 264 0 244 3 0 3 3 0 8 0 scsiplug 72 6 0 6 2 1 1 1 0 8 1 scxspl 216 60952 0 60952 15 7 8 8 1 8 8 plimitpl 152 567 0 552 1 0 1 1 0 8 0 sigapl 424 3396 0 3354 28 22 6 28 0 8 0 futexpl 64 23888 0 23888 1 0 1 1 0 8 1 knotepl 120 63453 0 63418 12 2 10 10 0 8 8 kqueuepl 184 692 0 683 7 3 4 4 0 8 3 pipepl 288 754 0 727 7 4 3 7 0 8 0 fdescpl 432 3174 0 3150 5 1 4 5 0 8 0 filepl 120 17151 0 16931 20 7 13 16 0 8 4 lockfpl 104 691 0 689 2 1 1 2 0 8 0 lockfspl 48 212 0 210 1 0 1 1 0 8 0 sessionpl 144 125 0 117 1 0 1 1 0 8 0 pgrppl 48 263 0 247 1 0 1 1 0 8 0 ucredpl 104 2136 0 2124 1 0 1 1 0 8 0 zombiepl 144 3764 0 3763 1 0 1 1 0 8 0 processpl 1096 3396 0 3354 18 13 5 18 0 8 1 procpl 648 5906 0 5864 23 17 6 23 0 8 0 sosppl 168 18 0 18 2 1 1 1 0 8 1 sockpl 504 5113 0 5087 44 32 12 30 0 8 8 mcl64k 65536 39 0 39 2 1 1 1 0 8 1 mcl16k 16384 5 0 5 2 1 1 1 0 8 1 mcl9k 9216 1 0 1 1 0 1 1 0 8 1 mcl8k 8192 22 0 22 2 1 1 1 0 8 1 mcl4k 4096 5102 0 5054 14 7 7 14 0 8 0 mcl2k 2048 3988 0 3986 6 2 4 4 0 8 3 mtagpl 96 143 0 143 3 2 1 3 0 8 1 mbufpl 256 33005 0 32881 121 100 21 77 0 8 8 bufpl 280 14229 0 6780 533 0 533 533 0 8 0 anonpl 24 445925 0 442934 126 49 77 79 0 187 40 amapchunkpl 152 78956 0 78666 54 22 32 43 0 158 11 amappl16 200 6367 0 6364 40 29 11 15 0 8 9 amappl15 192 40 0 40 1 1 0 1 0 8 0 amappl14 184 308 0 298 1 0 1 1 0 8 0 amappl13 176 40 0 40 1 1 0 1 0 8 0 amappl12 168 5386 0 5363 3 1 2 3 0 8 0 amappl11 160 51 0 41 1 0 1 1 0 8 0 amappl10 152 7 0 7 1 1 0 1 0 8 0 amappl9 144 117 0 117 1 1 0 1 0 8 0 amappl8 136 57 0 55 1 0 1 1 0 8 0 amappl7 128 310 0 300 1 0 1 1 0 8 0 amappl6 120 1155 0 1151 1 0 1 1 0 8 0 amappl5 112 527 0 517 1 0 1 1 0 8 0 amappl4 104 582 0 566 1 0 1 1 0 8 0 amappl3 96 15299 0 15236 5 1 4 4 0 8 1 amappl2 88 2076 0 2011 2 0 2 2 0 8 0 amappl1 80 22703 0 22204 14 1 13 13 0 8 0 amappl 88 23301 0 23193 5 0 5 5 0 92 0 dma65536 65536 1 0 1 1 1 0 1 0 8 0 dma32768 32768 1 0 1 1 1 0 1 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 8 0 8 2 1 1 1 0 8 1 dma128 128 254 0 254 1 1 0 1 0 8 0 dma64 64 6 0 6 1 1 0 1 0 8 0 dma32 32 7 0 7 1 1 0 1 0 8 0 dma16 16 20 0 19 1 0 1 1 0 8 0 aobjpl 72 50 0 8 1 0 1 1 0 8 0 uaddrrnd 24 3174 0 3150 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 3174 0 3150 1 0 1 1 0 8 0 vmmpekpl 168 25816 0 25763 4 0 4 4 0 8 1 vmmpepl 168 196488 0 195138 101 11 90 90 0 357 13 vmsppl 344 3173 0 3150 4 1 3 4 0 8 0 rwobjpl 24 60550 0 53024 48 0 48 48 0 8 0 pdppl 4096 6354 0 6300 240 176 64 82 0 8 10 pvpl 32 1542775 0 1535252 536 281 255 360 0 265 161 pmappl 216 3173 0 3150 3 1 2 3 0 8 0 extentpl 40 55 0 38 1 0 1 1 0 8 0 phpool 112 727 0 360 12 0 12 12 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:437 panic(ffffffff830b2cf8) at panic+0x1cf sys/kern/subr_prf.c:198 __assert(ffffffff83067aec,ffffffff83077779,136,ffffffff82ff1e56) at __assert+0x29 buf_free_pages(fffffd8064660260) at buf_free_pages+0x23d sys/kern/vfs_biomem.c:299 buf_dealloc_mem(fffffd8064660260) at buf_dealloc_mem+0x14e sys/kern/vfs_biomem.c:179 buf_put(fffffd8064660260) at buf_put+0x1dc sys/kern/vfs_bio.c:127 brelse(fffffd8064660260) at brelse+0x395 sys/kern/vfs_bio.c:944 vinvalbuf(fffffd8067d58b48,2,ffffffffffffffff,ffff80002f3e4f58,0,ffffffffffffffff) at vinvalbuf+0x52c sys/kern/vfs_subr.c:2022 ffs_truncate(fffffd8062a39970,0,0,ffffffffffffffff) at ffs_truncate+0xf63 ufs_inactive(ffff80002a519478) at ufs_inactive+0x203 sys/ufs/ufs/ufs_inode.c:84 VOP_INACTIVE(fffffd8067d58b48,ffff80002f3e4f58) at VOP_INACTIVE+0xfe sys/kern/vfs_vops.c:495 vrele(fffffd8067d58b48) at vrele+0x120 sys/kern/vfs_subr.c:824 ktrwriteraw(ffff80002f3e4f58,fffffd8067d58b48,fffffd807f7d7548,ffff80002a5196b0,ffff80002a519690) at ktrwriteraw+0x352 ktrcleartrace sys/kern/kern_ktrace.c:86 [inline] ktrwriteraw(ffff80002f3e4f58,fffffd8067d58b48,fffffd807f7d7548,ffff80002a5196b0,ffff80002a519690) at ktrwriteraw+0x352 sys/kern/kern_ktrace.c:701 ktrpsig(ffff80002f3e4f58,9,0,0,0,ffff80002a519780) at ktrpsig+0x1b2 sys/kern/kern_ktrace.c:292 postsig(ffff80002f3e4f58,9,ffff80002a519888) at postsig+0x3b2 sys/kern/kern_sig.c:1567 userret(ffff80002f3e4f58) at userret+0x1fe sys/kern/kern_sig.c:2018 syscall(ffff80002a5199c0) at syscall+0xa72 mi_syscall_return sys/sys/syscall_mi.h:206 [inline] syscall(ffff80002a5199c0) at syscall+0xa72 sys/arch/amd64/amd64/trap.c:598 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x75236b433d20, count: -18 ddb> machine ddbcpu 1 No such command ddb> trace db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:437 panic(ffffffff830b2cf8) at panic+0x1cf sys/kern/subr_prf.c:198 __assert(ffffffff83067aec,ffffffff83077779,136,ffffffff82ff1e56) at __assert+0x29 buf_free_pages(fffffd8064660260) at buf_free_pages+0x23d sys/kern/vfs_biomem.c:299 buf_dealloc_mem(fffffd8064660260) at buf_dealloc_mem+0x14e sys/kern/vfs_biomem.c:179 buf_put(fffffd8064660260) at buf_put+0x1dc sys/kern/vfs_bio.c:127 brelse(fffffd8064660260) at brelse+0x395 sys/kern/vfs_bio.c:944 vinvalbuf(fffffd8067d58b48,2,ffffffffffffffff,ffff80002f3e4f58,0,ffffffffffffffff) at vinvalbuf+0x52c sys/kern/vfs_subr.c:2022 ffs_truncate(fffffd8062a39970,0,0,ffffffffffffffff) at ffs_truncate+0xf63 ufs_inactive(ffff80002a519478) at ufs_inactive+0x203 sys/ufs/ufs/ufs_inode.c:84 VOP_INACTIVE(fffffd8067d58b48,ffff80002f3e4f58) at VOP_INACTIVE+0xfe sys/kern/vfs_vops.c:495 vrele(fffffd8067d58b48) at vrele+0x120 sys/kern/vfs_subr.c:824 ktrwriteraw(ffff80002f3e4f58,fffffd8067d58b48,fffffd807f7d7548,ffff80002a5196b0,ffff80002a519690) at ktrwriteraw+0x352 ktrcleartrace sys/kern/kern_ktrace.c:86 [inline] ktrwriteraw(ffff80002f3e4f58,fffffd8067d58b48,fffffd807f7d7548,ffff80002a5196b0,ffff80002a519690) at ktrwriteraw+0x352 sys/kern/kern_ktrace.c:701 ktrpsig(ffff80002f3e4f58,9,0,0,0,ffff80002a519780) at ktrpsig+0x1b2 sys/kern/kern_ktrace.c:292 postsig(ffff80002f3e4f58,9,ffff80002a519888) at postsig+0x3b2 sys/kern/kern_sig.c:1567 userret(ffff80002f3e4f58) at userret+0x1fe sys/kern/kern_sig.c:2018 syscall(ffff80002a5199c0) at syscall+0xa72 mi_syscall_return sys/sys/syscall_mi.h:206 [inline] syscall(ffff80002a5199c0) at syscall+0xa72 sys/arch/amd64/amd64/trap.c:598 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x75236b433d20, count: -18