panic: timeout_add: to_ticks (-228033415) < 0 Stopped at db_enter+0x18: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND 127640 38481 0 0 0 0 syz-executor.1 *473386 38481 0 0 0x4000000 1K syz-executor.1 db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:399 panic() at panic+0x174 sys/kern/subr_prf.c:208 timeout_add(ffff80000066d060,f2687c79) at timeout_add+0x194 sys/kern/kern_timeout.c:190 pcppi_bell(ffff80000066d000,70773cd0,f2687c79,1) at pcppi_bell+0x2a0 sys/dev/isa/pcppi.c:234 spkrioctl(1b00,20005302,ffff800020c1d120,2,ffff800020b42720) at spkrioctl+0x230 tone sys/dev/isa/spkr.c:89 [inline] spkrioctl(1b00,20005302,ffff800020c1d120,2,ffff800020b42720) at spkrioctl+0x230 sys/dev/isa/spkr.c:503 VOP_IOCTL(fffffd8064c06260,20005302,ffff800020c1d120,2,fffffd807f7c7a80,ffff800020b42720) at VOP_IOCTL+0x9a sys/kern/vfs_vops.c:290 vn_ioctl(fffffd8066fdde58,20005302,ffff800020c1d120,ffff800020b42720) at vn_ioctl+0xc9 sys/kern/vfs_vnops.c:512 sys_ioctl(ffff800020b42720,ffff800020c1d268,ffff800020c1d250) at sys_ioctl+0x646 syscall(ffff800020c1d300) at syscall+0x5ac mi_syscall sys/sys/syscall_mi.h:99 [inline] syscall(ffff800020c1d300) at syscall+0x5ac sys/arch/amd64/amd64/trap.c:574 Xsyscall(6,0,ffffffffffffff88,0,3,3901f368010) at Xsyscall+0x128 end of kernel end trace frame: 0x3929cc704f0, count: 5 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 timeout_add: to_ticks (-228033415) < 0 ddb{1}> trace db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:399 panic() at panic+0x174 sys/kern/subr_prf.c:208 timeout_add(ffff80000066d060,f2687c79) at timeout_add+0x194 sys/kern/kern_timeout.c:190 pcppi_bell(ffff80000066d000,70773cd0,f2687c79,1) at pcppi_bell+0x2a0 sys/dev/isa/pcppi.c:234 spkrioctl(1b00,20005302,ffff800020c1d120,2,ffff800020b42720) at spkrioctl+0x230 tone sys/dev/isa/spkr.c:89 [inline] spkrioctl(1b00,20005302,ffff800020c1d120,2,ffff800020b42720) at spkrioctl+0x230 sys/dev/isa/spkr.c:503 VOP_IOCTL(fffffd8064c06260,20005302,ffff800020c1d120,2,fffffd807f7c7a80,ffff800020b42720) at VOP_IOCTL+0x9a sys/kern/vfs_vops.c:290 vn_ioctl(fffffd8066fdde58,20005302,ffff800020c1d120,ffff800020b42720) at vn_ioctl+0xc9 sys/kern/vfs_vnops.c:512 sys_ioctl(ffff800020b42720,ffff800020c1d268,ffff800020c1d250) at sys_ioctl+0x646 syscall(ffff800020c1d300) at syscall+0x5ac mi_syscall sys/sys/syscall_mi.h:99 [inline] syscall(ffff800020c1d300) at syscall+0x5ac sys/arch/amd64/amd64/trap.c:574 Xsyscall(6,0,ffffffffffffff88,0,3,3901f368010) at Xsyscall+0x128 end of kernel end trace frame: 0x3929cc704f0, count: -10 ddb{1}> show registers rdi 0xffffffff816f6437 db_enter+0x17 rsi 0x178b __ALIGN_SIZE+0x78b rbp 0xffff800020c1cd40 rbx 0xffff800020c1cdf0 rdx 0x178c __ALIGN_SIZE+0x78c rcx 0xffff800002b49000 rax 0xffff800002b49000 r8 0xffffffff81555b63 kprintf+0x183 r9 0x1 r10 0x25 r11 0xfb1cc6aed8ca0a3f r12 0x3000000008 r13 0xffff800020c1cd50 r14 0x100 r15 0x1 rip 0xffffffff816f6438 db_enter+0x18 cs 0x8 rflags 0x246 rsp 0xffff800020c1cd30 ss 0x10 db_enter+0x18: addq $0x8,%rsp ddb{1}> show proc PROC (syz-executor.1) pid=473386 stat=onproc flags process=0 proc=4000000 pri=21, usrpri=70, nice=20 forw=0xffffffffffffffff, list=0xffff800020b432d8,0xffff800020b42e38 process=0xffff800020b45708 user=0xffff800020c18000, vmspace=0xfffffd807f00c5a0 estcpu=20, cpticks=0, pctcpu=0.0 user=0, sys=0, intr=0 ddb{1}> ps PID TID PPID UID S FLAGS WAIT COMMAND 38481 127640 75801 0 7 0 syz-executor.1 *38481 473386 75801 0 7 0x4000000 syz-executor.1 38481 219209 75801 0 3 0x4000080 bell syz-executor.1 38481 330531 75801 0 3 0x4000080 fsleep syz-executor.1 62337 489737 0 0 3 0x14200 bored sosplice 75801 285122 55926 0 3 0x82 nanosleep syz-executor.1 82539 65702 55926 0 3 0x82 piperd syz-executor.0 55926 172200 39466 0 3 0x82 kqread syz-fuzzer 55926 412807 39466 0 3 0x4000082 thrsleep syz-fuzzer 55926 308941 39466 0 3 0x4000082 thrsleep syz-fuzzer 55926 492631 39466 0 3 0x4000082 thrsleep syz-fuzzer 55926 523170 39466 0 3 0x4000082 thrsleep syz-fuzzer 55926 483830 39466 0 3 0x4000082 thrsleep syz-fuzzer 55926 358810 39466 0 3 0x4000082 thrsleep syz-fuzzer 55926 345316 39466 0 3 0x4000082 thrsleep syz-fuzzer 55926 57914 39466 0 3 0x4000082 thrsleep syz-fuzzer 55926 480716 39466 0 3 0x4000082 thrsleep syz-fuzzer 39466 136824 52469 0 3 0x10008a pause ksh 52469 264460 9795 0 3 0x92 select sshd 60642 410485 1 0 3 0x100083 ttyin getty 9795 148882 1 0 3 0x80 select sshd 15850 196483 50299 73 3 0x100090 kqread syslogd 50299 399033 1 0 3 0x100082 netio syslogd 89073 275850 1 77 3 0x100090 poll dhclient 11284 291830 1 0 3 0x80 poll dhclient 17866 6109 0 0 3 0x14200 pgzero zerothread 96584 338284 0 0 3 0x14200 aiodoned aiodoned 95988 169479 0 0 3 0x14200 syncer update 33114 77573 0 0 3 0x14200 cleaner cleaner 84371 199679 0 0 3 0x14200 reaper reaper 80601 499650 0 0 3 0x14200 pgdaemon pagedaemon 37495 151491 0 0 3 0x14200 bored crynlk 67057 461527 0 0 3 0x14200 bored crypto 92886 511739 0 0 3 0x40014200 acpi0 acpi0 69677 225957 0 0 3 0x40014200 idle1 60251 213242 0 0 3 0x14200 bored softnet 98925 129374 0 0 3 0x14200 bored systqmp 22913 357527 0 0 3 0x14200 bored systq 33719 246968 0 0 3 0x40014200 bored softclock 24194 404264 0 0 3 0x40014200 idle0 1 30940 0 0 3 0x82 wait init 0 0 -1 0 3 0x10200 scheduler swapper ddb{1}> show all locks Process 38481 (syz-executor.1) thread 0xffff800020b42720 (473386) exclusive kernel_lock &kernel_lock r = 0 (0xffffffff823174f8) locked @ /syzkaller/managers/multicore/kernel/sys/kern/sched_bsd.c:436 #0 witness_lock+0x58a sys/kern/subr_witness.c:1205 #1 ___mp_acquire_count+0x67 sys/kern/kern_lock.c:231 #2 mi_switch+0x3b0 sys/kern/sched_bsd.c:436 #3 sleep_finish+0x110 sys/kern/kern_synch.c:312 #4 sleep_finish_all+0x34 sleep_finish_timeout sys/kern/kern_synch.c:336 [inline] #4 sleep_finish_all+0x34 sys/kern/kern_synch.c:157 #5 tsleep+0x1bc #6 pcppi_bell+0x37e sys/dev/isa/pcppi.c:237 #7 spkrioctl+0x230 tone sys/dev/isa/spkr.c:89 [inline] #7 spkrioctl+0x230 sys/dev/isa/spkr.c:503 #8 VOP_IOCTL+0x9a sys/kern/vfs_vops.c:290 #9 vn_ioctl+0xc9 sys/kern/vfs_vnops.c:512 #10 sys_ioctl+0x646 #11 syscall+0x5ac mi_syscall sys/sys/syscall_mi.h:99 [inline] #11 syscall+0x5ac sys/arch/amd64/amd64/trap.c:574 #12 Xsyscall+0x128 ddb{1}> show malloc Type InUse MemUse HighUse Limit Requests Type Lim Kern Lim devbuf 9480 6336K 6344K 78643K 10641 0 0 pcb 23 9K 10K 78643K 176 0 0 rtable 100 3K 4K 78643K 213 0 0 ifaddr 43 11K 12K 78643K 66 0 0 counters 39 33K 33K 78643K 39 0 0 ioctlops 0 0K 2K 78643K 15 0 0 iov 0 0K 16K 78643K 17 0 0 mount 1 1K 1K 78643K 1 0 0 vnodes 1196 75K 75K 78643K 1308 0 0 UFS quota 1 32K 32K 78643K 1 0 0 UFS mount 5 36K 36K 78643K 5 0 0 shm 2 1K 5K 78643K 6 0 0 VM map 2 1K 1K 78643K 2 0 0 sem 12 0K 1K 78643K 16 0 0 dirhash 12 2K 2K 78643K 12 0 0 ACPI 1792 194K 288K 78643K 12592 0 0 file desc 5 13K 25K 78643K 217 0 0 proc 42 38K 58K 78643K 300 0 0 subproc 64 65538K 67586K 78643K 68 0 0 NFS srvsock 1 0K 0K 78643K 1 0 0 NFS daemon 1 16K 16K 78643K 1 0 0 ip_moptions 0 0K 0K 78643K 21 0 0 in_multi 33 2K 2K 78643K 34 0 0 ether_multi 1 0K 0K 78643K 1 0 0 ISOFS mount 1 32K 32K 78643K 1 0 0 MSDOSFS mount 1 16K 16K 78643K 1 0 0 ttys 66 291K 291K 78643K 66 0 0 exec 0 0K 1K 78643K 182 0 0 pagedep 1 8K 8K 78643K 1 0 0 inodedep 1 32K 32K 78643K 1 0 0 newblk 1 0K 0K 78643K 1 0 0 VM swap 7 26K 26K 78643K 7 0 0 UVM amap 81 20K 21K 78643K 1439 0 0 UVM aobj 8 2K 2K 78643K 8 0 0 memdesc 1 4K 4K 78643K 1 0 0 crypto data 1 1K 1K 78643K 1 0 0 ip6_options 0 0K 0K 78643K 6 0 0 NDP 7 0K 0K 78643K 17 0 0 temp 108 2356K 2423K 78643K 3339 0 0 kqueue 0 0K 0K 78643K 10 0 0 SYN cache 2 16K 16K 78643K 2 0 0 ddb{1}> show all pools Name Size Requests Fail Releases Pgreq Pgrel Npage Hiwat Minpg Maxpg Idle arp 64 4 0 0 1 0 1 1 0 8 0 inpcbpl 280 110 0 103 1 0 1 1 0 8 0 plimitpl 152 17 0 10 1 0 1 1 0 8 0 plcache 128 20 0 0 1 0 1 1 0 8 0 rtentry 112 41 0 1 2 0 2 2 0 8 0 syncache 264 4 0 4 1 1 0 1 0 8 0 tcpcb 544 30 0 26 1 0 1 1 0 8 0 nd6 48 4 0 0 1 0 1 1 0 8 0 ppxss 1128 5 0 5 2 1 1 1 0 8 1 art_heap8 4096 1 0 0 1 0 1 1 0 8 0 art_heap4 256 186 0 0 12 0 12 12 0 8 0 art_table 32 187 0 0 2 0 2 2 0 8 0 art_node 16 40 0 6 1 0 1 1 0 8 0 sysvmsgpl 40 10 0 4 1 0 1 1 0 8 0 semapl 112 14 0 4 1 0 1 1 0 8 0 shmpl 112 6 0 0 1 0 1 1 0 8 0 dirhash 1024 17 0 0 3 0 3 3 0 8 0 dino1pl 128 1804 0 396 46 0 46 46 0 8 0 ffsino 272 1804 0 396 95 0 95 95 0 8 0 nchpl 144 2330 0 720 61 0 61 61 0 8 0 uvmvnodes 72 1860 0 0 34 0 34 34 0 8 0 vnodes 200 1860 0 0 98 0 98 98 0 8 0 namei 1024 6071 0 6071 1 0 1 1 0 8 1 percpumem 16 30 0 0 1 0 1 1 0 8 0 scsiplug 64 1 0 1 1 1 0 1 0 8 0 scxspl 192 6523 0 6523 7 6 1 6 0 8 1 sigapl 432 385 0 372 2 0 2 2 0 8 0 futexpl 56 2169 0 2168 1 0 1 1 0 8 0 knotepl 112 117 0 90 3 2 1 2 0 8 0 kqueuepl 104 64 0 62 1 0 1 1 0 8 0 pipepl 112 244 0 225 2 0 2 2 0 8 1 fdescpl 488 386 0 372 3 1 2 3 0 8 0 filepl 152 2100 0 2002 5 0 5 5 0 8 1 lockfpl 104 100 0 98 2 1 1 1 0 8 0 lockfspl 32 128 0 126 2 1 1 1 0 8 0 sessionpl 112 17 0 7 1 0 1 1 0 8 0 pgrppl 48 17 0 7 1 0 1 1 0 8 0 ucredpl 96 358 0 351 1 0 1 1 0 8 0 zombiepl 144 372 0 372 1 0 1 1 0 8 1 processpl 840 401 0 372 4 0 4 4 0 8 0 procpl 600 866 0 825 4 0 4 4 0 8 0 sosppl 128 4 0 4 2 2 0 1 0 8 0 sockpl 384 251 0 234 3 0 3 3 0 8 1 mcl12k 12288 1 0 0 1 0 1 1 0 8 0 mcl9k 9216 2 0 0 1 0 1 1 0 8 0 mcl8k 8192 1 0 0 1 0 1 1 0 8 0 mcl4k 4096 4 0 0 1 0 1 1 0 8 0 mcl2k2 2112 2 0 0 1 0 1 1 0 8 0 mcl2k 2048 109 0 0 13 0 13 13 0 8 0 mtagpl 80 2 0 0 1 0 1 1 0 8 0 mbufpl 256 123 0 0 8 0 8 8 0 8 0 bufpl 256 5442 0 1018 277 0 277 277 0 8 0 anonpl 16 43952 0 36033 48 3 45 47 0 125 11 amapchunkpl 152 1996 0 1907 9 5 4 9 0 158 0 amappl16 192 1574 0 1155 32 4 28 32 0 8 6 amappl15 184 8 0 6 2 1 1 1 0 8 0 amappl14 176 7 0 6 2 1 1 1 0 8 0 amappl13 168 131 0 127 1 0 1 1 0 8 0 amappl12 160 100 0 96 2 1 1 1 0 8 0 amappl11 152 178 0 169 1 0 1 1 0 8 0 amappl10 144 58 0 56 1 0 1 1 0 8 0 amappl9 136 91 0 88 1 0 1 1 0 8 0 amappl8 128 224 0 207 1 0 1 1 0 8 0 amappl7 120 144 0 139 1 0 1 1 0 8 0 amappl6 112 54 0 48 1 0 1 1 0 8 0 amappl5 104 646 0 635 1 0 1 1 0 8 0 amappl4 96 263 0 242 2 1 1 2 0 8 0 amappl3 88 138 0 131 1 0 1 1 0 8 0 amappl2 80 2619 0 2564 2 0 2 2 0 8 0 amappl1 72 16523 0 16114 23 13 10 19 0 8 0 amappl 72 1073 0 1038 1 0 1 1 0 75 0 dma4096 4096 1 0 1 1 1 0 1 0 8 0 dma256 256 6 0 6 1 1 0 1 0 8 0 dma64 64 259 0 259 1 1 0 1 0 8 0 dma32 32 7 0 7 1 1 0 1 0 8 0 dma16 16 17 0 17 1 1 0 1 0 8 0 aobjpl 64 7 0 0 1 0 1 1 0 8 0 uaddrrnd 24 386 0 372 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 386 0 372 1 0 1 1 0 8 0 vmmpekpl 168 6948 0 6925 2 0 2 2 0 8 0 vmmpepl 168 50342 0 48994 83 13 70 72 0 357 7 vmsppl 360 385 0 372 2 0 2 2 0 8 0 pdppl 4096 779 0 744 6 1 5 6 0 8 0 pvpl 32 167002 0 156114 137 9 128 130 0 265 38 pmappl 224 385 0 372 1 0 1 1 0 8 0 extentpl 40 39 0 25 1 0 1 1 0 8 0 phpool 112 421 0 3 12 0 12 12 0 8 0