panic: mutex 0xfffffd806e8ae5e8 not held in knote_dequeue Stopped at db_enter+0x18: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND 411878 57343 0 0 0 0 syz-executor.0 *310563 57343 0 0 0x4000000 1K syz-executor.0 db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:399 panic(ffffffff82460c20) at panic+0x177 sys/kern/subr_prf.c:202 knote_dequeue(fffffd8065ff7e08) at knote_dequeue+0x12b sys/kern/kern_event.c:1860 filt_timermodify(ffff8000244ef2e0,fffffd8065ff7e08) at filt_timermodify+0x6f sys/kern/kern_event.c:479 kqueue_register(fffffd806e8ae5e8,ffff8000244ef2e0,ffff800021268d28) at kqueue_register+0xa89 filter_modify sys/kern/kern_event.c:662 [inline] kqueue_register(fffffd806e8ae5e8,ffff8000244ef2e0,ffff800021268d28) at kqueue_register+0xa89 sys/kern/kern_event.c:1125 sys_kevent(ffff800021268d28,ffff8000244ef598,ffff8000244ef5e0) at sys_kevent+0x214 sys/kern/kern_event.c:887 syscall(ffff8000244ef660) at syscall+0x5bf mi_syscall sys/sys/syscall_mi.h:102 [inline] syscall(ffff8000244ef660) at syscall+0x5bf sys/arch/amd64/amd64/trap.c:587 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x81b588b5b30, 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 *cpu1: mutex 0xfffffd806e8ae5e8 not held in knote_dequeue ddb{1}> trace db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:399 panic(ffffffff82460c20) at panic+0x177 sys/kern/subr_prf.c:202 knote_dequeue(fffffd8065ff7e08) at knote_dequeue+0x12b sys/kern/kern_event.c:1860 filt_timermodify(ffff8000244ef2e0,fffffd8065ff7e08) at filt_timermodify+0x6f sys/kern/kern_event.c:479 kqueue_register(fffffd806e8ae5e8,ffff8000244ef2e0,ffff800021268d28) at kqueue_register+0xa89 filter_modify sys/kern/kern_event.c:662 [inline] kqueue_register(fffffd806e8ae5e8,ffff8000244ef2e0,ffff800021268d28) at kqueue_register+0xa89 sys/kern/kern_event.c:1125 sys_kevent(ffff800021268d28,ffff8000244ef598,ffff8000244ef5e0) at sys_kevent+0x214 sys/kern/kern_event.c:887 syscall(ffff8000244ef660) at syscall+0x5bf mi_syscall sys/sys/syscall_mi.h:102 [inline] syscall(ffff8000244ef660) at syscall+0x5bf sys/arch/amd64/amd64/trap.c:587 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x81b588b5b30, count: -8 ddb{1}> show registers rdi 0 rsi 0x1 rbp 0xffff8000244ef0d0 rbx 0xffff800020d59bf7 rdx 0x8b rcx 0x2 rax 0x3a r8 0xffffffff816e1c04 kprintf+0x144 r9 0x1 r10 0x76ed6373008a4ba2 r11 0x88d3d954ef4e3956 r12 0xffff800020d599f8 r13 0 r14 0 r15 0x1 rip 0xffffffff81910f78 db_enter+0x18 cs 0x8 rflags 0x246 rsp 0xffff8000244ef0c0 ss 0x10 db_enter+0x18: addq $0x8,%rsp ddb{1}> show proc PROC (syz-executor.0) pid=310563 stat=onproc flags process=0 proc=4000000 pri=32, usrpri=86, nice=20 forw=0xffffffffffffffff, list=0xffff800021268548,0xffffffff827da780 process=0xffff800021225d98 user=0xffff8000244ea000, vmspace=0xfffffd807f009b80 estcpu=36, cpticks=1, pctcpu=0.0 user=0, sys=0, intr=0 ddb{1}> ps PID TID PPID UID S FLAGS WAIT COMMAND 57343 411878 15876 0 7 0 syz-executor.0 57343 107636 15876 0 2 0x4000000 syz-executor.0 *57343 310563 15876 0 7 0x4000000 syz-executor.0 41209 171510 0 0 3 0x14200 bored sosplice 86071 372309 59940 0 3 0x82 nanoslp syz-executor.1 15876 296299 59940 0 3 0x82 nanoslp syz-executor.0 59940 329512 84450 0 3 0x82 thrsleep syz-fuzzer 59940 123096 84450 0 3 0x4000082 nanoslp syz-fuzzer 59940 359140 84450 0 3 0x4000082 kqread syz-fuzzer 59940 510718 84450 0 3 0x4000082 thrsleep syz-fuzzer 59940 369799 84450 0 3 0x4000082 thrsleep syz-fuzzer 59940 96603 84450 0 3 0x4000082 thrsleep syz-fuzzer 59940 16387 84450 0 3 0x4000082 thrsleep syz-fuzzer 59940 130005 84450 0 3 0x4000082 thrsleep syz-fuzzer 84450 508731 31551 0 3 0x10008a sigsusp ksh 31551 293399 70967 0 3 0x92 select sshd 27399 250359 1 0 3 0x100083 ttyin getty 70967 459191 1 0 3 0x80 select sshd 81907 277973 79335 74 3 0x100092 bpf pflogd 79335 399419 1 0 3 0x80 netio pflogd 82343 218600 97731 73 3 0x100090 kqread syslogd 97731 502680 1 0 3 0x100082 netio syslogd 71976 207515 1 77 3 0x100090 poll dhclient 43163 282929 1 0 3 0x80 poll dhclient 84621 320699 0 0 3 0x14200 bored smr 90780 33715 0 0 2 0x14200 zerothread 44517 323939 0 0 3 0x14200 aiodoned aiodoned 45925 157108 0 0 3 0x14200 syncer update 2890 97794 0 0 3 0x14200 cleaner cleaner 48397 321144 0 0 3 0x14200 reaper reaper 68553 294893 0 0 3 0x14200 pgdaemon pagedaemon 81592 506750 0 0 3 0x14200 bored crynlk 72205 317982 0 0 3 0x14200 bored crypto 95151 367983 0 0 3 0x14200 bored viomb 15585 352491 0 0 3 0x40014200 acpi0 acpi0 48151 505442 0 0 3 0x40014200 idle1 54 291727 0 0 3 0x14200 bored softnet 41038 409658 0 0 3 0x14200 bored systqmp 77460 147800 0 0 3 0x14200 bored systq 57907 357270 0 0 3 0x40014200 bored softclock 69425 78754 0 0 3 0x40014200 idle0 1 243647 0 0 3 0x82 wait init 0 0 -1 0 3 0x10200 scheduler swapper ddb{1}> show all locks Process 57343 (syz-executor.0) thread 0xffff800021268d28 (310563) exclusive kernel_lock &kernel_lock r = 1 (0xffffffff827d4278) #0 witness_lock+0x4b0 stacktrace_save sys/sys/stacktrace.h:36 [inline] #0 witness_lock+0x4b0 sys/kern/subr_witness.c:1182 #1 syscall+0x439 mi_syscall sys/sys/syscall_mi.h:93 [inline] #1 syscall+0x439 sys/arch/amd64/amd64/trap.c:587 #2 Xsyscall+0x128 ddb{1}> show malloc Type InUse MemUse HighUse Limit Requests Type Lim devbuf 10123 6481K 6496K 78643K 11764 0 pcb 13 8K 8K 78643K 13 0 rtable 105 3K 3K 78643K 195 0 ifaddr 44 10K 10K 78643K 45 0 counters 44 34K 34K 78643K 44 0 ioctlops 0 0K 4K 78643K 1469 0 iov 0 0K 0K 78643K 4 0 mount 1 1K 1K 78643K 1 0 log 0 0K 0K 78643K 1 0 vnodes 1217 77K 77K 78643K 1222 0 UFS quota 1 32K 32K 78643K 1 0 UFS mount 5 36K 36K 78643K 5 0 shm 2 1K 5K 78643K 3 0 VM map 2 1K 1K 78643K 2 0 sem 10 0K 0K 78643K 16 0 dirhash 12 2K 2K 78643K 12 0 ACPI 1697 195K 286K 78643K 12598 0 file desc 5 13K 25K 78643K 457 0 sigio 0 0K 0K 78643K 25 0 proc 59 63K 95K 78643K 437 0 subproc 32 2K 2K 78643K 34 0 NFS srvsock 1 0K 0K 78643K 1 0 NFS daemon 1 16K 16K 78643K 1 0 in_multi 33 2K 2K 78643K 33 0 ether_multi 1 0K 0K 78643K 1 0 ISOFS mount 1 32K 32K 78643K 1 0 MSDOSFS mount 1 16K 16K 78643K 1 0 ttys 43 201K 201K 78643K 43 0 exec 0 0K 2K 78643K 354 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 255 32K 32K 78643K 7089 0 UVM aobj 3 2K 2K 78643K 3 0 memdesc 1 4K 4K 78643K 1 0 crypto data 1 1K 1K 78643K 1 0 NDP 6 0K 0K 78643K 10 0 temp 66 3975K 4039K 78643K 2908 0 kqueue 5 5K 8K 78643K 9 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 plcache 128 22 0 0 1 0 1 1 0 8 0 rtpcb 120 19 0 17 1 0 1 1 0 8 0 rtentry 112 45 0 1 2 0 2 2 0 8 0 unpcb 120 53 0 43 1 0 1 1 0 8 0 syncache 296 4 0 4 1 1 0 1 0 8 0 tcpqe 32 1041 0 1041 1 1 0 1 0 8 0 tcpcb 736 50 0 44 1 0 1 1 0 8 0 arp 120 6 0 0 1 0 1 1 0 8 0 inpcb 304 84 0 78 1 0 1 1 0 8 0 nd6 48 6 0 0 1 0 1 1 0 8 0 kcovpl 48 2 0 0 1 0 1 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 pfstitem 24 12 0 8 1 0 1 1 0 8 0 pfstkey 112 12 0 8 1 0 1 1 0 8 0 pfstate 320 12 0 8 1 0 1 1 0 8 0 pfrule 1360 21 0 16 2 1 1 2 0 8 0 art_heap8 4096 1 0 0 1 0 1 1 0 8 0 art_heap4 256 189 0 0 12 0 12 12 0 8 0 art_table 32 190 0 0 2 0 2 2 0 8 0 art_node 16 44 0 4 1 0 1 1 0 8 0 semupl 112 2 0 2 1 0 1 1 0 8 1 semapl 112 10 0 2 1 0 1 1 0 8 0 dirhash 1024 17 0 0 3 0 3 3 0 8 0 dino2pl 256 1931 0 525 89 0 89 89 0 8 1 ffsino 272 1931 0 525 94 0 94 94 0 8 0 nchpl 144 2945 0 1329 62 1 61 61 0 8 1 uvmvnodes 72 1975 0 0 36 0 36 36 0 8 0 vnodes 224 1975 0 0 117 0 117 117 0 8 0 namei 1024 8036 0 8036 2 1 1 1 0 8 1 percpumem 16 34 0 0 1 0 1 1 0 8 0 scxspl 216 7702 0 7702 9 8 1 8 0 8 1 plimitpl 152 15 0 7 1 0 1 1 0 8 0 sigapl 424 673 0 640 4 0 4 4 0 8 0 futexpl 56 4280 0 4280 1 0 1 1 0 8 1 knotepl 112 40 0 0 2 0 2 2 0 8 0 kqueuepl 216 540 0 535 1 0 1 1 0 8 0 pipepl 336 151 0 140 3 1 2 2 0 8 1 fdescpl 496 656 0 640 5 2 3 3 0 8 0 filepl 152 3822 0 3718 6 1 5 5 0 8 1 lockfpl 104 143 0 142 1 0 1 1 0 8 0 lockfspl 48 70 0 69 1 0 1 1 0 8 0 sessionpl 144 18 0 7 1 0 1 1 0 8 0 pgrppl 48 20 0 9 1 0 1 1 0 8 0 ucredpl 96 71 0 62 1 0 1 1 0 8 0 zombiepl 144 640 0 639 2 1 1 1 0 8 0 processpl 1080 673 0 639 3 0 3 3 0 8 0 procpl 672 1232 0 1189 5 1 4 4 0 8 0 sosppl 168 2 0 2 1 0 1 1 0 8 1 sockpl 480 156 0 138 5 1 4 4 0 8 1 mcl64k 65536 1 0 0 1 0 1 1 0 8 0 mcl12k 12288 2 0 0 1 0 1 1 0 8 0 mcl9k 9216 1 0 0 1 0 1 1 0 8 0 mcl8k 8192 4 0 0 1 0 1 1 0 8 0 mcl4k 4096 6 0 0 1 0 1 1 0 8 0 mcl2k2 2112 1 0 0 1 0 1 1 0 8 0 mcl2k 2048 277 0 0 34 0 34 34 0 8 0 mtagpl 96 2 0 0 1 0 1 1 0 8 0 mbufpl 256 301 0 0 19 0 19 19 0 8 0 bufpl 280 3855 0 149 265 0 265 265 0 8 0 anonpl 24 167262 0 140802 168 4 164 165 0 186 0 amapchunkpl 152 16414 0 15467 41 2 39 39 0 158 0 amappl16 200 1638 0 790 46 1 45 45 0 8 0 amappl15 192 285 0 279 1 0 1 1 0 8 0 amappl14 184 215 0 213 2 1 1 1 0 8 0 amappl13 176 29 0 26 1 0 1 1 0 8 0 amappl12 168 6 0 2 1 0 1 1 0 8 0 amappl11 160 49 0 36 1 0 1 1 0 8 0 amappl10 152 45 0 35 1 0 1 1 0 8 0 amappl9 144 239 0 239 2 2 0 1 0 8 0 amappl8 136 352 0 302 2 0 2 2 0 8 0 amappl7 128 65 0 57 1 0 1 1 0 8 0 amappl6 120 115 0 99 1 0 1 1 0 8 0 amappl5 112 344 0 331 1 0 1 1 0 8 0 amappl4 104 738 0 707 1 0 1 1 0 8 0 amappl3 96 121 0 110 1 0 1 1 0 8 0 amappl2 88 775 0 731 4 2 2 2 0 8 1 amappl1 80 13926 0 13501 13 3 10 12 0 8 0 amappl 88 6674 0 6480 5 0 5 5 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 2 0 0 1 0 1 1 0 8 0 uaddrrnd 24 656 0 640 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 656 0 640 1 0 1 1 0 8 0 vmmpekpl 168 8140 0 8108 2 0 2 2 0 8 0 vmmpepl 168 73074 0 70900 127 27 100 127 0 357 1 vmsppl 368 655 0 640 2 0 2 2 0 8 0 rwobjpl 56 15913 0 14300 27 3 24 24 0 8 1 pdppl 4096 1319 0 1280 63 22 41 45 0 8 2 pvpl 32 454470 0 424386 259 8 251 255 0 265 5 pmappl 232 655 0 640 2 1 1 2 0 8 0 extentpl 40 58 0 40 1 0 1 1 0 8 0 phpool 112 331 0 27 9 0 9 9 0 8 0 ddb{1}> machine ddbcpu 0 Stopped at x86_ipi_db+0x1a: addq $0x8,%rsp x86_ipi_db(ffffffff8275cff0) at x86_ipi_db+0x1a sys/arch/amd64/amd64/db_interface.c:353 x86_ipi_handler() at x86_ipi_handler+0xb7 sys/arch/amd64/amd64/ipi.c:106 Xresume_lapic_ipi() at Xresume_lapic_ipi+0x23 __sanitizer_cov_trace_pc() at __sanitizer_cov_trace_pc+0x7 sys/dev/kcov.c:139 clock_gettime(ffff8000212682a8,0,ffff8000244c13c8) at clock_gettime+0x9d sys/kern/kern_time.c:116 sys_clock_gettime(ffff8000212682a8,ffff8000244c1430,ffff8000244c1480) at sys_clock_gettime+0x4c sys/kern/kern_time.c:165 syscall(ffff8000244c1500) at syscall+0x5bf mi_syscall sys/sys/syscall_mi.h:102 [inline] syscall(ffff8000244c1500) at syscall+0x5bf sys/arch/amd64/amd64/trap.c:587 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x7f7fffff3a00, count: 7 ddb{0}> trace x86_ipi_db(ffffffff8275cff0) at x86_ipi_db+0x1a sys/arch/amd64/amd64/db_interface.c:353 x86_ipi_handler() at x86_ipi_handler+0xb7 sys/arch/amd64/amd64/ipi.c:106 Xresume_lapic_ipi() at Xresume_lapic_ipi+0x23 __sanitizer_cov_trace_pc() at __sanitizer_cov_trace_pc+0x7 sys/dev/kcov.c:139 clock_gettime(ffff8000212682a8,0,ffff8000244c13c8) at clock_gettime+0x9d sys/kern/kern_time.c:116 sys_clock_gettime(ffff8000212682a8,ffff8000244c1430,ffff8000244c1480) at sys_clock_gettime+0x4c sys/kern/kern_time.c:165 syscall(ffff8000244c1500) at syscall+0x5bf mi_syscall sys/sys/syscall_mi.h:102 [inline] syscall(ffff8000244c1500) at syscall+0x5bf sys/arch/amd64/amd64/trap.c:587 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x7f7fffff3a00, count: -8 ddb{0}> machine ddbcpu 1 Stopped at db_enter+0x18: addq $0x8,%rsp db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:399 panic(ffffffff82460c20) at panic+0x177 sys/kern/subr_prf.c:202 knote_dequeue(fffffd8065ff7e08) at knote_dequeue+0x12b sys/kern/kern_event.c:1860 filt_timermodify(ffff8000244ef2e0,fffffd8065ff7e08) at filt_timermodify+0x6f sys/kern/kern_event.c:479 kqueue_register(fffffd806e8ae5e8,ffff8000244ef2e0,ffff800021268d28) at kqueue_register+0xa89 filter_modify sys/kern/kern_event.c:662 [inline] kqueue_register(fffffd806e8ae5e8,ffff8000244ef2e0,ffff800021268d28) at kqueue_register+0xa89 sys/kern/kern_event.c:1125 sys_kevent(ffff800021268d28,ffff8000244ef598,ffff8000244ef5e0) at sys_kevent+0x214 sys/kern/kern_event.c:887 syscall(ffff8000244ef660) at syscall+0x5bf mi_syscall sys/sys/syscall_mi.h:102 [inline] syscall(ffff8000244ef660) at syscall+0x5bf sys/arch/amd64/amd64/trap.c:587 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x81b588b5b30, count: 7 ddb{1}> trace db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:399 panic(ffffffff82460c20) at panic+0x177 sys/kern/subr_prf.c:202 knote_dequeue(fffffd8065ff7e08) at knote_dequeue+0x12b sys/kern/kern_event.c:1860 filt_timermodify(ffff8000244ef2e0,fffffd8065ff7e08) at filt_timermodify+0x6f sys/kern/kern_event.c:479 kqueue_register(fffffd806e8ae5e8,ffff8000244ef2e0,ffff800021268d28) at kqueue_register+0xa89 filter_modify sys/kern/kern_event.c:662 [inline] kqueue_register(fffffd806e8ae5e8,ffff8000244ef2e0,ffff800021268d28) at kqueue_register+0xa89 sys/kern/kern_event.c:1125 sys_kevent(ffff800021268d28,ffff8000244ef598,ffff8000244ef5e0) at sys_kevent+0x214 sys/kern/kern_event.c:887 syscall(ffff8000244ef660) at syscall+0x5bf mi_syscall sys/sys/syscall_mi.h:102 [inline] syscall(ffff8000244ef660) at syscall+0x5bf sys/arch/amd64/amd64/trap.c:587 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x81b588b5b30, count: -8