panic: kernel diagnostic assertion "part >= 0 && part < MAXPARTITIONS" failed: file "/syzkaller/managers/main/kernel/sys/kern/subr_disk.c", line 1169 Stopped at db_enter+0x25: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND *262703 25541 0 0 0x4000000 0 syz-executor db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:438 panic(ffffffff8336f9a2) at panic+0x1cf sys/kern/subr_prf.c:198 __assert(ffffffff833a991a,ffffffff83347771,491,ffffffff8339e6c4) at __assert+0x29 sys/kern/subr_prf.c:-1 disk_openpart(ffff800000025c48,20,6000,1) at disk_openpart+0x20d sdopen(420,1,6000,ffff80002a8f54e8) at sdopen+0x261 sys/scsi/sd.c:429 VOP_OPEN(fffffd806ba7c048,1,fffffd8007bfd340,ffff80002a8f54e8) at VOP_OPEN+0x82 sys/kern/vfs_vops.c:138 vn_open(ffff80003c93dce0,1,0) at vn_open+0x6a0 sys/kern/vfs_vnops.c:177 doopenat(ffff80002a8f54e8,ffffff9c,200000000700,0,0,ffff80003c93de80) at doopenat+0x34d sys/kern/vfs_syscalls.c:1138 syscall(ffff80003c93df30) at syscall+0x962 mi_syscall sys/sys/syscall_mi.h:-1 [inline] syscall(ffff80003c93df30) at syscall+0x962 sys/arch/amd64/amd64/trap.c:765 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x4eab66da6b0, 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> ddb> set $lines = 0 ddb> set $maxwidth = 0 ddb> show panic *cpu0: kernel diagnostic assertion "part >= 0 && part < MAXPARTITIONS" failed: file "/syzkaller/managers/main/kernel/sys/kern/subr_disk.c", line 1169 ddb> trace db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:438 panic(ffffffff8336f9a2) at panic+0x1cf sys/kern/subr_prf.c:198 __assert(ffffffff833a991a,ffffffff83347771,491,ffffffff8339e6c4) at __assert+0x29 sys/kern/subr_prf.c:-1 disk_openpart(ffff800000025c48,20,6000,1) at disk_openpart+0x20d sdopen(420,1,6000,ffff80002a8f54e8) at sdopen+0x261 sys/scsi/sd.c:429 VOP_OPEN(fffffd806ba7c048,1,fffffd8007bfd340,ffff80002a8f54e8) at VOP_OPEN+0x82 sys/kern/vfs_vops.c:138 vn_open(ffff80003c93dce0,1,0) at vn_open+0x6a0 sys/kern/vfs_vnops.c:177 doopenat(ffff80002a8f54e8,ffffff9c,200000000700,0,0,ffff80003c93de80) at doopenat+0x34d sys/kern/vfs_syscalls.c:1138 syscall(ffff80003c93df30) at syscall+0x962 mi_syscall sys/sys/syscall_mi.h:-1 [inline] syscall(ffff80003c93df30) at syscall+0x962 sys/arch/amd64/amd64/trap.c:765 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x4eab66da6b0, count: -10 ddb> show registers rdi 0 rsi 0x1 rbp 0xffff80003c93d8e0 rbx 0xffff800000025c48 rdx 0 rcx 0 rax 0xffff80002a8f54e8 r8 0x101010101010101 r9 0x8080808080808080 r10 0xbb8a878d1e92badb r11 0xc0e7336f2ed3b00 r12 0 r13 0x1 r14 0 r15 0x1 rip 0xffffffff81666de5 db_enter+0x25 cs 0x8 rflags 0x246 rsp 0xffff80003c93d8d0 ss 0 db_enter+0x25: addq $0x8,%rsp ddb> show proc PROC (syz-executor) tid=262703 pid=25541 tcnt=3 stat=onproc flags process=0 proc=4000000 runpri=32, usrpri=50, slppri=32, nice=20 wchan=0x0, wmesg=, ps_single=0x0 scnt=0 ecnt=0 forw=0xffffffffffffffff, list=0xffff80002a8f4558,0xffffffff83918158 process=0xffff8000ffffb618 user=0xffff80003c938000, vmspace=0xfffffd8070b84178 estcpu=36, cpticks=1, pctcpu=0.0, user=0, sys=1, intr=0 ddb> ps PID TID PPID UID S FLAGS WAIT COMMAND 25541 476713 40103 0 2 0 syz-executor 25541 468217 40103 0 2 0x4000000 syz-executor *25541 262703 40103 0 7 0x4000000 syz-executor 63623 308920 47381 0 2 0 syz-executor 63623 207473 47381 0 3 0x4000080 fsleep syz-executor 30426 338298 86404 0 2 0 syz-executor 30426 444314 86404 0 3 0x4000080 fifor syz-executor 56450 28891 2171 60929 2 0x10 syz-executor 56450 244361 2171 60929 3 0x4000090 fsleep syz-executor 24226 76814 74553 0 2 0xc80 syz-executor 24226 136776 74553 0 3 0x4000080 fsleep syz-executor 24226 315705 74553 0 3 0x4000080 fsleep syz-executor 24226 188901 74553 0 3 0x4000080 fsleep syz-executor 36252 222208 81071 0 3 0x82 wait syz-executor 2171 374628 81071 0 2 0xc82 syz-executor 52051 217458 0 0 3 0x14200 acct acct 70151 336243 81071 0 2 0xc82 syz-executor 40103 170184 81071 0 2 0xc82 syz-executor 47381 512366 81071 0 2 0xc82 syz-executor 70780 160778 81071 0 2 0x2 syz-executor 86404 62279 81071 0 2 0xc82 syz-executor 74553 206622 81071 0 2 0xc82 syz-executor 81071 330871 95490 0 2 0x2 syz-executor 95490 35408 8107 0 3 0x10008a sigsusp ksh 8107 210961 44036 0 3 0x98 kqread sshd-session 44036 99423 46331 0 3 0x92 kqread sshd-session 34428 286014 1 0 3 0x100083 ttyin getty 46331 61997 1 0 3 0x88 kqread sshd 88968 67242 56872 73 3 0x1100090 kqread syslogd 56872 423391 1 0 3 0x100082 sbwait syslogd 81731 62645 1 0 3 0x100080 kqread resolvd 58658 141337 34360 77 3 0x100092 kqread dhcpleased 44005 423630 34360 77 3 0x100092 kqread dhcpleased 34360 438226 1 0 3 0x80 kqread dhcpleased 72812 60969 0 0 3 0x14200 bored smr 72230 98305 0 0 2 0x14200 zerothread 19544 186781 0 0 3 0x14200 aiodoned aiodoned 69654 212485 0 0 3 0x14200 syncer update 92189 219272 0 0 3 0x14200 cleaner cleaner 27929 316389 0 0 3 0x14200 reaper reaper 86647 265479 0 0 3 0x14200 pgdaemon pagedaemon 19469 292559 0 0 3 0x14200 bored viomb 40867 238181 0 0 3 0x40014200 acpi0 acpi0 6891 126742 0 0 3 0x14200 bored softnet0 24410 132773 0 0 3 0x14200 bored systqmp 76983 420168 0 0 3 0x14200 bored systq 12285 48427 0 0 3 0x40014200 tmoslp softclock 64304 25385 0 0 3 0x40014200 idle0 1 12158 0 0 3 0x82 wait init 0 0 -1 0 3 0x10010200 scheduler swapper ddb> show all locks No such command ddb> show malloc Type InUse MemUse HighUse Limit Requests Type Lim devbuf 10191 11174K 11576K 166960K 12648 0 pcb 17 17K 19K 166960K 223 0 rtable 242 9K 9K 166960K 624 0 pf 33 13K 17K 166960K 131 0 ifaddr 44 8K 8K 166960K 108 0 ifgroup 54 2K 2K 166960K 161 0 sysctl 4 1K 9K 166960K 12 0 counters 33 17K 18K 166960K 98 0 ioctlops 0 0K 5K 166960K 231 0 iov 0 0K 24K 166960K 29 0 mount 1 1K 1K 166960K 1 0 log 0 0K 0K 166960K 4 0 vnodes 1460 92K 92K 166960K 2356 0 UFS quota 1 32K 32K 166960K 1 0 UFS mount 5 36K 36K 166960K 5 0 shm 2 1K 5K 166960K 5 0 VM map 2 1K 1K 166960K 2 0 sem 12 1K 1K 166960K 30 0 dirhash 12 2K 2K 166960K 24 0 ACPI 1692 195K 286K 166960K 12470 0 file desc 19 90K 236K 166960K 874 0 sigio 0 0K 0K 166960K 25 0 proc 61 59K 108K 166960K 647 0 subproc 72 4K 4K 166960K 111 0 NFS srvsock 1 0K 0K 166960K 1 0 NFS daemon 1 16K 16K 166960K 1 0 ip_moptions 2 0K 0K 166960K 93 0 in_multi 94 6K 7K 166960K 172 0 ether_multi 1 0K 0K 166960K 7 0 mrt 0 0K 0K 166960K 3 0 ISOFS mount 1 32K 32K 166960K 1 0 MSDOSFS mount 1 16K 16K 166960K 1 0 ttys 109 493K 493K 166960K 109 0 exec 0 0K 1K 166960K 460 0 fusefs mount 1 32K 32K 166960K 1 0 pfkey data 0 0K 0K 166960K 1 0 tdb 3 0K 0K 166960K 3 0 VM swap 8 62K 64K 166960K 10 0 UVM amap 224 142K 157K 166960K 9027 0 UVM aobj 33 16K 16K 166960K 35 0 pinsyscall 38 76K 95K 166960K 2029 0 memdesc 1 4K 4K 166960K 1 0 crypto data 1 1K 1K 166960K 1 0 ip6_options 0 0K 1K 166960K 31 0 NDP 12 0K 2K 166960K 74 0 temp 63 8656K 8720K 166960K 31276 0 kqueue 13 20K 32K 166960K 157 0 SYN cache 2 16K 16K 166960K 2 0 ddb> show all pools Name Size Requests Fail Releases Pgreq Pgrel Npage Hiwat Minpg Maxpg Idle rtpcb 120 91 0 87 1 0 1 1 0 8 0 rtentry 136 176 0 72 4 0 4 4 0 8 0 unpcb 144 897 0 877 9 3 6 6 0 8 5 syncache 336 3 0 3 1 1 0 1 0 8 0 tcpcb 736 359 0 355 12 3 9 10 0 8 8 arp 96 29 0 13 1 0 1 1 0 8 0 ipq 40 9 0 1 1 0 1 1 0 8 0 ipqe 40 12 0 4 1 0 1 1 0 8 0 inpcb 328 844 0 835 14 5 9 9 0 8 7 ip6q 72 3 0 3 2 1 1 1 0 8 1 ip6af 40 6 0 6 2 1 1 1 0 8 1 nd6 112 41 0 18 1 0 1 1 0 8 0 pkpcb 40 5 0 5 2 1 1 1 0 8 1 kcovpl 48 12 0 4 1 0 1 1 0 8 0 ppxss 1072 52 0 52 2 1 1 1 0 8 1 pppxif 1384 5 0 5 2 1 1 1 0 8 1 pfstscr 40 1 0 1 1 1 0 1 0 8 0 pfosfp 40 1 0 0 1 0 1 1 0 8 0 pfosfpen 112 1 0 0 1 0 1 1 0 8 0 pftag 88 1 0 0 1 0 1 1 0 8 0 pfstitem 24 2 0 0 1 0 1 1 0 8 0 pfstkey 128 6 0 4 2 1 1 1 0 8 0 pfstate 384 3 0 2 2 1 1 1 0 8 0 pfrule 1344 73 0 73 2 1 1 1 0 8 1 rttmr 136 1 0 1 1 0 1 1 0 8 1 art_heap8 4096 2 0 0 2 0 2 2 0 8 0 art_heap4 256 684 0 241 30 2 28 30 0 8 0 art_table 40 686 0 241 5 0 5 5 0 8 0 art_node 32 174 0 79 1 0 1 1 0 8 0 sysvmsgpl 40 107 0 67 1 0 1 1 0 8 0 semapl 112 28 0 18 1 0 1 1 0 8 0 shmpl 112 26 0 2 1 0 1 1 0 8 0 dirhash 1024 25 0 8 3 0 3 3 0 8 0 dino2pl 256 3013 0 1508 95 0 95 95 0 8 0 ffsino 256 3013 0 1508 95 0 95 95 0 8 0 nchpl 144 4185 0 2483 64 0 64 64 0 8 0 rtmask 32 11 0 11 2 1 1 1 0 8 1 vnodes 216 3680 0 0 205 0 205 205 0 8 0 namei 1024 14926 0 14925 2 1 1 1 0 8 0 vcpupl 3904 6 0 0 1 0 1 1 0 8 0 vmpool 800 6 0 0 1 0 1 1 0 8 0 kstatmem 264 100 0 76 3 1 2 3 0 8 0 scsiplug 72 1 0 1 1 0 1 1 0 8 1 scxspl 216 12350 0 12350 9 1 8 8 1 8 8 plimitpl 152 185 0 168 1 0 1 1 0 8 0 sigapl 424 1136 0 1093 7 1 6 6 0 8 1 knotepl 120 35886 0 35839 23 14 9 17 0 8 7 kqueuepl 184 254 0 245 1 0 1 1 0 8 0 pipepl 304 252 0 225 8 5 3 8 0 8 0 fdescpl 448 1120 0 1091 5 1 4 5 0 8 0 filepl 120 7674 0 7454 16 3 13 13 0 8 4 lockfpl 104 557 0 554 3 1 2 2 0 8 1 lockfspl 48 193 0 190 1 0 1 1 0 8 0 sessionpl 144 25 0 17 1 0 1 1 0 8 0 pgrppl 48 59 0 43 1 0 1 1 0 8 0 ucredpl 104 1338 0 1326 1 0 1 1 0 8 0 zombiepl 144 1095 0 1093 1 0 1 1 0 8 0 processpl 1152 1136 0 1093 4 0 4 4 0 8 0 procpl 664 2153 0 2102 6 0 6 6 0 8 0 sosppl 176 3 0 3 2 1 1 1 0 8 1 sockpl 552 1896 0 1863 18 7 11 12 0 8 8 mcl64k 65536 61 0 60 1 0 1 1 0 8 0 mcl9k 9216 1 0 1 1 0 1 1 0 8 1 mcl8k 8192 75 0 75 2 1 1 1 0 8 1 mcl4k 4096 3358 0 3305 16 8 8 15 0 8 1 mcl2k2 2112 1 0 1 1 1 0 1 0 8 0 mcl2k 2048 1460 0 1414 8 1 7 7 0 8 1 mtagpl 96 35 0 11 1 0 1 1 0 8 0 mbufpl 256 12986 0 12652 86 52 34 86 0 8 8 bufpl 280 3689 0 120 255 0 255 255 0 8 0 anonpl 24 179997 0 176898 54 9 45 45 0 187 19 amapchunkpl 152 29782 0 29315 36 8 28 29 0 158 8 amappl16 200 3012 0 2981 17 6 11 15 0 8 8 amappl15 192 33 0 33 1 1 0 1 0 8 0 amappl14 184 5 0 5 1 1 0 1 0 8 0 amappl13 176 481 0 479 1 0 1 1 0 8 0 amappl12 168 1482 0 1443 2 0 2 2 0 8 0 amappl11 160 38 0 38 1 1 0 1 0 8 0 amappl10 152 46 0 36 1 0 1 1 0 8 0 amappl9 144 252 0 251 1 0 1 1 0 8 0 amappl8 136 25 0 24 1 0 1 1 0 8 0 amappl7 128 99 0 98 1 0 1 1 0 8 0 amappl6 120 312 0 300 1 0 1 1 0 8 0 amappl5 112 69 0 62 1 0 1 1 0 8 0 amappl4 104 398 0 375 1 0 1 1 0 8 0 amappl3 96 5035 0 4947 3 0 3 3 0 8 0 amappl2 88 1212 0 1143 2 0 2 2 0 8 0 amappl1 80 11954 0 11414 13 1 12 13 0 8 0 amappl 88 8163 0 8005 5 0 5 5 0 92 0 uvmvnodes 80 135 0 0 3 0 3 3 0 8 0 dma8192 8192 1 0 1 1 0 1 1 0 8 1 dma4096 4096 1 0 1 1 1 0 1 0 8 0 dma1024 1024 1 0 0 1 0 1 1 0 8 0 dma256 256 8 0 8 2 1 1 1 0 8 1 dma128 128 254 0 254 2 1 1 1 0 8 1 dma64 64 6 0 6 1 1 0 1 0 8 0 dma32 32 7 0 7 1 1 0 1 0 8 0 dma16 16 18 0 17 1 0 1 1 0 8 0 aobjpl 72 34 0 2 1 0 1 1 0 8 0 uaddrrnd 24 1120 0 1091 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 1120 0 1091 1 0 1 1 0 8 0 vmmpekpl 168 10317 0 10275 3 0 3 3 0 8 0 vmmpepl 168 75533 0 73762 93 1 92 92 0 357 12 vmsppl 368 1119 0 1091 4 1 3 4 0 8 0 rwobjpl 40 21437 0 20435 14 1 13 13 0 8 1 pdppl 4096 2258 0 2188 111 37 74 82 0 8 4 pvpl 32 485775 0 477332 142 22 120 120 0 265 36 pmappl 216 1125 0 1091 3 0 3 3 0 8 0 extentpl 40 45 0 27 1 0 1 1 0 8 0 phpool 112 478 0 110 12 0 12 12 0 8 0 ddb> machine ddbcpu 0 No such command ddb> trace db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:438 panic(ffffffff8336f9a2) at panic+0x1cf sys/kern/subr_prf.c:198 __assert(ffffffff833a991a,ffffffff83347771,491,ffffffff8339e6c4) at __assert+0x29 sys/kern/subr_prf.c:-1 disk_openpart(ffff800000025c48,20,6000,1) at disk_openpart+0x20d sdopen(420,1,6000,ffff80002a8f54e8) at sdopen+0x261 sys/scsi/sd.c:429 VOP_OPEN(fffffd806ba7c048,1,fffffd8007bfd340,ffff80002a8f54e8) at VOP_OPEN+0x82 sys/kern/vfs_vops.c:138 vn_open(ffff80003c93dce0,1,0) at vn_open+0x6a0 sys/kern/vfs_vnops.c:177 doopenat(ffff80002a8f54e8,ffffff9c,200000000700,0,0,ffff80003c93de80) at doopenat+0x34d sys/kern/vfs_syscalls.c:1138 syscall(ffff80003c93df30) at syscall+0x962 mi_syscall sys/sys/syscall_mi.h:-1 [inline] syscall(ffff80003c93df30) at syscall+0x962 sys/arch/amd64/amd64/trap.c:765 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x4eab66da6b0, count: -10 ddb> machine ddbcpu 1 No such command ddb> trace db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:438 panic(ffffffff8336f9a2) at panic+0x1cf sys/kern/subr_prf.c:198 __assert(ffffffff833a991a,ffffffff83347771,491,ffffffff8339e6c4) at __assert+0x29 sys/kern/subr_prf.c:-1 disk_openpart(ffff800000025c48,20,6000,1) at disk_openpart+0x20d sdopen(420,1,6000,ffff80002a8f54e8) at sdopen+0x261 sys/scsi/sd.c:429 VOP_OPEN(fffffd806ba7c048,1,fffffd8007bfd340,ffff80002a8f54e8) at VOP_OPEN+0x82 sys/kern/vfs_vops.c:138 vn_open(ffff80003c93dce0,1,0) at vn_open+0x6a0 sys/kern/vfs_vnops.c:177 doopenat(ffff80002a8f54e8,ffffff9c,200000000700,0,0,ffff80003c93de80) at doopenat+0x34d sys/kern/vfs_syscalls.c:1138 syscall(ffff80003c93df30) at syscall+0x962 mi_syscall sys/sys/syscall_mi.h:-1 [inline] syscall(ffff80003c93df30) at syscall+0x962 sys/arch/amd64/amd64/trap.c:765 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x4eab66da6b0, count: -10