panic: thread 0xffff800020b924c8 cannot exit while holding sleeplocks Stopped at db_enter+0x18: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND 397203 10016 32767 0x10 0 0 syz-executor1 *495769 76232 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(c9596128ab9a7710) 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 0xffff800020b924c8 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(c9596128ab9a7710) 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 0xffff800020b67400 rbx 0xffff800020b674a0 rdx 0xffffffff81ec88ae cmd0646_9_tim_udma+0x18cbf rcx 0 rax 0 r8 0xffffffff81aa9b64 kprintf+0x174 r9 0x1 r10 0x3463b31ad6793191 r11 0x659c948cdb222096 r12 0x3000000008 r13 0xffff800020b67410 r14 0x100 r15 0x1 rip 0xffffffff819d4fa8 db_enter+0x18 cs 0x8 rflags 0x246 rsp 0xffff800020b673f0 ss 0x10 db_enter+0x18: addq $0x8,%rsp ddb{1}> show proc PROC (reaper) pid=495769 stat=onproc flags process=14000 proc=200 pri=4, usrpri=58, nice=20 forw=0xffffffffffffffff, list=0xffff800020b20708,0xffff800020b21078 process=0xffff800020b5a008 user=0xffff800020b62000, vmspace=0xffffffff822dc6f0 estcpu=8, cpticks=2, pctcpu=0.67 user=0, sys=2, intr=0 ddb{1}> ps PID TID PPID UID S FLAGS WAIT COMMAND 10016 397203 78311 32767 7 0x10 syz-executor1 10016 356305 78311 32767 3 0x4000090 ttyin syz-executor1 10016 41248 78311 32767 3 0x4000090 fsleep syz-executor1 459 333995 76391 32767 2 0x490 syz-executor0 76391 73216 92105 0 3 0x82 wait syz-executor0 78311 242151 50066 32767 2 0x490 syz-executor1 50066 323556 92105 0 3 0x82 wait syz-executor1 50509 228825 0 0 3 0x14200 bored sosplice 92105 85789 66026 0 3 0x82 thrsleep syz-fuzzer 92105 271499 66026 0 3 0x4000082 thrsleep syz-fuzzer 92105 219877 66026 0 3 0x4000082 thrsleep syz-fuzzer 92105 225654 66026 0 3 0x4000082 thrsleep syz-fuzzer 92105 174029 66026 0 3 0x4000082 thrsleep syz-fuzzer 92105 65980 66026 0 3 0x4000082 kqread syz-fuzzer 92105 348329 66026 0 3 0x4000082 thrsleep syz-fuzzer 92105 348861 66026 0 3 0x4000082 thrsleep syz-fuzzer 92105 64306 66026 0 3 0x4000082 thrsleep syz-fuzzer 92105 221727 66026 0 3 0x4000082 thrsleep syz-fuzzer 92105 431068 66026 0 3 0x4000082 thrsleep syz-fuzzer 92105 358042 66026 0 3 0x4000082 thrsleep syz-fuzzer 66026 127639 42463 0 3 0x10008a pause ksh 42463 163690 24602 0 3 0x92 select sshd 13320 172051 1 0 3 0x100083 ttyin getty 24602 368298 1 0 3 0x80 select sshd 63996 358601 69769 73 3 0x100010 ffs_fsync syslogd 69769 134365 1 0 3 0x100082 netio syslogd 18665 474646 1 77 3 0x100090 poll dhclient 26708 274127 1 0 3 0x80 poll dhclient 17665 202992 0 0 3 0x14200 pgzero zerothread 92807 93739 0 0 3 0x14200 aiodoned aiodoned 57976 45903 0 0 3 0x14200 syncer update 91985 284206 0 0 3 0x14200 cleaner cleaner *76232 495769 0 0 7 0x14200 reaper 33095 457262 0 0 3 0x14200 pgdaemon pagedaemon 7365 322784 0 0 3 0x14200 bored crynlk 16387 244036 0 0 3 0x14200 bored crypto 36362 452274 0 0 3 0x40014200 acpi0 acpi0 91699 327954 0 0 3 0x40014200 idle1 72282 244566 0 0 3 0x14200 bored softnet 94832 488947 0 0 3 0x14200 bored systqmp 29149 254245 0 0 3 0x14200 bored systq 12571 363691 0 0 3 0x40014200 bored softclock 90848 258714 0 0 3 0x40014200 idle0 1 256008 0 0 3 0x82 wait init 0 0 -1 0 3 0x10200 scheduler swapper ddb{1}> show all locks Process 63996 (syslogd) thread 0xffff800020be59d8 (358601) exclusive rrwlock inode r = 0 (0xfffffd806ebb01a8) locked @ /syzkaller/managers/setuid/kernel/sys/ufs/ufs/ufs_vnops.c:1547 ddb{1}> show malloc Type InUse MemUse HighUse Limit Requests Type Lim Kern Lim devbuf 9463 6321K 6321K 78643K 13680 0 0 pcb 23 9K 11K 78643K 13753 0 0 rtable 97 3K 3K 78643K 20199 0 0 ifaddr 36 22K 29K 78643K 3828 0 0 counters 39 33K 33K 78643K 39 0 0 ioctlops 0 0K 2K 78643K 760 0 0 iov 0 0K 36K 78643K 1929 0 0 mount 1 1K 1K 78643K 1 0 0 vnodes 1201 75K 75K 78643K 19582 0 0 UFS quota 1 32K 32K 78643K 1 0 0 UFS mount 5 36K 36K 78643K 5 0 0 shm 2 1K 9K 78643K 332 0 0 VM map 2 1K 1K 78643K 2 0 0 sem 12 0K 1K 78643K 2121 0 0 dirhash 12 2K 2K 78643K 12 0 0 ACPI 1792 194K 288K 78643K 12592 0 0 file desc 7 21K 33K 78643K 26475 0 0 sigio 0 0K 0K 78643K 368 0 0 proc 41 38K 70K 78643K 16433 0 0 subproc 68 69634K 69634K 78643K 21352 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 3925 0 0 in_multi 33 2K 2K 78643K 7729 0 0 ether_multi 1 0K 0K 78643K 175 0 0 ISOFS mount 1 32K 32K 78643K 1 0 0 MSDOSFS mount 1 16K 16K 78643K 1 0 0 ttys 78 344K 344K 78643K 78 0 0 exec 0 0K 1K 78643K 4893 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 117 22K 53K 78643K 82379 0 0 UVM aobj 130 7K 7K 78643K 163 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 619 0 0 NDP 5 0K 0K 78643K 1887 0 0 temp 121 2362K 2442K 78643K 100890 0 0 kqueue 0 0K 0K 78643K 268 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 630 0 626 1 0 1 1 0 8 0 inpcbpl 280 11598 0 11591 1 0 1 1 0 8 0 plimitpl 152 1516 0 1507 1 0 1 1 0 8 0 plcache 128 20 0 0 1 0 1 1 0 8 0 rtentry 112 5675 0 5635 2 0 2 2 0 8 0 syncache 264 4 0 4 1 1 0 1 0 8 0 tcpcb 544 4645 0 4641 1 0 1 1 0 8 0 nd6 48 1256 0 1252 1 0 1 1 0 8 0 art_heap8 4096 1 0 0 1 0 1 1 0 8 0 art_heap4 256 26431 0 26240 35 23 12 13 0 8 0 art_table 32 26432 0 26240 2 0 2 2 0 8 0 art_node 16 5674 0 5640 1 0 1 1 0 8 0 sysvmsgpl 40 10 0 9 3 2 1 1 0 8 0 semapl 112 2115 0 2105 1 0 1 1 0 8 0 shmpl 112 161 0 33 4 0 4 4 0 8 0 dirhash 1024 17 0 0 3 0 3 3 0 8 0 dino1pl 128 35416 0 33493 66 3 63 63 0 8 0 ffsino 272 35416 0 33493 129 0 129 129 0 8 0 nchpl 144 70636 0 69059 59 0 59 59 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 265736 0 265736 9 8 1 1 0 8 1 percpumem 16 30 0 0 1 0 1 1 0 8 0 scxspl 192 187680 0 187679 115 114 1 6 0 8 0 sigapl 432 24764 0 24749 4 2 2 3 0 8 0 futexpl 56 253456 0 253455 5 4 1 1 0 8 0 knotepl 112 16708 0 16681 34 33 1 2 0 8 0 kqueuepl 104 7214 0 7212 1 0 1 1 0 8 0 pipepl 112 21754 0 21735 56 54 2 2 0 8 0 fdescpl 488 24765 0 24749 3 0 3 3 0 8 0 filepl 152 168655 0 168555 71 65 6 7 0 8 1 lockfpl 96 5719 0 5719 34 33 1 1 0 8 1 lockfspl 24 12475 0 12475 31 30 1 1 0 8 1 sessionpl 112 643 0 633 1 0 1 1 0 8 0 pgrppl 48 933 0 923 1 0 1 1 0 8 0 ucredpl 96 60352 0 60343 1 0 1 1 0 8 0 zombiepl 144 24749 0 24748 3 2 1 1 0 8 0 processpl 840 24780 0 24748 4 0 4 4 0 8 0 procpl 600 69855 0 69808 9 5 4 5 0 8 0 srpgc 64 3694 0 3694 75 74 1 1 0 8 1 sosppl 128 525 0 525 118 117 1 1 0 8 1 sockpl 384 25940 0 25923 38 35 3 4 0 8 1 mcl64k 65536 20 0 0 3 0 3 3 0 8 0 mcl16k 16384 22 0 0 3 1 2 3 0 8 0 mcl12k 12288 81 0 0 2 0 2 2 0 8 0 mcl9k 9216 87 0 0 4 2 2 2 0 8 0 mcl8k 8192 33 0 0 4 1 3 3 0 8 0 mcl4k 4096 57 0 0 6 3 3 3 0 8 0 mcl2k2 2112 13 0 0 1 0 1 1 0 8 0 mcl2k 2048 201 0 0 11 5 6 11 0 8 0 mtagpl 80 1 0 0 1 0 1 1 0 8 0 mbufpl 256 1279 0 0 11 1 10 10 0 8 0 bufpl 256 43747 0 36778 436 0 436 436 0 8 0 anonpl 16 2581039 0 2575293 416 377 39 48 0 125 2 amapchunkpl 152 189578 0 189476 763 667 96 189 0 158 91 amappl16 192 135992 0 135731 749 725 24 29 0 8 6 amappl15 184 3617 0 3615 1 0 1 1 0 8 0 amappl14 176 5141 0 5129 2 1 1 1 0 8 0 amappl13 168 4783 0 4780 1 0 1 1 0 8 0 amappl12 160 2694 0 2692 1 0 1 1 0 8 0 amappl11 152 5856 0 5847 1 0 1 1 0 8 0 amappl10 144 3031 0 3027 2 1 1 1 0 8 0 amappl9 136 3520 0 3517 1 0 1 1 0 8 0 amappl8 128 7524 0 7427 4 0 4 4 0 8 0 amappl7 120 4757 0 4745 1 0 1 1 0 8 0 amappl6 112 4055 0 4026 1 0 1 1 0 8 0 amappl5 104 3732 0 3720 1 0 1 1 0 8 0 amappl4 96 3745 0 3705 4 2 2 2 0 8 0 amappl3 88 2247 0 2242 1 0 1 1 0 8 0 amappl2 80 214397 0 214308 2 0 2 2 0 8 0 amappl1 72 627426 0 626941 24 14 10 19 0 8 0 amappl 72 74944 0 74901 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 162 0 33 3 0 3 3 0 8 0 uaddrrnd 24 24765 0 24748 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 24765 0 24748 1 0 1 1 0 8 0 vmmpekpl 168 205656 0 205630 2 0 2 2 0 8 0 vmmpepl 168 2864060 0 2862482 509 432 77 88 0 357 3 vmsppl 360 24764 0 24748 2 0 2 2 0 8 0 pdppl 4096 49537 0 49496 8 2 6 6 0 8 0 pvpl 32 7111792 0 7102472 1151 1036 115 130 0 265 23 pmappl 224 24764 0 24748 106 105 1 2 0 8 0 extentpl 40 39 0 25 1 0 1 1 0 8 0 phpool 112 662 0 46 18 0 18 18 0 8 0