panic: thread 0xffff800020b939e0 cannot exit while holding sleeplocks Stopped at db_enter+0x18: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND 10619 62795 0 0x2 0 0 syz-executor0 *218822 94142 0 0x14000 0x200 1 reaper db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:399 panic() at panic+0x16c sys/kern/subr_prf.c:208 witness_thread_exit(145a5976e9cbed99) at witness_thread_exit+0x244 sys/kern/subr_witness.c:1377 reaper(0) at reaper+0x14f sys/kern/kern_exit.c:412 end trace frame: 0x0, count: 11 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}> show panic thread 0xffff800020b939e0 cannot exit while holding sleeplocks ddb{1}> trace db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:399 panic() at panic+0x16c sys/kern/subr_prf.c:208 witness_thread_exit(145a5976e9cbed99) at witness_thread_exit+0x244 sys/kern/subr_witness.c:1377 reaper(0) at reaper+0x14f sys/kern/kern_exit.c:412 end trace frame: 0x0, count: -4 ddb{1}> show registers rdi 0 rsi 0x1 rbp 0xffff800020b67d80 rbx 0xffff800020b67e20 rdx 0xffffffff81f3066d apollo_pio_rec+0x86ea rcx 0 rax 0 r8 0xffffffff817c1934 kprintf+0x174 r9 0x1 r10 0xeb3bc8823ee4de0a r11 0x8223450835f66c30 r12 0x3000000008 r13 0xffff800020b67d90 r14 0x100 r15 0x1 rip 0xffffffff81598c38 db_enter+0x18 cs 0x8 rflags 0x246 rsp 0xffff800020b67d70 ss 0x10 db_enter+0x18: addq $0x8,%rsp ddb{1}> show proc PROC (reaper) pid=218822 stat=onproc flags process=14000 proc=200 pri=4, usrpri=51, nice=20 forw=0xffffffffffffffff, list=0xffff800020b21518,0xffff800020b21c30 process=0xffff800020b5a698 user=0xffff800020b62000, vmspace=0xffffffff822f1200 estcpu=1, cpticks=3, pctcpu=0.25 user=0, sys=2, intr=0 ddb{1}> ps PID TID PPID UID S FLAGS WAIT COMMAND 91427 136240 1 0 3 0x100083 ttyin getty 78244 452178 0 0 3 0x14200 bored sosplice 27416 427522 86036 0 3 0x82 nanosleep syz-executor1 62795 10619 86036 0 7 0x2 syz-executor0 86036 413791 33598 0 3 0x82 thrsleep syz-fuzzer 86036 334319 33598 0 3 0x4000082 nanosleep syz-fuzzer 86036 24843 33598 0 3 0x4000082 thrsleep syz-fuzzer 86036 427305 33598 0 3 0x4000082 thrsleep syz-fuzzer 86036 342651 33598 0 3 0x4000082 kqread syz-fuzzer 86036 327072 33598 0 3 0x4000082 thrsleep syz-fuzzer 86036 480327 33598 0 3 0x4000082 thrsleep syz-fuzzer 86036 19170 33598 0 3 0x4000082 thrsleep syz-fuzzer 86036 201647 33598 0 3 0x4000082 thrsleep syz-fuzzer 86036 43069 33598 0 3 0x4000082 thrsleep syz-fuzzer 33598 247002 72568 0 3 0x10008a pause ksh 72568 384867 40961 0 3 0x92 select sshd 40961 329943 1 0 3 0x80 select sshd 94350 182273 60315 73 3 0x100010 ffs_fsync syslogd 60315 231169 1 0 3 0x100082 netio syslogd 31144 56259 1 77 3 0x100090 poll dhclient 64510 169716 1 0 3 0x80 poll dhclient 24541 83531 0 0 3 0x14200 pgzero zerothread 16045 212279 0 0 3 0x14200 aiodoned aiodoned 82597 377694 0 0 3 0x14200 syncer update 31496 498830 0 0 3 0x14200 cleaner cleaner *94142 218822 0 0 7 0x14200 reaper 3831 140889 0 0 3 0x14200 pgdaemon pagedaemon 58553 59827 0 0 3 0x14200 bored crynlk 20980 269127 0 0 3 0x14200 bored crypto 58892 259715 0 0 3 0x40014200 acpi0 acpi0 81937 257629 0 0 3 0x40014200 idle1 95473 293556 0 0 3 0x14200 bored softnet 40624 83079 0 0 3 0x14200 bored systqmp 89994 45330 0 0 3 0x14200 bored systq 67312 474654 0 0 3 0x40014200 bored softclock 69757 254240 0 0 3 0x40014200 idle0 1 172417 0 0 3 0x82 wait init 0 0 -1 0 3 0x10200 scheduler swapper ddb{1}> show all locks Process 62795 (syz-executor0) thread 0xffff800020b74710 (10619) exclusive rrwlock inode r = 0 (0xfffffd8064d284d8) locked @ /syzkaller/managers/multicore/kernel/sys/ufs/ufs/ufs_vnops.c:1547 exclusive rrwlock inode r = 0 (0xfffffd806ce95d60) locked @ /syzkaller/managers/multicore/kernel/sys/ufs/ufs/ufs_vnops.c:1547 Process 94350 (syslogd) thread 0xffff800020be5528 (182273) exclusive rrwlock inode r = 0 (0xfffffd806eb94808) locked @ /syzkaller/managers/multicore/kernel/sys/ufs/ufs/ufs_vnops.c:1547 ddb{1}> show malloc Type InUse MemUse HighUse Limit Requests Type Lim Kern Lim devbuf 9601 22770K 26870K 78643K 14772 0 0 pcb 23 9K 11K 78643K 9111 0 0 rtable 100 3K 4K 78643K 2048 0 0 ifaddr 80 23K 26K 78643K 1179 0 0 counters 39 33K 33K 78643K 39 0 0 ioctlops 0 0K 2K 78643K 144 0 0 iov 0 0K 24K 78643K 1564 0 0 mount 1 1K 1K 78643K 1 0 0 vnodes 1186 74K 76K 78643K 13107 0 0 UFS quota 1 32K 32K 78643K 1 0 0 UFS mount 5 36K 36K 78643K 5 0 0 shm 3 5K 9K 78643K 292 0 0 VM map 2 1K 1K 78643K 2 0 0 sem 12 1K 1K 78643K 2472 0 0 dirhash 12 2K 2K 78643K 12 0 0 ACPI 1792 194K 288K 78643K 12592 0 0 file desc 5 13K 25K 78643K 18731 0 0 sigio 1 0K 0K 78643K 359 0 0 proc 42 38K 70K 78643K 2927 0 0 subproc 64 65538K 67586K 78643K 152 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 3530 0 0 in_multi 33 2K 2K 78643K 763 0 0 ether_multi 1 0K 0K 78643K 113 0 0 ISOFS mount 1 32K 32K 78643K 1 0 0 MSDOSFS mount 1 16K 16K 78643K 1 0 0 ttys 138 609K 609K 78643K 138 0 0 exec 0 0K 1K 78643K 1321 0 0 pfkey data 0 0K 4K 78643K 9 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 150 24K 44K 78643K 60135 0 0 UVM aobj 130 4K 4K 78643K 142 0 0 memdesc 1 4K 4K 78643K 1 0 0 crypto data 1 1K 1K 78643K 1 0 0 ip6_options 0 0K 1K 78643K 476 0 0 NDP 19 0K 0K 78643K 332 0 0 temp 219 2368K 2448K 78643K 51258 0 0 kqueue 0 0K 0K 78643K 197 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 8370 0 8359 49 47 2 2 0 8 1 plimitpl 152 204 0 197 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 2881 0 2877 1 0 1 1 0 8 0 nd6 48 4 0 0 1 0 1 1 0 8 0 ppxss 1128 214 0 214 80 80 0 1 0 8 0 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 6 1 0 1 1 0 8 0 semapl 112 2470 0 2460 1 0 1 1 0 8 0 shmpl 112 140 0 12 4 0 4 4 0 8 0 dirhash 1024 17 0 0 3 0 3 3 0 8 0 dino1pl 128 39402 0 37566 60 0 60 60 0 8 0 ffsino 272 39402 0 37566 124 1 123 123 0 8 0 nchpl 144 66306 0 64711 60 0 60 60 0 8 0 uvmvnodes 72 5926 0 0 108 0 108 108 0 8 0 vnodes 200 5926 0 0 312 0 312 312 0 8 0 namei 1024 204931 0 204931 5 4 1 1 0 8 1 percpumem 16 30 0 0 1 0 1 1 0 8 0 scsiplug 64 45 0 45 34 34 0 1 0 8 0 scxspl 192 203333 0 203332 42 41 1 6 0 8 0 sigapl 432 18899 0 18886 2 0 2 2 0 8 0 futexpl 56 253017 0 253017 5 4 1 1 0 8 1 knotepl 112 4701 0 4674 35 33 2 2 0 8 1 kqueuepl 104 6579 0 6577 1 0 1 1 0 8 0 pipepl 112 13100 0 13081 36 35 1 2 0 8 0 fdescpl 488 18900 0 18886 3 1 2 3 0 8 0 filepl 152 117411 0 117314 65 60 5 7 0 8 0 lockfpl 96 5601 0 5601 42 41 1 1 0 8 1 lockfspl 24 9707 0 9707 42 41 1 1 0 8 1 sessionpl 112 18 0 8 1 0 1 1 0 8 0 pgrppl 48 204 0 194 1 0 1 1 0 8 0 ucredpl 96 35510 0 35503 1 0 1 1 0 8 0 zombiepl 144 18887 0 18886 4 3 1 1 0 8 0 processpl 840 18915 0 18886 4 0 4 4 0 8 0 procpl 600 58154 0 58114 6 2 4 5 0 8 0 sosppl 128 356 0 356 75 74 1 1 0 8 1 sockpl 384 17096 0 17079 47 44 3 4 0 8 1 mcl64k 65536 2638 0 0 244 179 65 65 0 8 0 mcl16k 16384 15 0 0 2 0 2 2 0 8 0 mcl12k 12288 73 0 0 3 1 2 2 0 8 0 mcl9k 9216 73 0 0 4 2 2 2 0 8 0 mcl8k 8192 41 0 0 6 3 3 3 0 8 0 mcl4k 4096 43 0 0 5 2 3 3 0 8 0 mcl2k2 2112 12 0 0 1 0 1 1 0 8 0 mcl2k 2048 186 0 0 12 5 7 12 0 8 0 mtagpl 80 1 0 0 1 0 1 1 0 8 0 mbufpl 256 2733 0 0 45 10 35 36 0 8 0 bufpl 256 40624 0 30353 768 120 648 768 0 8 0 anonpl 16 2117189 0 2109545 589 548 41 48 0 125 0 amapchunkpl 152 115542 0 115449 344 335 9 96 0 158 5 amappl16 192 117629 0 117230 867 842 25 33 0 8 4 amappl15 184 1 0 0 1 0 1 1 0 8 0 amappl14 176 9458 0 9456 2 1 1 1 0 8 0 amappl13 168 9287 0 9282 1 0 1 1 0 8 0 amappl12 160 15 0 14 1 0 1 1 0 8 0 amappl11 152 181 0 172 1 0 1 1 0 8 0 amappl10 144 65 0 62 2 1 1 1 0 8 0 amappl9 136 349 0 346 1 0 1 1 0 8 0 amappl8 128 378 0 301 5 2 3 3 0 8 0 amappl7 120 9279 0 9273 1 0 1 1 0 8 0 amappl6 112 9492 0 9486 1 0 1 1 0 8 0 amappl5 104 236 0 224 1 0 1 1 0 8 0 amappl4 96 382 0 358 2 1 1 2 0 8 0 amappl3 88 875 0 870 1 0 1 1 0 8 0 amappl2 80 189010 0 188957 2 0 2 2 0 8 0 amappl1 72 409012 0 408584 24 14 10 19 0 8 0 amappl 72 58691 0 58654 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 141 0 12 3 0 3 3 0 8 0 uaddrrnd 24 18900 0 18886 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 18900 0 18886 1 0 1 1 0 8 0 vmmpekpl 168 163115 0 163092 2 0 2 2 0 8 0 vmmpepl 168 2050991 0 2049569 586 515 71 77 0 357 4 vmsppl 360 18899 0 18886 2 0 2 2 0 8 0 pdppl 4096 37807 0 37772 6 1 5 6 0 8 0 pvpl 32 5327630 0 5316874 1261 1147 114 133 0 265 21 pmappl 224 18899 0 18886 1 0 1 1 0 8 0 extentpl 40 39 0 25 1 0 1 1 0 8 0 phpool 112 1236 0 327 29 1 28 29 0 8 0