kernel: protection fault trap, code=0 Stopped at pfi_ifhead_RB_REMOVE+0x50: movq 0x10(%r12),%rbx ddb{1}> ddb{1}> set $lines = 0 ddb{1}> set $maxwidth = 0 ddb{1}> show panic the kernel did not panic ddb{1}> trace pfi_ifhead_RB_REMOVE(ffffffff82945488,ffff800000b34600) at pfi_ifhead_RB_REMOVE+0x50 sys/net/pf_if.c:80 pfi_detach_ifgroup(ffff800000b2ef80) at pfi_detach_ifgroup+0x11b pfi_kif_unref sys/net/pf_if.c:211 [inline] pfi_detach_ifgroup(ffff800000b2ef80) at pfi_detach_ifgroup+0x11b sys/net/pf_if.c:304 if_delgroup(ffff800000b30000,ffff800000b2ef80) at if_delgroup+0x1a3 sys/net/if.c:2705 if_detach(ffff800000b30000) at if_detach+0x1cb sys/net/if.c:1049 tun_clone_destroy(ffff800000b30000) at tun_clone_destroy+0x1e1 sys/net/if_tun.c:325 if_clone_destroy(ffff8000222b53d0) at if_clone_destroy+0x136 sys/net/if.c:1212 tun_dev_close(5d01,7) at tun_dev_close+0x140 sys/net/if_tun.c:479 spec_close(ffff8000222b54a0) at spec_close+0x311 sys/kern/spec_vnops.c:560 VOP_CLOSE(fffffd806e7c0788,7,fffffd807f7b7b40,ffff8000223317b0) at VOP_CLOSE+0xeb sys/kern/vfs_vops.c:177 vn_closefile(fffffd806cb658f8,ffff8000223317b0) at vn_closefile+0xd7 vn_close sys/kern/vfs_vnops.c:298 [inline] vn_closefile(fffffd806cb658f8,ffff8000223317b0) at vn_closefile+0xd7 sys/kern/vfs_vnops.c:614 fdrop(fffffd806cb658f8,ffff8000223317b0) at fdrop+0xc2 sys/kern/kern_descrip.c:1279 closef(fffffd806cb658f8,ffff8000223317b0) at closef+0x11c sys/kern/kern_descrip.c:1263 fdfree(ffff8000223317b0) at fdfree+0xf4 sys/kern/kern_descrip.c:1195 exit1(ffff8000223317b0,0,19,1) at exit1+0x345 sys/kern/kern_exit.c:199 postsig(ffff8000223317b0,19) at postsig+0x59c sigexit sys/kern/kern_sig.c:1494 [inline] postsig(ffff8000223317b0,19) at postsig+0x59c sys/kern/kern_sig.c:1423 userret(ffff8000223317b0) at userret+0x189 sys/kern/kern_sig.c:1914 syscall(ffff8000222b5920) at syscall+0x55c mi_syscall_return sys/sys/syscall_mi.h:129 [inline] syscall(ffff8000222b5920) at syscall+0x55c sys/arch/amd64/amd64/trap.c:612 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x7f7fffffa660, count: -18 ddb{1}> show registers rdi 0xffffffff82945488 pfi_ifs rsi 0xffff800000b34600 rbp 0xffff8000222b5230 rbx 0xdeadbeefdeadbeef rdx 0 rcx 0xffff800000af4980 rax 0xffff800000b34610 r8 0xf8 r9 0x8080808080808080 r10 0x4afb627f9d852009 r11 0x4480407b6f2e562e r12 0xdeadbeefdeadbeef r13 0xffff800000b2f0a0 r14 0xffff800000b34600 r15 0xffffffff82945488 pfi_ifs rip 0xffffffff822a81a0 pfi_ifhead_RB_REMOVE+0x50 cs 0x8 rflags 0x10282 __ALIGN_SIZE+0xf282 rsp 0xffff8000222b51d0 ss 0x10 pfi_ifhead_RB_REMOVE+0x50: movq 0x10(%r12),%rbx ddb{1}> show proc PROC (syz-executor.1) pid=119131 stat=onproc flags process=a proc=2000 pri=32, usrpri=76, nice=20 forw=0xffffffffffffffff, list=0xffff800022331510,0xffff800022330fe0 process=0xffff8000224a9da0 user=0xffff8000222b0000, vmspace=0xfffffd806a8cba20 estcpu=36, cpticks=2, pctcpu=0.27 user=0, sys=1, intr=0 ddb{1}> ps PID TID PPID UID S FLAGS WAIT COMMAND 27399 171365 38967 0 2 0x2 syz-executor.0 85610 192549 0 0 3 0x14280 nfsidl nfsio 61581 69086 0 0 3 0x14280 nfsidl nfsio 89723 429799 0 0 3 0x14280 nfsidl nfsio 46650 220493 0 0 3 0x14280 nfsidl nfsio 81297 181368 0 0 3 0x14280 nfsidl nfsio 35314 160084 0 0 3 0x14280 nfsidl nfsio 23241 271211 0 0 3 0x14280 nfsidl nfsio 99249 170439 0 0 3 0x14280 nfsidl nfsio 42108 198284 0 0 3 0x14280 nfsidl nfsio 24568 257476 0 0 3 0x14280 nfsidl nfsio 68074 76643 0 0 3 0x14280 nfsidl nfsio 7459 79294 0 0 3 0x14280 nfsidl nfsio 86757 448882 0 0 3 0x14280 nfsidl nfsio 73232 231514 0 0 3 0x14280 nfsidl nfsio 98277 329585 0 0 3 0x14280 nfsidl nfsio 2810 249478 0 0 3 0x14280 nfsidl nfsio 6902 477484 0 0 3 0x14280 nfsidl nfsio 41547 170374 0 0 3 0x14280 nfsidl nfsio 87554 68213 0 0 3 0x14280 nfsidl nfsio 8886 167379 0 0 3 0x14280 nfsidl nfsio 90989 256618 0 0 3 0x14200 bored sosplice 38967 203981 11964 0 7 0x2 syz-fuzzer 38967 450361 11964 0 3 0x4000082 nanoslp syz-fuzzer 38967 169177 11964 0 3 0x4000082 thrsleep syz-fuzzer 38967 399661 11964 0 3 0x4000082 thrsleep syz-fuzzer 38967 303036 11964 0 3 0x4000082 thrsleep syz-fuzzer 38967 494370 11964 0 3 0x4000082 thrsleep syz-fuzzer 38967 2249 11964 0 3 0x4000082 kqread syz-fuzzer 38967 369154 11964 0 3 0x4000082 thrsleep syz-fuzzer 11964 349706 62003 0 3 0x10008a sigsusp ksh 62003 514271 38214 0 3 0x92 select sshd 23695 73699 1 0 3 0x100083 ttyin getty 38214 73907 1 0 3 0x80 select sshd 83500 311601 79562 74 3 0x100092 bpf pflogd 79562 501390 1 0 3 0x80 netio pflogd 68938 30887 49939 73 3 0x100090 kqread syslogd 49939 522464 1 0 3 0x100082 netio syslogd 80261 220699 1 77 2 0x100090 dhclient 30199 511585 1 0 3 0x80 poll dhclient 60956 495811 0 0 3 0x14200 bored smr 27664 367269 0 0 3 0x14200 pgzero zerothread 98183 17051 0 0 3 0x14200 aiodoned aiodoned 67986 90106 0 0 3 0x14200 syncer update 85768 348794 0 0 3 0x14200 cleaner cleaner 75399 68139 0 0 3 0x14200 reaper reaper 3674 490866 0 0 3 0x14200 pgdaemon pagedaemon 37182 479453 0 0 3 0x14200 bored crynlk 49690 193093 0 0 3 0x14200 bored crypto 50972 478113 0 0 3 0x14200 bored viomb 25681 412301 0 0 3 0x40014200 acpi0 acpi0 50803 33875 0 0 3 0x40014200 idle1 75741 323295 0 0 3 0x14200 bored softnet 50279 272543 0 0 2 0x14200 systqmp 90126 310150 0 0 3 0x14200 bored systq 6903 206598 0 0 3 0x40014200 bored softclock 39674 338816 0 0 3 0x40014200 idle0 1 255297 0 0 3 0x82 wait init 0 0 -1 0 3 0x10200 scheduler swapper ddb{1}> show all locks Process 38967 (syz-fuzzer) thread 0xffff8000ffff6550 (203981) exclusive rwlock pipelk r = 0 (0xfffffd806f777910) #0 witness_lock+0x4b0 stacktrace_save sys/sys/stacktrace.h:36 [inline] #0 witness_lock+0x4b0 sys/kern/subr_witness.c:1182 #1 pipe_write+0x36f sys/kern/sys_pipe.c:560 #2 dofilewritev+0x1ab sys/kern/sys_generic.c:365 #3 sys_write+0x83 sys/kern/sys_generic.c:285 #4 syscall+0x4a1 mi_syscall sys/sys/syscall_mi.h:102 [inline] #4 syscall+0x4a1 sys/arch/amd64/amd64/trap.c:590 #5 Xsyscall+0x128 ddb{1}> show malloc Type InUse MemUse HighUse Limit Requests Type Lim devbuf 9535 6445K 7268K 78643K 17160 0 pcb 13 8K 8K 78643K 367 0 rtable 87 3K 4K 78643K 830 0 ifaddr 69 13K 15K 78643K 279 0 counters 44 34K 34K 78643K 118 0 ioctlops 0 0K 4K 78643K 1689 0 iov 0 0K 12K 78643K 94 0 mount 1 1K 1K 78643K 1 0 vnodes 1226 77K 77K 78643K 3118 0 UFS quota 1 32K 32K 78643K 1 0 UFS mount 5 36K 36K 78643K 5 0 shm 2 1K 9K 78643K 27 0 VM map 2 1K 1K 78643K 2 0 sem 12 0K 0K 78643K 232 0 dirhash 12 2K 2K 78643K 12 0 ACPI 1697 195K 286K 78643K 12598 0 file desc 4 9K 25K 78643K 5423 0 sigio 0 0K 0K 78643K 30 0 proc 63 63K 95K 78643K 1014 0 subproc 23 1K 2K 78643K 85 0 NFS srvsock 1 0K 0K 78643K 1 0 NFS daemon 1 16K 16K 78643K 1 0 ip_moptions 0 0K 0K 78643K 389 0 in_multi 22 1K 2K 78643K 383 0 ether_multi 1 0K 0K 78643K 99 0 mrt 0 0K 0K 78643K 51 0 ISOFS mount 1 32K 32K 78643K 1 0 MSDOSFS mount 1 16K 16K 78643K 1 0 ttys 49 228K 228K 78643K 49 0 exec 0 0K 2K 78643K 575 0 pfkey data 0 0K 1K 78643K 5 0 pagedep 1 8K 8K 78643K 1 0 inodedep 1 32K 32K 78643K 1 0 newblk 1 0K 0K 78643K 1 0 VM swap 7 26K 26K 78643K 7 0 UVM amap 189 158K 158K 78643K 13112 0 UVM aobj 102 8K 8K 78643K 102 0 memdesc 1 4K 4K 78643K 1 0 crypto data 1 1K 1K 78643K 1 0 ip6_options 0 0K 0K 78643K 317 0 NDP 13 0K 0K 78643K 86 0 temp 141 3975K 4051K 78643K 57794 0 kqueue 4 6K 12K 78643K 205 0 SYN cache 2 16K 16K 78643K 2 0 ddb{1}> show all pools Name Size Requests Fail Releases Pgreq Pgrel Npage Hiwat Minpg Maxpg Idle arp 64 12 0 8 1 0 1 1 0 8 0 plcache 128 20 0 0 1 0 1 1 0 8 0 rtpcb 120 144 0 142 1 0 1 1 0 8 0 rtentry 112 168 0 135 2 0 2 2 0 8 0 unpcb 120 915 0 901 2 1 1 2 0 8 0 syncache 296 78 0 78 6 6 0 1 0 8 0 tcpqe 32 22 0 22 3 3 0 1 0 8 0 tcpcb 736 1049 0 1045 20 16 4 5 0 8 3 inpcb 304 2431 0 2424 10 8 2 2 0 8 1 rttmr 72 12 0 12 1 1 0 1 0 8 0 nd6 48 43 0 40 1 0 1 1 0 8 0 pkpcb 40 20 0 20 3 2 1 1 0 8 1 kcovpl 48 5 0 4 1 0 1 1 0 8 0 ppxss 1128 11 0 11 2 2 0 1 0 8 0 pffrent 40 5 0 5 1 1 0 1 0 8 0 pfosfp 40 1428 0 1005 5 0 5 5 0 8 0 pfosfpen 112 1428 0 714 21 0 21 21 0 8 0 pfrktable 1344 14 0 14 1 1 0 1 0 8 0 pfstitem 24 81 0 50 1 0 1 1 0 8 0 pfstkey 112 81 0 50 1 0 1 1 0 8 0 pfstate 320 81 0 50 4 1 3 3 0 8 0 pfrule 1360 62 0 57 2 1 1 2 0 8 0 art_heap8 4096 1 0 0 1 0 1 1 0 8 0 art_heap4 256 611 0 420 15 3 12 13 0 8 0 art_table 32 612 0 420 2 0 2 2 0 8 0 art_node 16 160 0 120 1 0 1 1 0 8 0 sysvmsgpl 40 14 0 14 1 1 0 1 0 8 0 semapl 112 230 0 220 1 0 1 1 0 8 0 shmpl 112 99 0 0 3 0 3 3 0 8 0 dirhash 1024 17 0 0 3 0 3 3 0 8 0 dino2pl 256 8036 0 6627 92 3 89 89 0 8 0 ffsino 272 8036 0 6627 95 0 95 95 0 8 0 nchpl 144 14307 0 12714 60 0 60 60 0 8 0 uvmvnodes 72 5926 0 0 108 0 108 108 0 8 0 vnodes 224 5926 0 0 349 0 349 349 0 8 0 namei 1024 35547 0 35547 2 1 1 1 0 8 1 percpumem 16 70 0 37 1 0 1 1 0 8 0 vcpupl 1984 13 0 0 2 0 2 2 0 8 0 vmpool 560 23 0 10 1 0 1 1 0 8 0 scxspl 216 43197 0 43197 14 13 1 8 0 8 1 plimitpl 152 83 0 75 1 0 1 1 0 8 0 sigapl 424 5651 0 5599 8 1 7 7 0 8 1 futexpl 56 35686 0 35686 3 2 1 1 0 8 1 knotepl 112 345 0 327 1 0 1 1 0 8 0 kqueuepl 168 1974 0 1963 1 0 1 1 0 8 0 pipepl 336 287 0 277 8 6 2 2 0 8 1 fdescpl 496 5614 0 5599 3 0 3 3 0 8 0 filepl 152 17661 0 17570 6 1 5 6 0 8 1 lockfpl 104 936 0 935 1 0 1 1 0 8 0 lockfspl 48 337 0 336 1 0 1 1 0 8 0 sessionpl 144 21 0 10 1 0 1 1 0 8 0 pgrppl 48 21 0 10 1 0 1 1 0 8 0 ucredpl 96 1946 0 1937 1 0 1 1 0 8 0 zombiepl 144 5600 0 5599 2 1 1 1 0 8 0 processpl 1080 5651 0 5599 4 0 4 4 0 8 0 procpl 672 12071 0 12012 6 0 6 6 0 8 0 sosppl 168 41 0 41 4 3 1 1 0 8 1 sockpl 432 3518 0 3495 14 10 4 6 0 8 0 mcl64k 65536 37 0 0 4 2 2 3 0 8 0 mcl16k 16384 15 0 0 2 0 2 2 0 8 0 mcl12k 12288 17 0 0 2 0 2 2 0 8 0 mcl9k 9216 17 0 0 2 0 2 2 0 8 0 mcl8k 8192 11 0 0 2 0 2 2 0 8 0 mcl4k 4096 19 0 0 3 1 2 3 0 8 0 mcl2k 2048 239 0 0 14 0 14 14 0 8 0 mtagpl 96 352 0 0 8 0 8 8 0 8 0 mbufpl 256 963 0 0 50 2 48 48 0 8 0 bufpl 280 11579 0 5330 447 0 447 447 0 8 0 anonpl 24 445947 0 439995 100 63 37 72 0 186 0 amapchunkpl 152 21522 0 21364 20 13 7 14 0 158 0 amappl16 200 20365 0 20146 54 42 12 32 0 8 0 amappl15 192 2499 0 2498 1 0 1 1 0 8 0 amappl14 184 946 0 940 1 0 1 1 0 8 0 amappl13 176 53 0 52 1 0 1 1 0 8 0 amappl12 168 803 0 800 1 0 1 1 0 8 0 amappl11 160 67 0 50 1 0 1 1 0 8 0 amappl10 152 25 0 19 1 0 1 1 0 8 0 amappl9 144 1174 0 1172 2 1 1 1 0 8 0 amappl8 136 274 0 186 4 0 4 4 0 8 0 amappl7 128 1435 0 1428 1 0 1 1 0 8 0 amappl6 120 79 0 67 1 0 1 1 0 8 0 amappl5 112 4596 0 4579 1 0 1 1 0 8 0 amappl4 104 2052 0 2018 2 1 1 2 0 8 0 amappl3 96 272 0 262 1 0 1 1 0 8 0 amappl2 88 45757 0 45688 3 1 2 3 0 8 0 amappl1 80 163486 0 163034 30 19 11 21 0 8 0 amappl 88 12416 0 12352 2 0 2 2 0 92 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 6 0 6 1 1 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 64 101 0 0 2 0 2 2 0 8 0 uaddrrnd 24 5637 0 5609 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 5637 0 5609 1 0 1 1 0 8 0 vmmpekpl 168 28925 0 28894 2 0 2 2 0 8 0 vmmpepl 168 700186 0 698795 131 58 73 84 0 357 2 vmsppl 368 5636 0 5609 3 0 3 3 0 8 0 rwobjpl 56 145219 0 144256 39 24 15 19 0 8 0 pdppl 4096 11281 0 11231 75 21 54 54 0 8 4 pvpl 32 1820053 0 1810976 176 96 80 129 0 265 3 pmappl 232 5636 0 5609 3 1 2 2 0 8 0 extentpl 40 58 0 40 1 0 1 1 0 8 0 phpool 112 394 0 58 10 0 10 10 0 8 0 ddb{1}> machine ddbcpu 0 Stopped at x86_ipi_db+0x1a: addq $0x8,%rsp ddb{0}> trace x86_ipi_db(ffffffff8275cff0) at x86_ipi_db+0x1a sys/arch/amd64/amd64/db_interface.c:352 x86_ipi_handler() at x86_ipi_handler+0xb7 sys/arch/amd64/amd64/ipi.c:106 Xresume_lapic_ipi() at Xresume_lapic_ipi+0x23 __mp_lock(ffffffff828cbd68) at __mp_lock+0x122 __mp_lock_spin sys/kern/kern_lock.c:116 [inline] __mp_lock(ffffffff828cbd68) at __mp_lock+0x122 sys/kern/kern_lock.c:147 selwakeup(fffffd806f777890) at selwakeup+0x16 sys/kern/sys_generic.c:776 pipeselwakeup(fffffd806f777870) at pipeselwakeup+0x7c sys/kern/sys_pipe.c:370 pipe_write(fffffd8079e11000,ffff800021257098,0) at pipe_write+0x785 dofilewritev(ffff8000ffff6550,1,ffff800021257098,0,ffff800021257180) at dofilewritev+0x1ab sys/kern/sys_generic.c:365 sys_write(ffff8000ffff6550,ffff800021257130,ffff800021257180) at sys_write+0x83 sys/kern/sys_generic.c:285 syscall(ffff800021257200) at syscall+0x4a1 mi_syscall sys/sys/syscall_mi.h:102 [inline] syscall(ffff800021257200) at syscall+0x4a1 sys/arch/amd64/amd64/trap.c:590 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0xc0000e9820, count: -11 ddb{0}> machine ddbcpu 1 Stopped at pfi_ifhead_RB_REMOVE+0x50: movq 0x10(%r12),%rbx ddb{1}> trace pfi_ifhead_RB_REMOVE(ffffffff82945488,ffff800000b34600) at pfi_ifhead_RB_REMOVE+0x50 sys/net/pf_if.c:80 pfi_detach_ifgroup(ffff800000b2ef80) at pfi_detach_ifgroup+0x11b pfi_kif_unref sys/net/pf_if.c:211 [inline] pfi_detach_ifgroup(ffff800000b2ef80) at pfi_detach_ifgroup+0x11b sys/net/pf_if.c:304 if_delgroup(ffff800000b30000,ffff800000b2ef80) at if_delgroup+0x1a3 sys/net/if.c:2705 if_detach(ffff800000b30000) at if_detach+0x1cb sys/net/if.c:1049 tun_clone_destroy(ffff800000b30000) at tun_clone_destroy+0x1e1 sys/net/if_tun.c:325 if_clone_destroy(ffff8000222b53d0) at if_clone_destroy+0x136 sys/net/if.c:1212 tun_dev_close(5d01,7) at tun_dev_close+0x140 sys/net/if_tun.c:479 spec_close(ffff8000222b54a0) at spec_close+0x311 sys/kern/spec_vnops.c:560 VOP_CLOSE(fffffd806e7c0788,7,fffffd807f7b7b40,ffff8000223317b0) at VOP_CLOSE+0xeb sys/kern/vfs_vops.c:177 vn_closefile(fffffd806cb658f8,ffff8000223317b0) at vn_closefile+0xd7 vn_close sys/kern/vfs_vnops.c:298 [inline] vn_closefile(fffffd806cb658f8,ffff8000223317b0) at vn_closefile+0xd7 sys/kern/vfs_vnops.c:614 fdrop(fffffd806cb658f8,ffff8000223317b0) at fdrop+0xc2 sys/kern/kern_descrip.c:1279 closef(fffffd806cb658f8,ffff8000223317b0) at closef+0x11c sys/kern/kern_descrip.c:1263 fdfree(ffff8000223317b0) at fdfree+0xf4 sys/kern/kern_descrip.c:1195 exit1(ffff8000223317b0,0,19,1) at exit1+0x345 sys/kern/kern_exit.c:199 postsig(ffff8000223317b0,19) at postsig+0x59c sigexit sys/kern/kern_sig.c:1494 [inline] postsig(ffff8000223317b0,19) at postsig+0x59c sys/kern/kern_sig.c:1423 userret(ffff8000223317b0) at userret+0x189 sys/kern/kern_sig.c:1914 syscall(ffff8000222b5920) at syscall+0x55c mi_syscall_return sys/sys/syscall_mi.h:129 [inline] syscall(ffff8000222b5920) at syscall+0x55c sys/arch/amd64/amd64/trap.c:612 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x7f7fffffa660, count: -18