panic: timeout_add: to_ticks (-2) < 0 Stopped at db_enter+0x18: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND 291584 41100 0 0 0 1 syz-executor.1 *245497 41100 0 0 0x4000000 0K 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,fffffffe) at timeout_add+0x194 sys/kern/kern_timeout.c:190 pcppi_bell(ffff80000066d000,5,fffffffe,1) at pcppi_bell+0x2a0 sys/dev/isa/pcppi.c:234 spkrioctl(1b00,20005302,ffff800020c57360,2,ffff800020b43080) at spkrioctl+0x230 tone sys/dev/isa/spkr.c:89 [inline] spkrioctl(1b00,20005302,ffff800020c57360,2,ffff800020b43080) at spkrioctl+0x230 sys/dev/isa/spkr.c:503 VOP_IOCTL(fffffd8069c619f8,20005302,ffff800020c57360,2,fffffd807f7c7ba0,ffff800020b43080) at VOP_IOCTL+0x9a sys/kern/vfs_vops.c:290 vn_ioctl(fffffd80693a90b0,20005302,ffff800020c57360,ffff800020b43080) at vn_ioctl+0xc9 sys/kern/vfs_vnops.c:512 sys_ioctl(ffff800020b43080,ffff800020c574a8,ffff800020c57490) at sys_ioctl+0x646 syscall(ffff800020c57540) at syscall+0x5ac mi_syscall sys/sys/syscall_mi.h:99 [inline] syscall(ffff800020c57540) at syscall+0x5ac sys/arch/amd64/amd64/trap.c:574 Xsyscall(6,0,ffffffffffffff88,0,3,e077174e010) at Xsyscall+0x128 end of kernel end trace frame: 0xe0a257f7500, 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{0}> ddb{0}> set $lines = 0 ddb{0}> set $maxwidth = 0 ddb{0}> show panic timeout_add: to_ticks (-2) < 0 ddb{0}> trace db_enter() at db_enter+24 panic() at panic+372 timeout_add(ffff80000066d060,fffffffe) at timeout_add+404 pcppi_bell(ffff80000066d000,5,fffffffe,1) at pcppi_bell+672 spkrioctl(1b00,20005302,ffff800020c57360,2,ffff800020b43080) at spkrioctl+560 VOP_IOCTL(fffffd8069c619f8,20005302,ffff800020c57360,2,fffffd807f7c7ba0,ffff800020b43080) at VOP_IOCTL+154 vn_ioctl(fffffd80693a90b0,20005302,ffff800020c57360,ffff800020b43080) at vn_ioctl+201 sys_ioctl(ffff800020b43080,ffff800020c574a8,ffff800020c57490) at sys_ioctl+1606 syscall(ffff800020c57540) at syscall+1452 Xsyscall(6,0,ffffffffffffff88,0,3,e077174e010) at Xsyscall+296 end of kernel end trace frame: 0xe0a257f7500, count: -10 ddb{0}> show registers rdi 18446744071587636919 db_enter+23 rsi 3486 rbp 18446603336771006336 rbx 18446603336771006512 rdx 3487 rcx 18446603336266584064 rax 18446603336266584064 r8 18446744071580452035 kprintf+387 r9 1 r10 37 r11 17552006494967695898 r12 206158430216 r13 18446603336771006352 r14 256 r15 1 rip 18446744071587636920 db_enter+24 cs 8 rflags 582 rsp 18446603336771006320 ss 16 db_enter+24: addq $8,%rsp ddb{0}> show proc PROC (syz-executor.1) pid=245497 stat=onproc flags process=0 proc=4000000 pri=86, usrpri=86, nice=20 forw=0xffffffffffffffff, list=0xffff800020b42bd0,0xffffffff8230d660 process=0xffff800020b44d30 user=0xffff800020c52000, vmspace=0xfffffd807efff168 estcpu=36, cpticks=1, pctcpu=0.0 user=0, sys=1, intr=0 ddb{0}> ps PID TID PPID UID S FLAGS WAIT COMMAND 41100 291584 94084 0 7 0 syz-executor.1 *41100 245497 94084 0 7 0x4000000 syz-executor.1 94084 38682 33092 0 3 0x82 nanosleep syz-executor.1 46838 303638 1 0 3 0x100083 ttyin getty 61653 461405 0 0 3 0x14200 bored sosplice 91357 433981 33092 0 3 0x82 nanosleep syz-executor.0 33092 157287 94046 0 3 0x82 thrsleep syz-fuzzer 33092 334437 94046 0 3 0x4000082 thrsleep syz-fuzzer 33092 133158 94046 0 3 0x4000082 thrsleep syz-fuzzer 33092 278056 94046 0 3 0x4000082 thrsleep syz-fuzzer 33092 328962 94046 0 3 0x4000082 thrsleep syz-fuzzer 33092 85901 94046 0 3 0x4000082 thrsleep syz-fuzzer 33092 294530 94046 0 3 0x4000082 thrsleep syz-fuzzer 33092 326514 94046 0 3 0x4000082 thrsleep syz-fuzzer 33092 407479 94046 0 3 0x4000082 thrsleep syz-fuzzer 33092 244512 94046 0 3 0x4000082 kqread syz-fuzzer 33092 262781 94046 0 3 0x4000082 thrsleep syz-fuzzer 94046 425842 16298 0 3 0x10008a pause ksh 16298 389940 46600 0 3 0x92 select sshd 46600 275105 1 0 3 0x80 select sshd 4922 390256 81506 73 3 0x100090 kqread syslogd 81506 84150 1 0 3 0x100082 netio syslogd 99493 112909 1 77 3 0x100090 poll dhclient 31411 150746 1 0 3 0x80 poll dhclient 53586 26651 0 0 3 0x14200 pgzero zerothread 93118 35244 0 0 3 0x14200 aiodoned aiodoned 95021 119984 0 0 3 0x14200 syncer update 54565 77555 0 0 3 0x14200 cleaner cleaner 80983 142406 0 0 3 0x14200 reaper reaper 91346 191315 0 0 3 0x14200 pgdaemon pagedaemon 3105 81431 0 0 3 0x14200 bored crynlk 52509 430606 0 0 3 0x14200 bored crypto 91226 83826 0 0 3 0x40014200 acpi0 acpi0 64156 250458 0 0 3 0x40014200 idle1 60829 412576 0 0 3 0x14200 bored softnet 83692 407562 0 0 3 0x14200 bored systqmp 86594 116326 0 0 3 0x14200 bored systq 16632 88153 0 0 3 0x40014200 bored softclock 38946 356640 0 0 3 0x40014200 idle0 1 353480 0 0 3 0x82 wait init 0 0 -1 0 3 0x10200 scheduler swapper ddb{0}> show all locks Process 41100 (syz-executor.1) thread 0xffff800020b43080 (245497) exclusive kernel_lock &kernel_lock r = 0 (0xffffffff823220c8) locked @ /syzkaller/managers/multicore/kernel/sys/sys/syscall_mi.h:90 #0 witness_lock+1418 #1 syscall+1151 #2 Xsyscall+296 ddb{0}> show malloc Type InUse MemUse HighUse Limit Requests Type Lim Kern Lim devbuf 9502 6343K 6351K 78643K 10845 0 0 pcb 23 9K 11K 78643K 388 0 0 rtable 100 3K 4K 78643K 308 0 0 ifaddr 49 12K 12K 78643K 102 0 0 counters 39 33K 33K 78643K 39 0 0 ioctlops 0 0K 2K 78643K 18 0 0 iov 0 0K 16K 78643K 37 0 0 mount 1 1K 1K 78643K 1 0 0 vnodes 1217 76K 76K 78643K 1704 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 12 0 0 VM map 2 1K 1K 78643K 2 0 0 sem 12 0K 1K 78643K 88 0 0 dirhash 12 2K 2K 78643K 12 0 0 ACPI 1792 194K 288K 78643K 12592 0 0 file desc 5 13K 25K 78643K 790 0 0 sigio 0 0K 0K 78643K 8 0 0 proc 41 38K 70K 78643K 411 0 0 subproc 64 65538K 67586K 78643K 159 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 92 0 0 in_multi 33 2K 2K 78643K 85 0 0 ether_multi 1 0K 0K 78643K 2 0 0 ISOFS mount 1 32K 32K 78643K 1 0 0 MSDOSFS mount 1 16K 16K 78643K 1 0 0 ttys 72 318K 318K 78643K 72 0 0 exec 0 0K 1K 78643K 326 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 83 20K 29K 78643K 3194 0 0 UVM aobj 42 2K 3K 78643K 48 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 9 0 0 NDP 9 0K 0K 78643K 30 0 0 temp 139 2364K 2429K 78643K 4889 0 0 kqueue 0 0K 0K 78643K 8 0 0 SYN cache 2 16K 16K 78643K 2 0 0 ddb{0}> show all pools Name Size Requests Fail Releases Pgreq Pgrel Npage Hiwat Minpg Maxpg Idle arp 64 6 0 2 1 0 1 1 0 8 0 inpcbpl 280 323 0 316 1 0 1 1 0 8 0 plimitpl 152 26 0 19 1 0 1 1 0 8 0 plcache 128 20 0 0 1 0 1 1 0 8 0 rtentry 112 59 0 19 2 0 2 2 0 8 0 syncache 264 4 0 4 1 1 0 1 0 8 0 tcpcb 544 137 0 133 1 0 1 1 0 8 0 nd6 48 8 0 4 1 0 1 1 0 8 0 ppxss 1128 6 0 6 4 3 1 1 0 8 1 art_heap8 4096 1 0 0 1 0 1 1 0 8 0 art_heap4 256 273 0 85 12 0 12 12 0 8 0 art_table 32 274 0 85 2 0 2 2 0 8 0 art_node 16 58 0 24 1 0 1 1 0 8 0 sysvmsgpl 40 2 0 2 1 1 0 1 0 8 0 semapl 112 84 0 74 1 0 1 1 0 8 0 shmpl 112 46 0 6 2 0 2 2 0 8 0 dirhash 1024 17 0 0 3 0 3 3 0 8 0 dino1pl 128 2957 0 1544 46 0 46 46 0 8 0 ffsino 272 2957 0 1544 95 0 95 95 0 8 0 nchpl 144 4305 0 2692 61 0 61 61 0 8 0 uvmvnodes 72 3113 0 0 57 0 57 57 0 8 0 vnodes 200 3113 0 0 164 0 164 164 0 8 0 namei 1024 11780 0 11780 2 1 1 1 0 8 1 percpumem 16 30 0 0 1 0 1 1 0 8 0 scsiplug 64 4 0 4 2 2 0 1 0 8 0 scxspl 192 11297 0 11297 9 8 1 6 0 8 1 sigapl 432 954 0 941 2 0 2 2 0 8 0 futexpl 56 7443 0 7443 1 0 1 1 0 8 1 knotepl 112 225 0 198 2 1 1 2 0 8 0 kqueuepl 104 196 0 194 1 0 1 1 0 8 0 pipepl 112 552 0 533 3 2 1 2 0 8 0 fdescpl 488 955 0 941 3 1 2 3 0 8 0 filepl 152 5002 0 4907 9 4 5 6 0 8 1 lockfpl 104 333 0 332 4 3 1 1 0 8 0 lockfspl 32 449 0 448 4 3 1 1 0 8 0 sessionpl 112 21 0 11 1 0 1 1 0 8 0 pgrppl 48 25 0 15 1 0 1 1 0 8 0 ucredpl 96 994 0 987 1 0 1 1 0 8 0 zombiepl 144 941 0 940 2 1 1 1 0 8 0 processpl 840 970 0 940 4 0 4 4 0 8 0 procpl 600 2537 0 2496 4 0 4 4 0 8 0 srpgc 64 12 0 12 1 0 1 1 0 8 1 sosppl 128 13 0 13 3 2 1 1 0 8 1 sockpl 384 664 0 647 6 4 2 4 0 8 0 mcl64k 65536 511 0 0 64 4 60 64 0 8 1 mcl16k 16384 2 0 0 1 0 1 1 0 8 0 mcl12k 12288 3 0 0 1 0 1 1 0 8 0 mcl9k 9216 5 0 0 1 0 1 1 0 8 0 mcl8k 8192 3 0 0 1 0 1 1 0 8 0 mcl4k 4096 9 0 0 2 0 2 2 0 8 0 mcl2k2 2112 3 0 0 1 0 1 1 0 8 0 mcl2k 2048 108 0 0 13 0 13 13 0 8 0 mtagpl 80 1 0 0 1 0 1 1 0 8 0 mbufpl 256 628 0 0 38 0 38 38 0 8 0 bufpl 256 6051 0 1023 315 0 315 315 0 8 0 anonpl 16 111345 0 104774 66 31 35 49 0 125 2 amapchunkpl 152 5549 0 5461 17 12 5 9 0 158 1 amappl16 192 5026 0 4626 54 33 21 34 0 8 0 amappl15 184 316 0 316 2 2 0 1 0 8 0 amappl14 176 11 0 7 2 1 1 1 0 8 0 amappl13 168 34 0 31 1 0 1 1 0 8 0 amappl12 160 13 0 10 2 1 1 1 0 8 0 amappl11 152 611 0 600 1 0 1 1 0 8 0 amappl10 144 96 0 94 2 1 1 1 0 8 0 amappl9 136 719 0 714 1 0 1 1 0 8 0 amappl8 128 154 0 135 1 0 1 1 0 8 0 amappl7 120 45 0 38 1 0 1 1 0 8 0 amappl6 112 53 0 46 1 0 1 1 0 8 0 amappl5 104 443 0 431 1 0 1 1 0 8 0 amappl4 96 286 0 261 2 1 1 2 0 8 0 amappl3 88 159 0 153 1 0 1 1 0 8 0 amappl2 80 8235 0 8180 2 0 2 2 0 8 0 amappl1 72 27919 0 27508 24 14 10 19 0 8 0 amappl 72 2777 0 2743 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 47 0 6 1 0 1 1 0 8 0 uaddrrnd 24 955 0 941 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 955 0 941 1 0 1 1 0 8 0 vmmpekpl 168 11091 0 11068 2 0 2 2 0 8 0 vmmpepl 168 109153 0 107814 107 34 73 76 0 357 8 vmsppl 360 954 0 941 2 0 2 2 0 8 0 pdppl 4096 1918 0 1882 6 1 5 6 0 8 0 pvpl 32 323109 0 313544 161 48 113 132 0 265 25 pmappl 224 954 0 941 1 0 1 1 0 8 0 extentpl 40 39 0 25 1 0 1 1 0 8 0 phpool 112 556 0 8 16 0 16 16 0 8 0