panic: kernel diagnostic assertion "__mp_lock_held(&sched_lock, curcpu()) == 0" failed: file "/syzkaller/managers/multicore/kernel/sys/kern/kern_lock.c", line 63 Stopped at db_enter+0xa: popq %rbp TID PID UID PRFLAGS PFLAGS CPU COMMAND db_enter() at db_enter+0xa panic() at panic+0x147 __assert(ffffffff81521464,ffff8000211ab3d0,ffff8000210a39e0,ffff800000038e80) at __assert+0x24 _kernel_lock(ffff8000210a39e0,ffff8000211a6000) at _kernel_lock+0x125 pageflttrap() at pageflttrap+0x6c kerntrap(9) at kerntrap+0x8d alltraps_kern(6,ffff800000ad6000,ffffffffffffffff,0,9,ffff8000210a39e0) at alltraps_kern+0x7b ptsignal(2829,ffff8000210a39e0,ffff8000210b7630) at ptsignal+0x115 mi_switch() at mi_switch+0x1fb sleep_finish(1,ffff8000211ab660) at sleep_finish+0xd3 sleep_finish_all(ffff8000211ab660,32) at sleep_finish_all+0x22 tsleep(ffff8000210a39e0,3,0,ffff8000210b76f8) at tsleep+0x142 single_thread_set(ffff8000210a39e0,ffff8000210a39e0,0) at single_thread_set+0x28b exit1(ffff8000210a39e0,9,0) at exit1+0x84 end trace frame: 0xffff8000211ab830, 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{1}> ddb{1}> set $lines = 0 ddb{1}> show panic kernel diagnostic assertion "__mp_lock_held(&sched_lock, curcpu()) == 0" failed: file "/syzkaller/managers/multicore/kernel/sys/kern/kern_lock.c", line 63 ddb{1}> trace db_enter() at db_enter+0xa panic() at panic+0x147 __assert(ffffffff81521464,ffff8000211ab3d0,ffff8000210a39e0,ffff800000038e80) at __assert+0x24 _kernel_lock(ffff8000210a39e0,ffff8000211a6000) at _kernel_lock+0x125 pageflttrap() at pageflttrap+0x6c kerntrap(9) at kerntrap+0x8d alltraps_kern(6,ffff800000ad6000,ffffffffffffffff,0,9,ffff8000210a39e0) at alltraps_kern+0x7b ptsignal(2829,ffff8000210a39e0,ffff8000210b7630) at ptsignal+0x115 mi_switch() at mi_switch+0x1fb sleep_finish(1,ffff8000211ab660) at sleep_finish+0xd3 sleep_finish_all(ffff8000211ab660,32) at sleep_finish_all+0x22 tsleep(ffff8000210a39e0,3,0,ffff8000210b76f8) at tsleep+0x142 single_thread_set(ffff8000210a39e0,ffff8000210a39e0,0) at single_thread_set+0x28b exit1(ffff8000210a39e0,9,0) at exit1+0x84 postsig(100,ffff8000210a39e0) at postsig+0x3ea userret(0) at userret+0x11b syscall(0) at syscall+0x54d Xsyscall(6,58,1739cadc000,53,0,1739cad9900) at Xsyscall+0x128 end of kernel end trace frame: 0x173e57df590, count: -18 ddb{1}> show registers rdi 0xffffffff81e2ec58 kprintf_mutex rsi 0xffffffff81b67d99 db_enter+0x9 rbp 0xffff8000211ab330 rbx 0xffff8000211ab3d0 rdx 0xffff800000ad6000 rcx 0x4124 __ALIGN_SIZE+0x3124 rax 0xffff800000ad6000 r8 0xffff8000211ab300 r9 0x8080808080808080 r10 0x60905f3d72fffdb2 r11 0xffffffff819e6130 x86_bus_space_io_read_1 r12 0x3000000008 r13 0xffff8000211ab340 r14 0x100 r15 0xffffffff81bf400f cmd0646_9_tim_udma+0x20bde rip 0xffffffff81b67d9a db_enter+0xa cs 0x8 rflags 0x206 rsp 0xffff8000211ab330 ss 0x10 db_enter+0xa: popq %rbp ddb{1}> show proc PROC (syz-executor0) pid=411107 stat=sleep flags process=1000 proc=4002000 pri=50, usrpri=59, nice=20 forw=0x0, list=0xffff8000210a32d8,0xffff8000210a24d8 process=0xffff8000210b7630 user=0xffff8000211a6000, vmspace=0xffffff007f124d68 estcpu=36, cpticks=0, pctcpu=0.0 user=0, sys=0, intr=0 ddb{1}> ps PID TID PPID UID S FLAGS WAIT COMMAND *63176 411107 5161 0 3 0x4003000 suspend syz-executor0 63176 384693 5161 0 2 0x4081000 syz-executor0 80245 76884 15514 0 3 0x80 nanosleep syz-executor1 80245 506280 15514 0 3 0x4000080 nanosleep syz-executor1 18695 379545 1 0 3 0x100083 ttyin getty 11848 240477 0 0 3 0x14200 bored sosplice 15514 493056 35592 0 3 0x82 nanosleep syz-executor1 5161 353797 35592 0 3 0x82 nanosleep syz-executor0 35592 459283 27952 0 3 0x82 thrsleep syz-fuzzer 35592 469380 27952 0 3 0x4000082 thrsleep syz-fuzzer 35592 271747 27952 0 3 0x4000082 thrsleep syz-fuzzer 35592 87539 27952 0 3 0x4000082 thrsleep syz-fuzzer 35592 108039 27952 0 3 0x4000082 thrsleep syz-fuzzer 35592 174212 27952 0 3 0x4000082 thrsleep syz-fuzzer 35592 376433 27952 0 3 0x4000082 kqread syz-fuzzer 35592 474160 27952 0 3 0x4000082 thrsleep syz-fuzzer 35592 18539 27952 0 3 0x4000082 thrsleep syz-fuzzer 35592 320118 27952 0 3 0x4000082 thrsleep syz-fuzzer 27952 412649 39976 0 3 0x10008a pause ksh 39976 341993 46564 0 3 0x92 select sshd 46564 390952 1 0 3 0x80 select sshd 12 138312 84757 73 3 0x100010 ffs_fsync syslogd 84757 187478 1 0 3 0x100082 netio syslogd 73032 156183 1 77 3 0x100090 poll dhclient 25587 305141 1 0 3 0x80 poll dhclient 63865 460955 0 0 3 0x14200 pgzero zerothread 9351 322180 0 0 3 0x14200 aiodoned aiodoned 8149 230041 0 0 3 0x14200 syncer update 96043 40529 0 0 3 0x14200 cleaner cleaner 83691 163811 0 0 3 0x14200 reaper reaper 22208 349244 0 0 3 0x14200 pgdaemon pagedaemon 90218 346453 0 0 3 0x14200 bored crynlk 87434 256645 0 0 3 0x14200 bored crypto 52891 329123 0 0 3 0x40014200 acpi0 acpi0 55548 293949 0 0 3 0x40014200 idle1 14051 499727 0 0 3 0x14200 bored softnet 65358 487762 0 0 3 0x14200 bored systqmp 53237 460659 0 0 3 0x14200 bored systq 6554 243268 0 0 3 0x40014200 bored softclock 27780 517001 0 0 3 0x40014200 idle0 1 279078 0 0 3 0x82 wait init 0 0 -1 0 3 0x10200 scheduler swapper