panic: kernel diagnostic assertion "pg->wire_count == 0" failed: file "/syzkaller/managers/main/kernel/sys/uvm/uvm_page.c", line 1326 Stopped at db_enter+0x25: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND *455669 48081 0 0 0x4000000 0 syz-executor db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:438 panic(ffffffff8337b37c) at panic+0x1cf sys/kern/subr_prf.c:198 __assert(ffffffff833ba7b3,ffffffff833a3e01,52e,ffffffff833d457a) at __assert+0x29 sys/kern/subr_prf.c:-1 uvm_pagedequeue(fffffd800706b580) at uvm_pagedequeue+0x2cd sys/uvm/uvm_page.c:1324 uvm_pageclean(fffffd800706b580) at uvm_pageclean+0x2ac sys/uvm/uvm_page.c:981 uvm_pagefree(fffffd800706b580) at uvm_pagefree+0x26 sys/uvm/uvm_page.c:1020 uvm_anfree(fffffd806ad1aab0) at uvm_anfree+0xe9 sys/uvm/uvm_anon.c:112 amap_wipeout(fffffd806fc7b640) at amap_wipeout+0x246 sys/uvm/uvm_amap.c:-1 uvm_unmap_detach(ffff80003c951bb0,0) at uvm_unmap_detach+0x8a sys/uvm/uvm_map.c:1353 uvm_mapanon(fffffd806cb03460,ffff80003c951dd8,400000,0,3090713) at uvm_mapanon+0x854 sys/uvm/uvm_map.c:910 uvm_mmapanon(fffffd806cb03460,ffff80003c951dd8,400000,3,7,5012,5125c0e282b9b220,fffffd806cb03460) at uvm_mmapanon+0x1d0 sys/uvm/uvm_mmap.c:1029 sys_mmap(ffff80003c929780,ffff80003c951f30,ffff80003c951e80) at sys_mmap+0xa60 sys/uvm/uvm_mmap.c:426 syscall(ffff80003c951f30) at syscall+0x962 mi_syscall sys/sys/syscall_mi.h:-1 [inline] syscall(ffff80003c951f30) at syscall+0x962 sys/arch/amd64/amd64/trap.c:775 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0xc0e0f478640, count: 1 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 == 0" failed: file "/syzkaller/managers/main/kernel/sys/uvm/uvm_page.c", line 1326 ddb> trace db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:438 panic(ffffffff8337b37c) at panic+0x1cf sys/kern/subr_prf.c:198 __assert(ffffffff833ba7b3,ffffffff833a3e01,52e,ffffffff833d457a) at __assert+0x29 sys/kern/subr_prf.c:-1 uvm_pagedequeue(fffffd800706b580) at uvm_pagedequeue+0x2cd sys/uvm/uvm_page.c:1324 uvm_pageclean(fffffd800706b580) at uvm_pageclean+0x2ac sys/uvm/uvm_page.c:981 uvm_pagefree(fffffd800706b580) at uvm_pagefree+0x26 sys/uvm/uvm_page.c:1020 uvm_anfree(fffffd806ad1aab0) at uvm_anfree+0xe9 sys/uvm/uvm_anon.c:112 amap_wipeout(fffffd806fc7b640) at amap_wipeout+0x246 sys/uvm/uvm_amap.c:-1 uvm_unmap_detach(ffff80003c951bb0,0) at uvm_unmap_detach+0x8a sys/uvm/uvm_map.c:1353 uvm_mapanon(fffffd806cb03460,ffff80003c951dd8,400000,0,3090713) at uvm_mapanon+0x854 sys/uvm/uvm_map.c:910 uvm_mmapanon(fffffd806cb03460,ffff80003c951dd8,400000,3,7,5012,5125c0e282b9b220,fffffd806cb03460) at uvm_mmapanon+0x1d0 sys/uvm/uvm_mmap.c:1029 sys_mmap(ffff80003c929780,ffff80003c951f30,ffff80003c951e80) at sys_mmap+0xa60 sys/uvm/uvm_mmap.c:426 syscall(ffff80003c951f30) at syscall+0x962 mi_syscall sys/sys/syscall_mi.h:-1 [inline] syscall(ffff80003c951f30) at syscall+0x962 sys/arch/amd64/amd64/trap.c:775 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0xc0e0f478640, count: -14 ddb> show registers rdi 0 rsi 0x1 rbp 0xffff80003c951930 rbx 0x1 rdx 0xffff8000014346c0 rcx 0 rax 0xffff80003c929780 r8 0x101010101010101 r9 0x8080808080808080 r10 0x93d877bb04112016 r11 0x1895718708e39e7e r12 0 r13 0xfffffd806ad1aab0 r14 0 r15 0x1 rip 0xffffffff820dbab5 db_enter+0x25 cs 0x8 rflags 0x246 rsp 0xffff80003c951920 ss 0x10 db_enter+0x25: addq $0x8,%rsp ddb> show proc PROC (syz-executor) tid=455669 pid=48081 tcnt=2 stat=onproc flags process=0 proc=4000000 runpri=32, usrpri=82, slppri=32, nice=20 wchan=0x0, wmesg=, ps_single=0x0 scnt=0 ecnt=0 forw=0xffffffffffffffff, list=0xffff80003c929a18,0xffff80002f0fd258 process=0xffff80002f0f8498 user=0xffff80003c94c000, vmspace=0xfffffd806cb03460 estcpu=32, cpticks=1, pctcpu=0.0, user=0, sys=1, intr=0 ddb> ps PID TID PPID UID S FLAGS WAIT COMMAND 20613 122536 10449 0 2 0 syz-executor 20613 57281 10449 0 3 0x4000000 biowait syz-executor 48081 195412 88685 0 2 0 syz-executor *48081 455669 88685 0 7 0x4000000 syz-executor 52632 93226 3940 0 2 0 syz-executor 52632 118813 3940 0 3 0x4000080 ttyretype syz-executor 52632 227881 3940 0 3 0x4000080 fsleep syz-executor 72489 183946 1 0 3 0x82 nanoslp getty 88685 380127 73744 0 3 0x82 nanoslp syz-executor 10449 233091 73744 0 3 0x82 nanoslp syz-executor 86424 79666 0 0 3 0x14280 nfsidl nfsio 60764 129968 73744 0 2 0x2 syz-executor 4988 201949 73744 0 2 0x2 syz-executor 30237 33042 73744 0 3 0x82 nanoslp syz-executor 64818 174870 73744 0 3 0x82 nanoslp syz-executor 65471 8323 73744 0 3 0x2 biowait syz-executor 3940 260493 73744 0 3 0x82 nanoslp syz-executor 73744 122240 4298 0 3 0x82 kqread syz-executor 4298 130198 30913 0 3 0x10008a sigsusp ksh 30913 59785 53736 0 3 0x98 kqread sshd-session 53736 15472 26019 0 3 0x92 kqread sshd-session 26019 393733 1 0 3 0x88 kqread sshd 30454 227029 3983 73 3 0x1100090 kqread syslogd 3983 472726 1 0 3 0x100082 sbwait syslogd 49648 94318 1 0 3 0x100080 kqread resolvd 92257 166756 53548 77 3 0x100092 kqread dhcpleased 85367 127192 53548 77 3 0x100092 kqread dhcpleased 53548 6425 1 0 3 0x80 kqread dhcpleased 54810 500951 0 0 3 0x14200 bored smr 75259 516207 0 0 2 0x14200 zerothread 24319 381529 0 0 3 0x14200 aiodoned aiodoned 76303 48584 0 0 3 0x14200 syncer update 57131 266657 0 0 3 0x14200 cleaner cleaner 58381 329548 0 0 3 0x14200 reaper reaper 88126 125985 0 0 3 0x14200 pgdaemon pagedaemon 2364 239292 0 0 3 0x14200 bored viomb 9425 471242 0 0 3 0x40014200 acpi0 acpi0 90668 68092 0 0 3 0x14200 bored softnet0 80163 271894 0 0 3 0x14200 smrbar systqmp 32334 385176 0 0 3 0x14200 bored systq 82399 434948 0 0 3 0x40014200 tmoslp softclock 80719 285645 0 0 3 0x40014200 idle0 1 13232 0 0 3 0x80082 wait init 0 0 -1 0 3 0x10010200 scheduler swapper ddb> show all locks No such command ddb> show malloc Type InUse MemUse HighUse Limit Requests Type Lim devbuf 10181 11128K 15488K 166960K 13593 0 pcb 18 18K 20K 166960K 399 0 rtable 232 9K 9K 166960K 558 0 pf 34 13K 20K 166960K 118 0 ifaddr 44 8K 8K 166960K 90 0 ifgroup 52 2K 2K 166960K 136 0 sysctl 4 1K 9K 166960K 10 0 counters 34 17K 18K 166960K 77 0 ioctlops 0 0K 4K 166960K 223 0 iov 0 0K 20K 166960K 130 0 mount 1 1K 1K 166960K 1 0 log 0 0K 0K 166960K 4 0 vnodes 1428 90K 90K 166960K 2586 0 UFS quota 1 32K 32K 166960K 1 0 UFS mount 5 36K 36K 166960K 5 0 shm 3 5K 9K 166960K 24 0 VM map 2 1K 1K 166960K 2 0 sem 12 0K 1K 166960K 75 0 dirhash 12 2K 2K 166960K 21 0 ACPI 1692 195K 286K 166960K 12470 0 file desc 15 53K 236K 166960K 1186 0 sigio 0 0K 0K 166960K 18 0 proc 60 59K 83K 166960K 660 0 subproc 72 4K 4K 166960K 90 0 NFS srvsock 1 0K 0K 166960K 1 0 NFS daemon 1 16K 16K 166960K 1 0 ip_moptions 0 0K 0K 166960K 169 0 in_multi 103 7K 7K 166960K 171 0 ether_multi 1 0K 0K 166960K 16 0 mrt 0 0K 0K 166960K 10 0 ISOFS mount 1 32K 32K 166960K 1 0 MSDOSFS mount 1 16K 16K 166960K 1 0 ttys 91 413K 413K 166960K 91 0 exec 0 0K 1K 166960K 486 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 219 170K 176K 166960K 11869 0 UVM aobj 44 14K 16K 166960K 52 0 pinsyscall 36 72K 94K 166960K 2311 0 memdesc 1 4K 4K 166960K 1 0 crypto data 1 1K 1K 166960K 1 0 ip6_options 0 0K 0K 166960K 51 0 NDP 12 0K 2K 166960K 58 0 temp 77 8672K 8743K 166960K 44525 0 kqueue 13 20K 34K 166960K 205 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 116 0 113 1 0 1 1 0 8 0 rtentry 136 170 0 71 4 0 4 4 0 8 0 unpcb 144 1202 0 1183 15 6 9 10 0 8 8 syncache 336 9 0 9 4 3 1 1 0 8 1 tcpqe 32 4 0 4 2 1 1 1 0 8 1 tcpcb 736 370 0 361 5 3 2 4 0 8 1 arp 96 29 0 12 1 0 1 1 0 8 0 ipq 40 6 0 1 1 0 1 1 0 8 0 ipqe 40 10 0 4 1 0 1 1 0 8 0 inpcb 328 1582 0 1569 27 20 7 15 0 8 4 ip6q 72 21 0 18 1 0 1 1 0 8 0 ip6af 40 38 0 36 1 0 1 1 0 8 0 nd6 112 35 0 11 1 0 1 1 0 8 0 pkpcb 40 12 0 12 3 2 1 1 0 8 1 kcovpl 48 10 0 2 1 0 1 1 0 8 0 ppxss 1072 32 0 31 3 2 1 1 0 8 0 pppxif 1384 5 0 5 2 2 0 1 0 8 0 pfrktable 1344 3 0 3 1 1 0 1 0 8 0 pfanchor 1288 2 0 0 1 0 1 1 0 8 0 pftag 88 1 0 0 1 0 1 1 0 8 0 pfstitem 24 2 0 0 1 0 1 1 0 8 0 pfstkey 128 4 0 2 1 0 1 1 0 8 0 pfstate 384 2 0 1 1 0 1 1 0 8 0 pfrule 1344 1 0 1 1 1 0 1 0 8 0 rttmr 136 1 0 1 1 1 0 1 0 8 0 art_heap8 4096 2 0 0 2 0 2 2 0 8 0 art_heap4 256 639 0 193 32 4 28 30 0 8 0 art_table 40 641 0 193 5 0 5 5 0 8 0 art_node 32 168 0 79 1 0 1 1 0 8 0 sysvmsgpl 40 3 0 2 2 1 1 1 0 8 0 semupl 112 2 0 2 1 1 0 1 0 8 0 semapl 112 72 0 62 1 0 1 1 0 8 0 shmpl 112 42 0 7 1 0 1 1 0 8 0 dirhash 1024 23 0 6 3 0 3 3 0 8 0 dino2pl 256 3736 0 2232 95 0 95 95 0 8 0 ffsino 256 3736 0 2232 95 0 95 95 0 8 0 nchpl 144 5474 0 3771 64 0 64 64 0 8 0 rtmask 32 9 0 9 2 2 0 1 0 8 0 vnodes 216 4416 0 0 246 0 246 246 0 8 0 namei 1024 18408 0 18407 2 1 1 1 0 8 0 vcpupl 3904 6 0 0 1 0 1 1 0 8 0 vmpool 808 7 0 1 1 0 1 1 0 8 0 kstatmem 264 76 0 52 2 0 2 2 0 8 0 scsiplug 72 7 0 7 3 2 1 1 0 8 1 scxspl 216 15826 0 15823 11 8 3 8 1 8 2 plimitpl 152 420 0 403 1 0 1 1 0 8 0 sigapl 424 1463 0 1422 7 1 6 6 0 8 0 knotepl 120 41204 0 41157 46 35 11 22 0 8 8 kqueuepl 184 411 0 401 3 2 1 3 0 8 0 pipepl 304 268 0 241 8 5 3 8 0 8 0 fdescpl 448 1446 0 1419 5 1 4 5 0 8 0 filepl 120 10614 0 10393 18 3 15 15 0 8 5 lockfpl 104 472 0 468 2 0 2 2 0 8 1 lockfspl 48 172 0 169 1 0 1 1 0 8 0 sessionpl 144 26 0 19 1 0 1 1 0 8 0 pgrppl 48 56 0 41 1 0 1 1 0 8 0 ucredpl 104 2088 0 2077 1 0 1 1 0 8 0 zombiepl 144 1424 0 1422 2 1 1 1 0 8 0 processpl 1152 1463 0 1422 4 0 4 4 0 8 0 procpl 664 2939 0 2894 6 0 6 6 0 8 1 sosppl 176 9 0 9 3 2 1 1 0 8 1 sockpl 552 2948 0 2913 31 19 12 20 0 8 8 mcl64k 65536 195 0 194 2 1 1 1 0 8 0 mcl16k 16384 3 0 3 2 2 0 1 0 8 0 mcl9k 9216 1 0 1 1 1 0 1 0 8 0 mcl8k 8192 17 0 17 4 3 1 1 0 8 1 mcl4k 4096 3819 0 3762 16 7 9 14 0 8 1 mcl2k2 2112 3 0 3 2 2 0 1 0 8 0 mcl2k 2048 1942 0 1934 4 2 2 3 0 8 0 mtagpl 96 180 0 12 5 0 5 5 0 8 0 mbufpl 256 16036 0 15687 27 3 24 24 0 8 0 bufpl 280 5701 0 124 399 0 399 399 0 8 0 anonpl 24 230775 0 225461 96 51 45 57 0 187 12 amapchunkpl 152 47509 0 46831 58 26 32 38 0 158 3 amappl16 200 4002 0 3955 43 30 13 16 0 8 8 amappl15 192 3 0 3 1 1 0 1 0 8 0 amappl14 184 4 0 4 1 1 0 1 0 8 0 amappl13 176 430 0 429 1 0 1 1 0 8 0 amappl12 168 1829 0 1793 2 0 2 2 0 8 0 amappl11 160 6 0 6 1 1 0 1 0 8 0 amappl10 152 44 0 34 1 0 1 1 0 8 0 amappl9 144 251 0 250 2 1 1 1 0 8 0 amappl8 136 46 0 45 1 0 1 1 0 8 0 amappl7 128 92 0 91 1 0 1 1 0 8 0 amappl6 120 297 0 285 1 0 1 1 0 8 0 amappl5 112 71 0 63 1 0 1 1 0 8 0 amappl4 104 430 0 405 1 0 1 1 0 8 0 amappl3 96 8053 0 7958 3 0 3 3 0 8 0 amappl2 88 563 0 508 2 0 2 2 0 8 0 amappl1 80 13763 0 13230 14 1 13 13 0 8 0 amappl 88 10924 0 10778 4 0 4 4 0 92 0 uvmvnodes 80 137 0 0 3 0 3 3 0 8 0 dma16384 16384 1 0 1 1 1 0 1 0 8 0 dma8192 8192 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 7 0 7 2 2 0 1 0 8 0 dma128 128 255 0 255 3 2 1 1 0 8 1 dma64 64 9 0 9 3 3 0 1 0 8 0 dma32 32 7 0 7 1 1 0 1 0 8 0 dma16 16 18 0 17 1 0 1 1 0 8 0 aobjpl 72 51 0 8 1 0 1 1 0 8 0 uaddrrnd 24 1446 0 1419 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 1446 0 1419 1 0 1 1 0 8 0 vmmpekpl 168 12439 0 12399 3 0 3 3 0 8 0 vmmpepl 168 96091 0 94380 115 23 92 92 0 357 10 vmsppl 368 1445 0 1419 4 1 3 4 0 8 0 rwobjpl 40 26149 0 25123 13 0 13 13 0 8 0 pdppl 4096 2912 0 2846 117 45 72 80 0 8 6 pvpl 32 640443 0 628607 210 87 123 131 0 265 21 pmappl 216 1452 0 1420 3 0 3 3 0 8 0 extentpl 40 45 0 27 1 0 1 1 0 8 0 phpool 112 426 0 81 11 0 11 11 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(ffffffff8337b37c) at panic+0x1cf sys/kern/subr_prf.c:198 __assert(ffffffff833ba7b3,ffffffff833a3e01,52e,ffffffff833d457a) at __assert+0x29 sys/kern/subr_prf.c:-1 uvm_pagedequeue(fffffd800706b580) at uvm_pagedequeue+0x2cd sys/uvm/uvm_page.c:1324 uvm_pageclean(fffffd800706b580) at uvm_pageclean+0x2ac sys/uvm/uvm_page.c:981 uvm_pagefree(fffffd800706b580) at uvm_pagefree+0x26 sys/uvm/uvm_page.c:1020 uvm_anfree(fffffd806ad1aab0) at uvm_anfree+0xe9 sys/uvm/uvm_anon.c:112 amap_wipeout(fffffd806fc7b640) at amap_wipeout+0x246 sys/uvm/uvm_amap.c:-1 uvm_unmap_detach(ffff80003c951bb0,0) at uvm_unmap_detach+0x8a sys/uvm/uvm_map.c:1353 uvm_mapanon(fffffd806cb03460,ffff80003c951dd8,400000,0,3090713) at uvm_mapanon+0x854 sys/uvm/uvm_map.c:910 uvm_mmapanon(fffffd806cb03460,ffff80003c951dd8,400000,3,7,5012,5125c0e282b9b220,fffffd806cb03460) at uvm_mmapanon+0x1d0 sys/uvm/uvm_mmap.c:1029 sys_mmap(ffff80003c929780,ffff80003c951f30,ffff80003c951e80) at sys_mmap+0xa60 sys/uvm/uvm_mmap.c:426 syscall(ffff80003c951f30) at syscall+0x962 mi_syscall sys/sys/syscall_mi.h:-1 [inline] syscall(ffff80003c951f30) at syscall+0x962 sys/arch/amd64/amd64/trap.c:775 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0xc0e0f478640, count: -14 ddb> machine ddbcpu 1 No such command ddb> trace db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:438 panic(ffffffff8337b37c) at panic+0x1cf sys/kern/subr_prf.c:198 __assert(ffffffff833ba7b3,ffffffff833a3e01,52e,ffffffff833d457a) at __assert+0x29 sys/kern/subr_prf.c:-1 uvm_pagedequeue(fffffd800706b580) at uvm_pagedequeue+0x2cd sys/uvm/uvm_page.c:1324 uvm_pageclean(fffffd800706b580) at uvm_pageclean+0x2ac sys/uvm/uvm_page.c:981 uvm_pagefree(fffffd800706b580) at uvm_pagefree+0x26 sys/uvm/uvm_page.c:1020 uvm_anfree(fffffd806ad1aab0) at uvm_anfree+0xe9 sys/uvm/uvm_anon.c:112 amap_wipeout(fffffd806fc7b640) at amap_wipeout+0x246 sys/uvm/uvm_amap.c:-1 uvm_unmap_detach(ffff80003c951bb0,0) at uvm_unmap_detach+0x8a sys/uvm/uvm_map.c:1353 uvm_mapanon(fffffd806cb03460,ffff80003c951dd8,400000,0,3090713) at uvm_mapanon+0x854 sys/uvm/uvm_map.c:910 uvm_mmapanon(fffffd806cb03460,ffff80003c951dd8,400000,3,7,5012,5125c0e282b9b220,fffffd806cb03460) at uvm_mmapanon+0x1d0 sys/uvm/uvm_mmap.c:1029 sys_mmap(ffff80003c929780,ffff80003c951f30,ffff80003c951e80) at sys_mmap+0xa60 sys/uvm/uvm_mmap.c:426 syscall(ffff80003c951f30) at syscall+0x962 mi_syscall sys/sys/syscall_mi.h:-1 [inline] syscall(ffff80003c951f30) at syscall+0x962 sys/arch/amd64/amd64/trap.c:775 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0xc0e0f478640, count: -14