panic: mutex 0xfffffd806e9a8438 not held in knote_dequeue Stopped at db_enter+0x18: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND 108677 26694 32767 0x10 0 1 syz-executor.0 *500487 26428 32767 0x10 0x4000000 0K syz-executor.1 db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:399 panic(ffffffff8246025e) at panic+0x177 sys/kern/subr_prf.c:202 knote_dequeue(fffffd806e8bae70) at knote_dequeue+0x12b sys/kern/kern_event.c:1860 filt_timermodify(ffff8000256e2a00,fffffd806e8bae70) at filt_timermodify+0x6f sys/kern/kern_event.c:479 kqueue_register(fffffd806e9a8438,ffff8000256e2a00,ffff8000ffff4d20) at kqueue_register+0xa89 filter_modify sys/kern/kern_event.c:662 [inline] kqueue_register(fffffd806e9a8438,ffff8000256e2a00,ffff8000ffff4d20) at kqueue_register+0xa89 sys/kern/kern_event.c:1125 sys_kevent(ffff8000ffff4d20,ffff8000256e2c18,ffff8000256e2c60) at sys_kevent+0x214 sys/kern/kern_event.c:887 syscall(ffff8000256e2ce0) at syscall+0x5bf mi_syscall sys/sys/syscall_mi.h:102 [inline] syscall(ffff8000256e2ce0) at syscall+0x5bf sys/arch/amd64/amd64/trap.c:587 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0xcae57da7f00, 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{0}> ddb{0}> set $lines = 0 ddb{0}> set $maxwidth = 0 ddb{0}> show panic *cpu0: mutex 0xfffffd806e9a8438 not held in knote_dequeue ddb{0}> trace db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:399 panic(ffffffff8246025e) at panic+0x177 sys/kern/subr_prf.c:202 knote_dequeue(fffffd806e8bae70) at knote_dequeue+0x12b sys/kern/kern_event.c:1860 filt_timermodify(ffff8000256e2a00,fffffd806e8bae70) at filt_timermodify+0x6f sys/kern/kern_event.c:479 kqueue_register(fffffd806e9a8438,ffff8000256e2a00,ffff8000ffff4d20) at kqueue_register+0xa89 filter_modify sys/kern/kern_event.c:662 [inline] kqueue_register(fffffd806e9a8438,ffff8000256e2a00,ffff8000ffff4d20) at kqueue_register+0xa89 sys/kern/kern_event.c:1125 sys_kevent(ffff8000ffff4d20,ffff8000256e2c18,ffff8000256e2c60) at sys_kevent+0x214 sys/kern/kern_event.c:887 syscall(ffff8000256e2ce0) at syscall+0x5bf mi_syscall sys/sys/syscall_mi.h:102 [inline] syscall(ffff8000256e2ce0) at syscall+0x5bf sys/arch/amd64/amd64/trap.c:587 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0xcae57da7f00, count: -8 ddb{0}> show registers rdi 0 rsi 0x1 rbp 0xffff8000256e2750 rbx 0xffffffff8270abf7 cpu_info_full_primary+0x2bf7 rdx 0x8b rcx 0x2 rax 0x3a r8 0xffffffff81bb3f14 kprintf+0x144 r9 0x1 r10 0x2dbd2fdf35cdac3e r11 0x5ba5f17b2c04dca1 r12 0xffffffff8270a9f8 cpu_info_full_primary+0x29f8 r13 0 r14 0 r15 0x1 rip 0xffffffff81b43698 db_enter+0x18 cs 0x8 rflags 0x246 rsp 0xffff8000256e2740 ss 0x10 db_enter+0x18: addq $0x8,%rsp ddb{0}> show proc PROC (syz-executor.1) pid=500487 stat=onproc flags process=10 proc=4000000 pri=32, usrpri=74, nice=20 forw=0xffffffffffffffff, list=0xffff8000ffff4000,0xffffffff828f5570 process=0xffff8000ffff3b28 user=0xffff8000256dd000, vmspace=0xfffffd807f0098a0 estcpu=36, cpticks=0, pctcpu=0.0 user=0, sys=0, intr=0 ddb{0}> ps PID TID PPID UID S FLAGS WAIT COMMAND 26694 108677 8537 32767 7 0x10 syz-executor.0 26694 306494 8537 32767 3 0x4000090 kqread syz-executor.0 26428 475258 19940 32767 2 0x10 syz-executor.1 *26428 500487 19940 32767 7 0x4000010 syz-executor.1 8537 86757 33419 32767 3 0x90 nanoslp syz-executor.0 33419 291302 8891 0 3 0x82 wait syz-executor.0 19940 271139 8147 32767 3 0x90 nanoslp syz-executor.1 8147 521569 8891 0 3 0x82 wait syz-executor.1 63331 387600 0 0 3 0x14200 bored sosplice 8891 423304 78415 0 3 0x82 thrsleep syz-fuzzer 8891 58554 78415 0 3 0x4000082 nanoslp syz-fuzzer 8891 482096 78415 0 3 0x4000082 thrsleep syz-fuzzer 8891 4655 78415 0 3 0x4000082 thrsleep syz-fuzzer 8891 73668 78415 0 3 0x4000082 thrsleep syz-fuzzer 8891 493683 78415 0 3 0x4000082 thrsleep syz-fuzzer 8891 465268 78415 0 3 0x4000082 kqread syz-fuzzer 8891 508519 78415 0 3 0x4000082 thrsleep syz-fuzzer 78415 431468 40322 0 3 0x10008a sigsusp ksh 40322 301291 75829 0 3 0x92 select sshd 89993 454921 1 0 3 0x100083 ttyin getty 75829 161072 1 0 3 0x80 select sshd 84870 139883 56525 73 3 0x100090 kqread syslogd 56525 485733 1 0 3 0x100082 netio syslogd 21656 199670 1 77 3 0x100090 poll dhclient 39143 82676 1 0 3 0x80 poll dhclient 14257 422905 0 0 3 0x14200 bored smr 46932 327747 0 0 2 0x14200 zerothread 49206 366307 0 0 3 0x14200 aiodoned aiodoned 61831 183064 0 0 3 0x14200 syncer update 33450 130550 0 0 3 0x14200 cleaner cleaner 82008 18454 0 0 3 0x14200 reaper reaper 77861 246587 0 0 3 0x14200 pgdaemon pagedaemon 16200 273402 0 0 3 0x14200 bored crynlk 37417 142758 0 0 3 0x14200 bored crypto 13661 131025 0 0 3 0x14200 bored viomb 42647 97735 0 0 3 0x40014200 acpi0 acpi0 48815 383065 0 0 3 0x40014200 idle1 8281 355997 0 0 3 0x14200 bored softnet 95207 522317 0 0 3 0x14200 bored systqmp 54707 330655 0 0 3 0x14200 bored systq 31793 147257 0 0 3 0x40014200 bored softclock 12660 506847 0 0 3 0x40014200 idle0 1 469748 0 0 3 0x82 wait init 0 0 -1 0 3 0x10200 scheduler swapper ddb{0}> show all locks Process 26428 (syz-executor.1) thread 0xffff8000ffff4d20 (500487) exclusive kernel_lock &kernel_lock r = 1 (0xffffffff8294f968) #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{0}> show malloc Type InUse MemUse HighUse Limit Requests Type Lim devbuf 10117 6414K 6414K 78643K 11219 0 pcb 13 8K 8K 78643K 13 0 rtable 105 3K 3K 78643K 366 0 ifaddr 39 10K 10K 78643K 68 0 counters 44 34K 34K 78643K 52 0 ioctlops 0 0K 2K 78643K 24 0 iov 0 0K 2K 78643K 18 0 mount 1 1K 1K 78643K 1 0 log 0 0K 0K 78643K 1 0 vnodes 1216 76K 76K 78643K 1306 0 UFS quota 1 32K 32K 78643K 1 0 UFS mount 5 36K 36K 78643K 5 0 shm 2 1K 1K 78643K 2 0 VM map 2 1K 1K 78643K 2 0 sem 12 0K 0K 78643K 542 0 dirhash 12 2K 2K 78643K 12 0 ACPI 1697 195K 286K 78643K 12598 0 file desc 8 25K 33K 78643K 1342 0 proc 48 50K 83K 78643K 677 0 subproc 34 2K 2K 78643K 102 0 NFS srvsock 1 0K 0K 78643K 1 0 NFS daemon 1 16K 16K 78643K 1 0 ip_moptions 0 0K 0K 78643K 85 0 in_multi 33 2K 2K 78643K 112 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 429 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 194 25K 41K 78643K 17168 0 UVM aobj 32 2K 2K 78643K 32 0 memdesc 1 4K 4K 78643K 1 0 crypto data 1 1K 1K 78643K 1 0 ip6_options 0 0K 0K 78643K 108 0 NDP 5 0K 0K 78643K 21 0 temp 101 3985K 4049K 78643K 5032 0 kqueue 8 7K 8K 78643K 33 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 55 0 53 1 0 1 1 0 8 0 rtentry 112 89 0 45 2 0 2 2 0 8 0 unpcb 120 264 0 256 1 0 1 1 0 8 0 syncache 296 38 0 38 3 2 1 1 0 8 1 tcpqe 32 33 0 33 3 3 0 1 0 8 0 tcpcb 736 374 0 355 6 4 2 4 0 8 0 arp 120 14 0 8 1 0 1 1 0 8 0 ipq 40 1 0 1 1 1 0 1 0 8 0 ipqe 40 5 0 5 1 1 0 1 0 8 0 inpcb 304 699 0 693 1 0 1 1 0 8 0 nd6 48 18 0 12 1 0 1 1 0 8 0 kcovpl 48 6 0 4 1 0 1 1 0 8 0 art_heap8 4096 1 0 0 1 0 1 1 0 8 0 art_heap4 256 365 0 176 12 0 12 12 0 8 0 art_table 32 366 0 176 2 0 2 2 0 8 0 art_node 16 88 0 48 1 0 1 1 0 8 0 sysvmsgpl 40 28 0 14 1 0 1 1 0 8 0 semapl 112 540 0 530 1 0 1 1 0 8 0 shmpl 112 29 0 0 1 0 1 1 0 8 0 dirhash 1024 17 0 0 3 0 3 3 0 8 0 dino2pl 256 2870 0 1470 88 0 88 88 0 8 0 ffsino 272 2870 0 1470 94 0 94 94 0 8 0 nchpl 144 4755 0 3159 60 0 60 60 0 8 0 uvmvnodes 72 2981 0 0 55 0 55 55 0 8 0 vnodes 224 2981 0 0 176 0 176 176 0 8 0 namei 1024 11601 0 11601 1 0 1 1 0 8 1 percpumem 16 38 0 4 1 0 1 1 0 8 0 scxspl 216 13442 0 13442 9 8 1 8 0 8 1 plimitpl 152 24 0 15 1 0 1 1 0 8 0 sigapl 424 1518 0 1484 4 0 4 4 0 8 0 futexpl 56 16118 0 16118 1 0 1 1 0 8 1 knotepl 112 40 0 0 2 0 2 2 0 8 0 kqueuepl 216 1444 0 1440 1 0 1 1 0 8 0 pipepl 336 203 0 191 5 3 2 2 0 8 0 fdescpl 496 1501 0 1484 3 0 3 3 0 8 0 filepl 152 6101 0 5999 6 1 5 5 0 8 1 lockfpl 104 223 0 222 1 0 1 1 0 8 0 lockfspl 48 100 0 99 1 0 1 1 0 8 0 sessionpl 144 21 0 11 1 0 1 1 0 8 0 pgrppl 48 26 0 16 1 0 1 1 0 8 0 ucredpl 96 357 0 348 1 0 1 1 0 8 0 zombiepl 144 1484 0 1484 1 0 1 1 0 8 1 processpl 1080 1518 0 1484 4 1 3 3 0 8 0 procpl 672 3078 0 3035 4 0 4 4 0 8 0 sosppl 168 28 0 28 1 1 0 1 0 8 0 sockpl 480 1018 0 1002 4 0 4 4 0 8 1 mcl64k 65536 11 0 0 2 0 2 2 0 8 0 mcl16k 16384 10 0 0 2 0 2 2 0 8 0 mcl12k 12288 6 0 0 1 0 1 1 0 8 0 mcl9k 9216 7 0 0 1 0 1 1 0 8 0 mcl8k 8192 10 0 0 2 0 2 2 0 8 0 mcl4k 4096 15 0 0 2 0 2 2 0 8 0 mcl2k 2048 150 0 0 15 0 15 15 0 8 0 mtagpl 96 1 0 0 1 0 1 1 0 8 0 mbufpl 256 1011 0 0 62 0 62 62 0 8 0 bufpl 280 4864 0 145 338 0 338 338 0 8 0 anonpl 24 409528 0 402497 91 25 66 69 0 186 20 amapchunkpl 152 41552 0 41153 30 13 17 25 0 158 1 amappl16 200 3864 0 3677 24 9 15 23 0 8 5 amappl15 192 63 0 56 1 0 1 1 0 8 0 amappl14 184 12 0 9 1 0 1 1 0 8 0 amappl13 176 100 0 98 1 0 1 1 0 8 0 amappl12 168 140 0 134 1 0 1 1 0 8 0 amappl11 160 40 0 32 1 0 1 1 0 8 0 amappl10 152 1146 0 1139 1 0 1 1 0 8 0 amappl9 144 164 0 162 3 2 1 1 0 8 0 amappl8 136 401 0 345 2 0 2 2 0 8 0 amappl7 128 77 0 70 1 0 1 1 0 8 0 amappl6 120 160 0 138 1 0 1 1 0 8 0 amappl5 112 2568 0 2557 1 0 1 1 0 8 0 amappl4 104 637 0 602 3 1 2 2 0 8 1 amappl3 96 324 0 312 1 0 1 1 0 8 0 amappl2 88 1794 0 1742 2 0 2 2 0 8 0 amappl1 80 26822 0 26410 12 3 9 12 0 8 0 amappl 88 16499 0 16374 4 1 3 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 64 31 0 0 1 0 1 1 0 8 0 uaddrrnd 24 1501 0 1484 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 1501 0 1484 1 0 1 1 0 8 0 vmmpekpl 168 12195 0 12177 2 0 2 2 0 8 0 vmmpepl 168 170690 0 169080 81 4 77 80 0 357 7 vmsppl 368 1500 0 1484 2 0 2 2 0 8 0 rwobjpl 56 32663 0 31825 18 5 13 15 0 8 0 pdppl 4096 3009 0 2968 55 14 41 45 0 8 0 pvpl 32 966053 0 955503 171 47 124 129 0 265 31 pmappl 232 1500 0 1484 2 1 1 2 0 8 0 extentpl 40 58 0 40 1 0 1 1 0 8 0 phpool 112 355 0 23 10 0 10 10 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:399 panic(ffffffff8246025e) at panic+0x177 sys/kern/subr_prf.c:202 knote_dequeue(fffffd806e8bae70) at knote_dequeue+0x12b sys/kern/kern_event.c:1860 filt_timermodify(ffff8000256e2a00,fffffd806e8bae70) at filt_timermodify+0x6f sys/kern/kern_event.c:479 kqueue_register(fffffd806e9a8438,ffff8000256e2a00,ffff8000ffff4d20) at kqueue_register+0xa89 filter_modify sys/kern/kern_event.c:662 [inline] kqueue_register(fffffd806e9a8438,ffff8000256e2a00,ffff8000ffff4d20) at kqueue_register+0xa89 sys/kern/kern_event.c:1125 sys_kevent(ffff8000ffff4d20,ffff8000256e2c18,ffff8000256e2c60) at sys_kevent+0x214 sys/kern/kern_event.c:887 syscall(ffff8000256e2ce0) at syscall+0x5bf mi_syscall sys/sys/syscall_mi.h:102 [inline] syscall(ffff8000256e2ce0) at syscall+0x5bf sys/arch/amd64/amd64/trap.c:587 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0xcae57da7f00, count: -8 ddb{0}> machine ddbcpu 1 Stopped at x86_ipi_db+0x1a: addq $0x8,%rsp x86_ipi_db(ffff800020d58ff0) 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 end of kernel end trace frame: 0x7f7ffffbe870, count: 12 ddb{1}> trace x86_ipi_db(ffff800020d58ff0) 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 end of kernel end trace frame: 0x7f7ffffbe870, count: -3