panic: sleep: syz-executor[74539] slept inside a no-sleep walk bracket (raw pointer held across sleep, wmesg "getblk") Stopped at db_enter+0x17: popq %rbp TID PID UID PRFLAGS PFLAGS CPU COMMAND * 71261 74539 0 0x10 0x4000010 0K syz-executor db_enter() at db_enter+0x17 sys/arch/amd64/amd64/db_interface.c:457 panic(ffffffff84d8d160) at panic+0x270 sys/kern/subr_prf.c:198 sleep_setup(ffff800001bce110,11,ffffffff84692e40) at sleep_setup+0x3b2 sys/kern/kern_synch.c:296 tsleep_nsec(ffff800001bce110,11,ffffffff84692e40,ffffffffffffffff) at tsleep_nsec+0x29c sys/kern/kern_synch.c:153 getblk(ffff800000d8e360,65560,4000,0,ffffffffffffffff) at getblk+0x23a sys/kern/vfs_bio.c:882 bread(ffff800000d8e360,65560,4000,ffff800029991740) at bread+0x47 bio_doread sys/kern/vfs_bio.c:295 [inline] bread(ffff800000d8e360,65560,4000,ffff800029991740) at bread+0x47 sys/kern/vfs_bio.c:340 ffs_update(ffff800001c1de30,1) at ffs_update+0x3e4 sys/ufs/ffs/ffs_inode.c:91 ffs_truncate(ffff800001c1de30,0,0,ffffffffffffffff) at ffs_truncate+0x12f0 sys/ufs/ffs/ffs_inode.c:-1 ufs_inactive(ffff800029991b20) at ufs_inactive+0x2cb sys/ufs/ufs/ufs_inode.c:84 VOP_INACTIVE(ffff8000017d9978,ffff800045ff4fb8) at VOP_INACTIVE+0x1bb sys/kern/vfs_vops.c:498 vrele(ffff8000017d9978) at vrele+0x16a sys/kern/vfs_subr.c:845 ktrsettrace(ffffffff85e2cd80,80000008,ffff8000018fbd88,ffff800000119a28) at ktrsettrace+0x16c sys/kern/kern_ktrace.c:123 ktrops(ffff800045ff4fb8,ffffffff85e2cd80,0,80000008,ffff8000018fbd88,ffff800000119a28) at ktrops+0x338 sys/kern/kern_ktrace.c:578 doktrace(ffff8000018fbd88,4,8,0,ffff800045ff4fb8) at doktrace+0xa72 ktrsetchildren sys/kern/kern_ktrace.c:607 [inline] doktrace(ffff8000018fbd88,4,8,0,ffff800045ff4fb8) at doktrace+0xa72 sys/kern/kern_ktrace.c:522 end trace frame: 0xffff800029992010, count: 0 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: sleep: syz-executor[74539] slept inside a no-sleep walk bracket (raw pointer held across sleep, wmesg "getblk") ddb{0}> show kasan kasan: no report recorded this boot ddb{0}> trace db_enter() at db_enter+0x17 sys/arch/amd64/amd64/db_interface.c:457 panic(ffffffff84d8d160) at panic+0x270 sys/kern/subr_prf.c:198 sleep_setup(ffff800001bce110,11,ffffffff84692e40) at sleep_setup+0x3b2 sys/kern/kern_synch.c:296 tsleep_nsec(ffff800001bce110,11,ffffffff84692e40,ffffffffffffffff) at tsleep_nsec+0x29c sys/kern/kern_synch.c:153 getblk(ffff800000d8e360,65560,4000,0,ffffffffffffffff) at getblk+0x23a sys/kern/vfs_bio.c:882 bread(ffff800000d8e360,65560,4000,ffff800029991740) at bread+0x47 bio_doread sys/kern/vfs_bio.c:295 [inline] bread(ffff800000d8e360,65560,4000,ffff800029991740) at bread+0x47 sys/kern/vfs_bio.c:340 ffs_update(ffff800001c1de30,1) at ffs_update+0x3e4 sys/ufs/ffs/ffs_inode.c:91 ffs_truncate(ffff800001c1de30,0,0,ffffffffffffffff) at ffs_truncate+0x12f0 sys/ufs/ffs/ffs_inode.c:-1 ufs_inactive(ffff800029991b20) at ufs_inactive+0x2cb sys/ufs/ufs/ufs_inode.c:84 VOP_INACTIVE(ffff8000017d9978,ffff800045ff4fb8) at VOP_INACTIVE+0x1bb sys/kern/vfs_vops.c:498 vrele(ffff8000017d9978) at vrele+0x16a sys/kern/vfs_subr.c:845 ktrsettrace(ffffffff85e2cd80,80000008,ffff8000018fbd88,ffff800000119a28) at ktrsettrace+0x16c sys/kern/kern_ktrace.c:123 ktrops(ffff800045ff4fb8,ffffffff85e2cd80,0,80000008,ffff8000018fbd88,ffff800000119a28) at ktrops+0x338 sys/kern/kern_ktrace.c:578 doktrace(ffff8000018fbd88,4,8,0,ffff800045ff4fb8) at doktrace+0xa72 ktrsetchildren sys/kern/kern_ktrace.c:607 [inline] doktrace(ffff8000018fbd88,4,8,0,ffff800045ff4fb8) at doktrace+0xa72 sys/kern/kern_ktrace.c:522 sys_ktrace(ffff800045ff4fb8,ffff800029992190,ffff800029992100) at sys_ktrace+0x1f6 sys/kern/kern_ktrace.c:563 syscall(ffff800029992190) at syscall+0x1089 mi_syscall sys/sys/syscall_mi.h:176 [inline] syscall(ffff800029992190) at syscall+0x1089 sys/arch/amd64/amd64/trap.c:783 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x64124ef5280, count: -17 ddb{0}> show registers rdi 0 rsi 0x1 rbp 0xffff8000299911f0 rbx 0xffff800029991260 rdx 0 rcx 0xffffffff851e9ff0 cpu_info_full_primary+0x1ff0 rax 0xffff80000016e880 r8 0x101010101010101 r9 0x8080808080808080 r10 0 r11 0xffffffff83e54b70 x86_bus_space_io_read_1 r12 0xffffffff84d8d160 .str.9 r13 0xffffffff851eac08 cpu_info_full_primary+0x2c08 r14 0xffffffff851eae07 cpu_info_full_primary+0x2e07 r15 0x1 rip 0xffffffff82f1b577 db_enter+0x17 cs 0x8 rflags 0x246 rsp 0xffff8000299911f0 ss 0x10 db_enter+0x17: popq %rbp ddb{0}> show proc PROC (syz-executor) tid=71261 pid=74539 tcnt=2 stat=onproc flags process=10 proc=4000010 runpri=32, usrpri=79, slppri=32, nice=20 wchan=0x0, wmesg=, ps_single=0x0 scnt=0 ecnt=0 forw=0xffffffffffffffff, list=0xffff800045ff5cb0,0xffffffff85deb120 process=0xffff8000299144e0 user=0xffff800029987000, vmspace=0xffff800001c345d0 estcpu=29, cpticks=1, pctcpu=0.0, user=0, sys=1, intr=0 ddb{0}> ps PID TID PPID UID S PRLAGS PFLAGS WAIT COMMAND 74539 19765 72376 0 2 0x10 0 syz-executor *74539 71261 72376 0 7 0x10 0x4000010 syz-executor 42803 105740 53065 0 2 0 0 syz-executor 42803 264134 53065 0 3 0 0x4000080 fsleep syz-executor 43453 166998 63439 0 2 0 0 syz-executor 43453 29555 63439 0 3 0 0x4000080 fsleep syz-executor 99364 497577 38512 0 2 0x11 0 syz-executor 99364 113223 38512 0 3 0x11 0x4000080 fsleep syz-executor 99364 354481 38512 0 3 0x11 0x4000080 fsleep syz-executor 24035 284431 75927 0 2 0 0 syz-executor 24035 499556 75927 0 3 0 0x4000080 fsleep syz-executor 24035 218757 75927 0 2 0 0x4000000 syz-executor 58801 15631 38260 0 2 0x2 0 syz-executor 82642 187716 1 0 3 0x100003 0x80 ttyin getty 53065 108665 38260 0 3 0x2 0x80 nanoslp syz-executor 86622 167221 38260 0 3 0x2 0x80 wait syz-executor 72376 79607 38260 0 3 0x2 0x80 nanoslp syz-executor 90649 517976 38260 0 3 0x2 0 biowait syz-executor 63439 487586 38260 0 3 0x2 0x80 nanoslp syz-executor 38512 127244 38260 0 3 0x2 0x80 nanoslp syz-executor 75927 344746 38260 0 3 0x2 0x80 nanoslp syz-executor 38260 387769 1 0 3 0x2 0x80 kqread syz-executor 34829 133890 0 0 3 0x14000 0x200 bored smr 2472 93721 0 0 2 0x14000 0x200 zerothread 22201 500983 0 0 3 0x14000 0x200 aiodoned aiodoned 41490 293938 0 0 3 0x14000 0x200 syncer update 70792 413784 0 0 3 0x14000 0x200 cleaner cleaner 15033 437737 0 0 3 0x14000 0x200 reaper reaper 90083 115619 0 0 3 0x14000 0x200 pgdaemon pagedaemon 18281 471314 0 0 3 0x14000 0x200 bored viomb 86304 356199 0 0 3 0x14000 0x40000200 acpi0 acpi0 86031 435218 0 0 7 0x14000 0x40000200 idle1 56570 408687 0 0 3 0x14000 0x200 bored softnet1 49483 424573 0 0 3 0x14000 0x200 bored softnet0 40492 4879 0 0 3 0x14000 0x200 bored systqmp 13279 439064 0 0 3 0x14000 0x200 bored systq 52954 405171 0 0 3 0x14000 0x200 tmoslp softclockmp 52716 326722 0 0 3 0x14000 0x40000200 tmoslp softclock 73800 417676 0 0 3 0x14000 0x40000200 idle0 1 198759 0 0 3 0x2 0x80 wait init 0 0 -1 0 3 0x10000 0x200 scheduler swapper ddb{0}> show all locks Process 74539 (syz-executor) thread 0xffff800045ff4fb8 (71261) exclusive rrwlock inode r = 0 (0xffff800001c1ded0) #0 witness_lock+0x632 stacktrace_save sys/sys/stacktrace.h:37 [inline] #0 witness_lock+0x632 sys/kern/subr_witness.c:1160 #1 rw_do_enter_write+0x53e sys/kern/kern_rwlock.c:320 #2 rrw_enter+0xf0 sys/kern/kern_rwlock.c:621 #3 VOP_LOCK+0x17e sys/kern/vfs_vops.c:527 #4 vn_lock+0xca sys/kern/vfs_vnops.c:576 #5 vrele+0x113 sys/kern/vfs_subr.c:836 #6 ktrsettrace+0x16c sys/kern/kern_ktrace.c:123 #7 ktrops+0x338 sys/kern/kern_ktrace.c:578 #8 doktrace+0xa72 ktrsetchildren sys/kern/kern_ktrace.c:607 [inline] #8 doktrace+0xa72 sys/kern/kern_ktrace.c:522 #9 sys_ktrace+0x1f6 sys/kern/kern_ktrace.c:563 #10 syscall+0x1089 mi_syscall sys/sys/syscall_mi.h:176 [inline] #10 syscall+0x1089 sys/arch/amd64/amd64/trap.c:783 #11 Xsyscall+0x128 exclusive kernel_lock &kernel_lock r = 0 (0xffffffff85d52380) #0 witness_lock+0x632 stacktrace_save sys/sys/stacktrace.h:37 [inline] #0 witness_lock+0x632 sys/kern/subr_witness.c:1160 #1 syscall+0x1048 mi_syscall sys/sys/syscall_mi.h:175 [inline] #1 syscall+0x1048 sys/arch/amd64/amd64/trap.c:783 #2 Xsyscall+0x128 Process 90649 (syz-executor) thread 0xffff8000299274d8 (517976) exclusive rrwlock inode r = 0 (0xffff800001ae2578) #0 witness_lock+0x632 stacktrace_save sys/sys/stacktrace.h:37 [inline] #0 witness_lock+0x632 sys/kern/subr_witness.c:1160 #1 rw_do_enter_write+0x53e sys/kern/kern_rwlock.c:320 #2 rrw_enter+0xf0 sys/kern/kern_rwlock.c:621 #3 VOP_LOCK+0x17e sys/kern/vfs_vops.c:527 #4 ufs_ihashins+0xda sys/ufs/ufs/ufs_ihash.c:146 #5 ffs_vget+0x2e9 sys/ufs/ffs/ffs_vfsops.c:1232 #6 ffs_inode_alloc+0x576 sys/ufs/ffs/ffs_alloc.c:393 #7 ufs_mkdir+0x25d sys/ufs/ufs/ufs_vnops.c:1112 #8 VOP_MKDIR+0x1a8 sys/kern/vfs_vops.c:394 #9 domkdirat+0x1f9 sys/kern/vfs_syscalls.c:3063 #10 syscall+0x1089 mi_syscall sys/sys/syscall_mi.h:176 [inline] #10 syscall+0x1089 sys/arch/amd64/amd64/trap.c:783 #11 Xsyscall+0x128 exclusive rrwlock inode r = 0 (0xffff800001be67d8) #0 witness_lock+0x632 stacktrace_save sys/sys/stacktrace.h:37 [inline] #0 witness_lock+0x632 sys/kern/subr_witness.c:1160 #1 rw_do_enter_write+0x53e sys/kern/kern_rwlock.c:320 #2 rrw_enter+0xf0 sys/kern/kern_rwlock.c:621 #3 VOP_LOCK+0x17e sys/kern/vfs_vops.c:527 #4 vn_lock+0xca sys/kern/vfs_vnops.c:576 #5 vfs_lookup+0x1f7 sys/kern/vfs_lookup.c:431 #6 namei+0xe19 sys/kern/vfs_lookup.c:250 #7 domkdirat+0xe1 sys/kern/vfs_syscalls.c:3048 #8 syscall+0x1089 mi_syscall sys/sys/syscall_mi.h:176 [inline] #8 syscall+0x1089 sys/arch/amd64/amd64/trap.c:783 #9 Xsyscall+0x128 ddb{0}> show malloc Type InUse MemUse HighUse Limit Requests Type Lim devbuf 11044 12161K 12543K 166960K 12354 0 pcb 18 30K 32K 166960K 99 0 rtable 219 11K 13K 166960K 445 0 pf 33 22K 24K 166960K 65 0 ifaddr 39 11K 12K 166960K 62 0 ifgroup 51 2K 2K 166960K 78 0 sysctl 3 1K 13K 166960K 9 0 counters 68 42K 42K 166960K 82 0 ioctlops 0 0K 4K 166960K 1541 0 iov 0 0K 16K 166960K 73 0 mount 1 1K 1K 166960K 1 0 log 67 16K 16K 166960K 71 0 vnodes 1299 84K 84K 166960K 1534 0 UFS quota 1 36K 36K 166960K 1 0 UFS mount 5 44K 44K 166960K 5 0 shm 2 2K 14K 166960K 13 0 VM map 2 1K 1K 166960K 2 0 sem 12 0K 1K 166960K 24 0 dirhash 12 2K 2K 166960K 12 0 ACPI 1734 201K 292K 166960K 11964 0 file desc 15 54K 93K 166960K 433 0 sigio 0 0K 0K 166960K 6 0 proc 21 46K 209K 166960K 667 0 subproc 63 7K 9K 166960K 99 0 NFS srvsock 1 0K 0K 166960K 1 0 NFS daemon 1 20K 20K 166960K 1 0 ip_moptions 0 0K 0K 166960K 2 0 in_multi 88 6K 7K 166960K 132 0 ether_multi 1 0K 0K 166960K 1 0 mrt 0 0K 0K 166960K 15 0 ISOFS mount 1 36K 36K 166960K 1 0 MSDOSFS mount 1 20K 20K 166960K 1 0 ttys 67 465K 465K 166960K 67 0 exec 0 0K 2K 166960K 433 0 fusefs mount 1 36K 36K 166960K 1 0 tdb 3 1K 1K 166960K 3 0 VM swap 8 62K 64K 166960K 10 0 UVM amap 124 127K 242K 166960K 5455 0 UVM aobj 23 4K 8K 166960K 27 0 pinsyscall 1042 1799K 1802K 166960K 1676 0 memdesc 1 4K 4K 166960K 1 0 crypto data 1 1K 1K 166960K 1 0 NDP 11 0K 2K 166960K 40 0 temp 35 9163K 9483K 166960K 8060 0 kqueue 1 4K 52K 166960K 91 0 SYN cache 2 16K 16K 166960K 2 0 ddb{0}> show all pools Name Size Requests Fail Releases Pgreq Pgrel Npage Hiwat Minpg Maxpg Idle plcache 128 28 0 0 1 0 1 1 0 8 0 rtpcb 120 40 0 40 2 1 1 1 0 8 1 rtentry 176 146 0 45 6 0 6 6 0 8 0 unpcb 144 299 0 296 2 1 1 2 0 8 0 syncache 336 4 0 4 2 2 0 1 0 8 0 tcpcb 736 51 0 50 1 0 1 1 0 8 0 arp 136 24 0 8 1 0 1 1 0 8 0 inpcb 328 325 0 321 8 5 3 6 0 8 1 nd6 152 35 0 12 2 0 2 2 0 8 1 kcovpl 48 11 0 4 1 0 1 1 0 8 0 ppxss 1192 1 0 1 1 1 0 1 0 8 0 pffrag 232 1 0 0 1 0 1 1 0 482 0 pffrnode 88 1 0 0 1 0 1 1 0 8 0 pffrent 40 3 0 2 1 0 1 1 0 8 0 pfosfp 40 1428 0 1005 5 0 5 5 0 8 0 pfosfpen 112 1428 0 714 21 0 21 21 0 8 0 pfstitem 24 40 0 0 1 0 1 1 0 8 0 pfstkey 128 40 0 0 2 0 2 2 0 8 0 pfstate 448 40 0 0 5 0 5 5 0 8 0 pfrule 1360 23 0 18 2 1 1 2 0 8 0 art_heap8 4096 1 0 0 1 0 1 1 0 8 0 art_heap4 256 597 0 185 30 1 29 29 0 8 1 art_table 40 598 0 185 5 0 5 5 0 8 0 art_node 32 146 0 54 1 0 1 1 0 8 0 sysvmsgpl 40 4 0 3 1 0 1 1 0 8 0 semupl 112 1 0 1 1 1 0 1 0 8 0 semapl 72 22 0 12 1 0 1 1 0 8 0 shmpl 112 24 0 4 1 0 1 1 0 8 0 dirhash 1024 17 0 0 3 0 3 3 0 8 0 dino2pl 256 1977 0 495 93 0 93 93 0 8 0 ffsino 296 1977 0 495 115 0 115 115 0 8 0 nchpl 144 2556 0 844 64 0 64 64 0 8 0 vnodes 216 2197 0 0 123 0 123 123 0 8 0 namei 1024 8475 0 8474 2 1 1 1 0 8 0 percpumem 16 57 0 7 1 0 1 1