panic: tcp_output Stopped at db_enter+0x18: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND 309443 15446 0 0 0 1 syz-executor.5 * 58550 15446 0 0 0x4000000 0 syz-executor.5 db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:437 panic(ffffffff8257866e) at panic+0x177 sys/kern/subr_prf.c:198 tcp_output(ffff800000c1db68) at tcp_output+0x2cd2 sys/netinet/tcp_output.c:727 tcp_send(fffffd8070c97990,fffffd8070888800,0,fffffd807004a000) at tcp_send+0xc4 sys/netinet/tcp_usrreq.c:953 sosend(fffffd8070c97990,0,ffff80002e51a880,0,fffffd807004a000,0) at sosend+0x62a pru_send sys/sys/protosw.h:331 [inline] sosend(fffffd8070c97990,0,ffff80002e51a880,0,fffffd807004a000,0) at sosend+0x62a sys/kern/uipc_socket.c:646 sendit(ffff800021258540,4,ffff80002e51aa00,0,ffff80002e51aaf0) at sendit+0x65d sys/kern/uipc_syscalls.c:694 sys_sendmsg(ffff800021258540,ffff80002e51aaa8,ffff80002e51aaf0) at sys_sendmsg+0x198 sys/kern/uipc_syscalls.c:601 syscall(ffff80002e51ab70) at syscall+0x4c3 mi_syscall sys/sys/syscall_mi.h:101 [inline] syscall(ffff80002e51ab70) at syscall+0x4c3 sys/arch/amd64/amd64/trap.c:585 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0xd4af8df0c00, count: 6 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{0}> ddb{0}> set $lines = 0 ddb{0}> set $maxwidth = 0 ddb{0}> show panic *cpu0: tcp_output ddb{0}> trace db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:437 panic(ffffffff8257866e) at panic+0x177 sys/kern/subr_prf.c:198 tcp_output(ffff800000c1db68) at tcp_output+0x2cd2 sys/netinet/tcp_output.c:727 tcp_send(fffffd8070c97990,fffffd8070888800,0,fffffd807004a000) at tcp_send+0xc4 sys/netinet/tcp_usrreq.c:953 sosend(fffffd8070c97990,0,ffff80002e51a880,0,fffffd807004a000,0) at sosend+0x62a pru_send sys/sys/protosw.h:331 [inline] sosend(fffffd8070c97990,0,ffff80002e51a880,0,fffffd807004a000,0) at sosend+0x62a sys/kern/uipc_socket.c:646 sendit(ffff800021258540,4,ffff80002e51aa00,0,ffff80002e51aaf0) at sendit+0x65d sys/kern/uipc_syscalls.c:694 sys_sendmsg(ffff800021258540,ffff80002e51aaa8,ffff80002e51aaf0) at sys_sendmsg+0x198 sys/kern/uipc_syscalls.c:601 syscall(ffff80002e51ab70) at syscall+0x4c3 mi_syscall sys/sys/syscall_mi.h:101 [inline] syscall(ffff80002e51ab70) at syscall+0x4c3 sys/arch/amd64/amd64/trap.c:585 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0xd4af8df0c00, count: -9 ddb{0}> show registers rdi 0 rsi 0x1 rbp 0xffff80002e51a4e0 rbx 0xffffffff82955b8f cpu_info_full_primary+0x2b8f rdx 0xffff800000c03c40 rcx 0 rax 0xffff800021258540 r8 0x101010101010101 r9 0x8080808080808080 r10 0xc7bd06ce2aa02750 r11 0x371d122b41483eaf r12 0xffffffff82955990 cpu_info_full_primary+0x2990 r13 0 r14 0 r15 0x1 rip 0xffffffff8240e298 db_enter+0x18 cs 0x8 rflags 0x246 rsp 0xffff80002e51a4d0 ss 0x10 db_enter+0x18: addq $0x8,%rsp ddb{0}> show proc PROC (syz-executor.5) pid=58550 stat=onproc flags process=0 proc=4000000 pri=32, usrpri=82, nice=20 forw=0xffffffffffffffff, list=0xffff800021258fc0,0xffffffff82ba7f40 process=0xffff8000ffff0c90 user=0xffff80002e515000, vmspace=0xfffffd806a9e7740 estcpu=36, cpticks=0, pctcpu=0.0 user=0, sys=0, intr=0 ddb{0}> ps PID TID PPID UID S FLAGS WAIT COMMAND 15446 309443 22386 0 7 0 syz-executor.5 *15446 58550 22386 0 7 0x4000000 syz-executor.5 56737 314401 84302 0 2 0 syz-executor.0 11695 452805 54518 0 2 0 syz-executor.7 11695 204848 54518 0 3 0x4000080 fsleep syz-executor.7 58278 329065 84972 0 2 0 syz-executor.6 58278 474697 84972 0 3 0x4000000 smrbar syz-executor.6 22466 158519 49085 0 2 0 syz-executor.1 22466 321522 49085 0 2 0x4000000 syz-executor.1 22466 157294 49085 0 3 0x4000080 fsleep syz-executor.1 92372 127452 2386 0 3 0x80 nanoslp syz-executor.2 92372 206651 2386 0 3 0x4000080 rest syz-executor.2 78840 472743 50577 0 2 0 syz-executor.4 78840 42264 50577 0 3 0x4000080 ttyout syz-executor.4 84972 493777 52753 0 3 0x82 nanoslp syz-executor.6 2386 440553 52753 0 3 0x82 nanoslp syz-executor.2 22386 277292 52753 0 3 0x82 nanoslp syz-executor.5 81233 507133 0 0 3 0x14200 bored sosplice 54518 186777 52753 0 3 0x82 nanoslp syz-executor.7 49085 160153 52753 0 2 0x2 syz-executor.1 50577 174134 52753 0 3 0x82 nanoslp syz-executor.4 27955 488248 52753 0 3 0x82 piperd syz-executor.3 84302 334041 52753 0 3 0x82 nanoslp syz-executor.0 52753 497866 43268 0 3 0x82 wait syz-fuzzer 52753 197051 43268 0 3 0x4000082 thrsleep syz-fuzzer 52753 324369 43268 0 3 0x4000082 wait syz-fuzzer 52753 415061 43268 0 3 0x4000082 wait syz-fuzzer 52753 22927 43268 0 3 0x4000082 wait syz-fuzzer 52753 262294 43268 0 3 0x4000082 wait syz-fuzzer 52753 361338 43268 0 3 0x4000082 thrsleep syz-fuzzer 52753 10168 43268 0 3 0x4000082 thrsleep syz-fuzzer 52753 160279 43268 0 3 0x4000082 thrsleep syz-fuzzer 52753 373932 43268 0 3 0x4000082 wait syz-fuzzer 52753 244660 43268 0 3 0x4000082 kqread syz-fuzzer 52753 141113 43268 0 3 0x4000082 wait syz-fuzzer 52753 24171 43268 0 3 0x4000082 wait syz-fuzzer 52753 400393 43268 0 3 0x4000082 thrsleep syz-fuzzer 52753 325764 43268 0 3 0x4000082 thrsleep syz-fuzzer 52753 447439 43268 0 3 0x4000082 thrsleep syz-fuzzer 43268 264543 28919 0 3 0x10008a sigsusp ksh 28919 254621 412 0 3 0x9a kqread sshd 45251 170841 1 0 3 0x100083 ttyin getty 412 504481 1 0 3 0x88 kqread sshd 89842 392995 81674 74 3 0x1100092 bpf pflogd 81674 361527 1 0 3 0x80 netio pflogd 85286 376738 78890 73 3 0x1100090 kqread syslogd 78890 452277 1 0 3 0x100082 netio syslogd 84690 73491 1 0 3 0x100080 kqread resolvd 91510 61683 19412 77 3 0x100092 kqread dhcpleased 76754 123457 19412 77 3 0x100092 kqread dhcpleased 19412 195901 1 0 3 0x80 kqread dhcpleased 57036 318865 0 0 3 0x14200 bored smr 91952 480861 0 0 2 0x14200 zerothread 56240 68758 0 0 3 0x14200 aiodoned aiodoned 11707 107265 0 0 3 0x14200 syncer update 8348 451012 0 0 3 0x14200 cleaner cleaner 41622 467130 0 0 3 0x14200 reaper reaper 5038 304677 0 0 3 0x14200 pgdaemon pagedaemon 46962 509988 0 0 3 0x14200 bored viomb 17225 149263 0 0 3 0x40014200 acpi0 acpi0 54889 480222 0 0 3 0x40014200 idle1 61614 69880 0 0 3 0x14200 bored softnet 59700 486399 0 0 3 0x14200 bored softnet 5444 9733 0 0 3 0x14200 bored softnet 94295 387837 0 0 3 0x14200 bored softnet 15597 153484 0 0 3 0x14200 bored systqmp 62209 469436 0 0 3 0x14200 bored systq 52138 322170 0 0 3 0x40014200 bored softclock 17160 148929 0 0 3 0x40014200 idle0 1 519022 0 0 3 0x80082 wait init 0 0 -1 0 3 0x10200 scheduler swapper ddb{0}> show all locks Process 15446 (syz-executor.5) thread 0xffff800021258540 (58550) exclusive rwlock netlock r = 0 (0xffffffff829a5720) #0 witness_lock+0x44d #1 sosend+0x500 sys/kern/uipc_socket.c:632 #2 sendit+0x65d sys/kern/uipc_syscalls.c:694 #3 sys_sendmsg+0x198 sys/kern/uipc_syscalls.c:601 #4 syscall+0x4c3 mi_syscall sys/sys/syscall_mi.h:101 [inline] #4 syscall+0x4c3 sys/arch/amd64/amd64/trap.c:585 #5 Xsyscall+0x128 Process 58278 (syz-executor.6) thread 0xffff8000212597a0 (474697) exclusive rwlock clonelk r = 0 (0xffffffff829a5690) #0 witness_lock+0x44d #1 if_clone_destroy+0x49 #2 tun_dev_close+0x14d sys/net/if_tun.c:509 #3 spec_close+0x34b sys/kern/spec_vnops.c:550 #4 VOP_CLOSE+0xe3 sys/kern/vfs_vops.c:156 #5 vn_closefile+0xd7 vn_close sys/kern/vfs_vnops.c:292 [inline] #5 vn_closefile+0xd7 sys/kern/vfs_vnops.c:609 #6 fdrop+0xc7 sys/kern/kern_descrip.c:1274 #7 closef+0x11c sys/kern/kern_descrip.c:1258 #8 syscall+0x4c3 mi_syscall sys/sys/syscall_mi.h:101 [inline] #8 syscall+0x4c3 sys/arch/amd64/amd64/trap.c:585 #9 Xsyscall+0x128 ddb{0}> show malloc Type InUse MemUse HighUse Limit Requests Type Lim devbuf 10196 6482K 7052K 78643K 13501 0 pcb 13 8K 8K 78643K 287 0 rtable 163 15K 15K 78643K 872 0 ifaddr 75 15K 17K 78643K 447 0 counters 52 35K 35K 78643K 136 0 ioctlops 0 0K 4K 78643K 1741 0 iov 0 0K 32K 78643K 193 0 mount 1 1K 1K 78643K 1 0 log 0 0K 0K 78643K 4 0 vnodes 1270 79K 80K 78643K 2342 0 UFS quota 1 32K 32K 78643K 1 0 UFS mount 5 36K 36K 78643K 5 0 shm 2 1K 9K 78643K 30 0 VM map 2 1K 1K 78643K 2 0 sem 12 0K 0K 78643K 69 0 dirhash 12 2K 2K 78643K 12 0 ACPI 1697 195K 286K 78643K 12548 0 file desc 17 61K 89K 78643K 3756 0 sigio 0 0K 0K 78643K 125 0 proc 73 91K 127K 78643K 853 0 subproc 104 6K 6K 78643K 156 0 NFS srvsock 1 0K 0K 78643K 1 0 NFS daemon 1 16K 16K 78643K 1 0 ip_moptions 0 0K 0K 78643K 332 0 in_multi 59 3K 6K 78643K 310 0 ether_multi 1 0K 0K 78643K 82 0 mrt 1 0K 0K 78643K 68 0 ISOFS mount 1 32K 32K 78643K 1 0 MSDOSFS mount 1 16K 16K 78643K 1 0 ttys 115 519K 519K 78643K 115 0 exec 0 0K 2K 78643K 946 0 tdb 3 0K 0K 78643K 3 0 pagedep 1 8K 8K 78643K 1 0 inodedep 1 32K 32K 78643K 1 0 newblk 1 0K 0K 78643K 1 0 VM swap 8 62K 62K 78643K 8 0 UVM amap 252 81K 81K 78643K 20043 0 UVM aobj 60 2K 2K 78643K 60 0 memdesc 1 4K 4K 78643K 1 0 crypto data 1 1K 1K 78643K 1 0 ip6_options 0 0K 0K 78643K 182 0 NDP 11 0K 2K 78643K 83 0 temp 124 4721K 4800K 78643K 60934 0 kqueue 12 18K 34K 78643K 295 0 SYN cache 2 16K 16K 78643K 2 0 ddb{0}> show all pools Name Size Requests Fail Releases Pgreq Pgrel Npage Hiwat Minpg Maxpg Idle plcache 128 22 0 0 1 0 1 1 0 8 0 rtpcb 120 98 0 95 1 0 1 1 0 8 0 rtentry 112 202 0 135 4 1 3 4 0 8 0 unpcb 144 804 0 789 3 2 1 2 0 8 0 syncache 296 105 0 105 5 5 0 1 0 8 0 tcpqe 32 11 0 11 2 2 0 1 0 8 0 tcpcb 768 913 0 904 16 12 4 6 0 8 2 arp 120 26 0 16 1 0 1 1 0 8 0 inpcb 368 1939 0 1927 7 5 2 3 0 8 0 nd6 48 42 0 30 1 0 1 1 0 8 0 pkpcb 40 100 0 100 2 2 0 1 0 8 0 kcovpl 48 12 0 4 1 0 1 1 0 8 0 ppxss 1256 23 0 23 2 2 0 1 0 8 0 pfstscr 40 4 0 4 1 1 0 1 0 8 0 pffrag 232 4 0 3 1 0 1 1 0 482 0 pffrnode 88 4 0 3 1 0 1 1 0 8 0 pffrent 40 10 0 9 2 1 1 1 0 8 0 pfosfp 40 1441 0 1017 5 0 5 5 0 8 0 pfosfpen 112 1441 0 726 21 0 21 21 0 8 0 pfrktable 1344 129 0 125 2 1 1 1 0 8 0 pfanchor 1280 207 0 182 5 2 3 3 0 8 0 pftag 88 16 0 14 1 0 1 1 0 8 0 pfqueue 264 4 0 4 1 1 0 1 0 8 0 pfstitem 24 38 0 36 1 0 1 1 0 8 0 pfstkey 120 44 0 42 1 0 1 1 0 8 0 pfstate 336 40 0 38 3 2 1 3 0 8 0 pfrule 1360 85 0 76 2 1 1 2 0 8 0 rttmr 136 19 0 19 2 2 0 1 0 8 0 art_heap8 4096 1 0 0 1 0 1 1 0 8 0 art_heap4 256 843 0 560 30 11 19 29 0 8 0 art_table 32 844 0 560 4 1 3 4 0 8 0 art_node 16 201 0 141 1 0 1 1 0 8 0 sysvmsgpl 40 32 0 16 1 0 1 1 0 8 0 semupl 112 20 0 20 1 1 0 1 0 8 0 semapl 112 57 0 47 1 0 1 1 0 8 0 shmpl 112 57 0 0 2 0 2 2 0 8 0 dirhash 1024 17 0 0 3 0 3 3 0 8 0 dino2pl 256 6317 0 4860 92 0 92 92 0 8 0 ffsino 272 6317 0 4860 98 0 98 98 0 8 0 nchpl 144 10867 0 9221 63 0 63 63 0 8 0 uvmvnodes 80 5926 0 0 121 0 121 121 0 8 0 vnodes 216 5926 0 0 330 0 330 330 0 8 0 namei 1024 29165 0 29165 2 1 1 2 0 8 1 percpumem 16 80 0 42 1 0 1 1 0 8 0 pfiaddrpl 120 38 0 30 2 1 1 1 0 8 0 kstatmem 264 106 0 84 2 0 2 2 0 8 0 scxspl 216 33594 0 33594 15 14 1 8 0 8 1 plimitpl 152 194 0 178 1 0 1 1 0 8 0 sigapl 424 4056 0 4008 8 2 6 7 0 8 0 futexpl 64 24544 0 24542 1 0 1 1 0 8 0 knotepl 120 578 0 0 17 0 17 17 0 8 0 kqueuepl 216 562 0 554 3 2 1 2 0 8 0 pipepl 320 300 0 272 3 0 3 3 0 8 0 fdescpl 496 4038 0 4008 5 1 4 5 0 8 0 filepl 152 13063 0 12817 12 2 10 11 0 8 0 lockfpl 104 487 0 485 1 0 1 1 0 8 0 lockfspl 48 181 0 179 1 0 1 1 0 8 0 sessionpl 144 28 0 11 1 0 1 1 0 8 0 pgrppl 48 42 0 25 1 0 1 1 0 8 0 ucredpl 104 2144 0 2131 1 0 1 1 0 8 0 zombiepl 144 4008 0 4008 1 0 1 1 0 8 1 processpl 1064 4056 0 4008 4 0 4 4 0 8 0 procpl 672 8251 0 8181 10 3 7 8 0 8 0 srpgc 96 12 0 12 1 1 0 1 0 8 0 sosppl 168 120 0 120 4 4 0 1 0 8 0 sockpl 488 2941 0 2911 12 7 5 7 0 8 1 mcl64k 65536 26 0 0 4 0 4 4 0 8 0 mcl16k 16384 9 0 0 2 0 2 2 0 8 0 mcl12k 12288 4 0 0 1 0 1 1 0 8 0 mcl9k 9216 4 0 0 1 0 1 1 0 8 0 mcl8k 8192 20 0 0 3 1 2 3 0 8 0 mcl4k 4096 31 0 0 4 0 4 4 0 8 0 mcl2k2 2112 2 0 0 1 0 1 1 0 8 0 mcl2k 2048 193 0 0 17 0 17 17 0 8 0 mtagpl 96 152 0 0 4 0 4 4 0 8 0 mbufpl 256 522 0 0 30 1 29 30 0 8 0 bufpl 288 10545 0 4216 453 0 453 453 0 8 0 anonpl 24 701224 0 693323 142 74 68 132 0 186 7 amapchunkpl 152 55486 0 54972 27 5 22 23 0 158 1 amappl16 200 11940 0 11760 64 53 11 55 0 8 0 amappl15 192 1333 0 1326 1 0 1 1 0 8 0 amappl14 184 1794 0 1782 1 0 1 1 0 8 0 amappl13 176 551 0 550 1 0 1 1 0 8 0 amappl12 168 244 0 242 3 2 1 1 0 8 0 amappl11 160 174 0 153 1 0 1 1 0 8 0 amappl10 152 462 0 455 1 0 1 1 0 8 0 amappl9 144 610 0 606 1 0 1 1 0 8 0 amappl8 136 935 0 850 3 0 3 3 0 8 0 amappl7 128 362 0 338 1 0 1 1 0 8 0 amappl6 120 348 0 334 2 1 1 2 0 8 0 amappl5 112 3125 0 3107 1 0 1 1 0 8 0 amappl4 104 2036 0 2000 2 0 2 2 0 8 0 amappl3 96 10496 0 10442 2 0 2 2 0 8 0 amappl2 88 982 0 946 2 0 2 2 0 8 0 amappl1 80 97151 0 96444 22 6 16 20 0 8 0 amappl 88 19384 0 19237 4 0 4 4 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 72 59 0 0 2 0 2 2 0 8 0 uaddrrnd 24 4038 0 4008 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 4038 0 4008 1 0 1 1 0 8 0 vmmpekpl 168 28266 0 28231 3 0 3 3 0 8 0 vmmpepl 168 377680 0 375373 151 44 107 137 0 357 1 vmsppl 368 4037 0 4008 4 1 3 4 0 8 0 rwobjpl 56 94337 0 87121 107 4 103 103 0 8 0 pdppl 4096 8083 0 8016 145 76 69 81 0 8 2 pvpl 32 1804704 0 1792117 278 105 173 258 0 265 50 pmappl 248 4037 0 4008 3 1 2 3 0 8 0 extentpl 40 56 0 38 1 0 1 1 0 8 0 phpool 112 905 0 103 24 0 24 24 0 8 0 ddb{0}> machine ddbcpu 0 Invalid cpu 0 ddb{0}> trace db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:437 panic(ffffffff8257866e) at panic+0x177 sys/kern/subr_prf.c:198 tcp_output(ffff800000c1db68) at tcp_output+0x2cd2 sys/netinet/tcp_output.c:727 tcp_send(fffffd8070c97990,fffffd8070888800,0,fffffd807004a000) at tcp_send+0xc4 sys/netinet/tcp_usrreq.c:953 sosend(fffffd8070c97990,0,ffff80002e51a880,0,fffffd807004a000,0) at sosend+0x62a pru_send sys/sys/protosw.h:331 [inline] sosend(fffffd8070c97990,0,ffff80002e51a880,0,fffffd807004a000,0) at sosend+0x62a sys/kern/uipc_socket.c:646 sendit(ffff800021258540,4,ffff80002e51aa00,0,ffff80002e51aaf0) at sendit+0x65d sys/kern/uipc_syscalls.c:694 sys_sendmsg(ffff800021258540,ffff80002e51aaa8,ffff80002e51aaf0) at sys_sendmsg+0x198 sys/kern/uipc_syscalls.c:601 syscall(ffff80002e51ab70) at syscall+0x4c3 mi_syscall sys/sys/syscall_mi.h:101 [inline] syscall(ffff80002e51ab70) at syscall+0x4c3 sys/arch/amd64/amd64/trap.c:585 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0xd4af8df0c00, count: -9 ddb{0}> machine ddbcpu 1 Stopped at x86_ipi_db+0x1a: addq $0x8,%rsp x86_ipi_db(ffff800020dd8ff0) at x86_ipi_db+0x1a sys/arch/amd64/amd64/db_interface.c:393 x86_ipi_handler() at x86_ipi_handler+0xb7 sys/arch/amd64/amd64/ipi.c:106 Xresume_lapic_ipi() at Xresume_lapic_ipi+0x23 end of kernel end trace frame: 0x7f7ffffc4cc0, count: 12 ddb{1}> trace x86_ipi_db(ffff800020dd8ff0) at x86_ipi_db+0x1a sys/arch/amd64/amd64/db_interface.c:393 x86_ipi_handler() at x86_ipi_handler+0xb7 sys/arch/amd64/amd64/ipi.c:106 Xresume_lapic_ipi() at Xresume_lapic_ipi+0x23 end of kernel end trace frame: 0x7f7ffffc4cc0, count: -3