panic: pool_do_get: shmpl free list modified: page 0xfffffd8077512000; item addr 0xfffffd8077512630; offset 0x10=0xdead4000 Stopped at db_enter+0x18: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND 34438 15388 0 0 0 0 syz-executor.1 *333453 73489 60929 0x10 0x4000000 1K syz-executor.0 db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:398 panic() at panic+0x15c sys/kern/subr_prf.c:212 pool_do_get(ffffffff8235e8f8,1,ffff800023e4b248) at pool_do_get+0x483 sys/kern/subr_pool.c:744 pool_get() at pool_get+0xeb sys/kern/subr_pool.c:581 shmget_allocate_segment(ffff800020b61398,ffff800023e4b3d8,0,ffff800023e4b440) at shmget_allocate_segment+0x15e sys/kern/sysv_shm.c:409 sys_shmget(ffff800020b61398,ffff800023e4b3d8,ffff800023e4b440) at sys_shmget+0x13f sys/kern/sysv_shm.c:472 syscall(ffff800023e4b4b0) at syscall+0x552 mi_syscall sys/sys/syscall_mi.h:90 [inline] syscall(ffff800023e4b4b0) at syscall+0x552 sys/arch/amd64/amd64/trap.c:554 Xsyscall(6,0,fffffffffffffff4,0,4,67da2145010) at Xsyscall+0x128 end of kernel end trace frame: 0x6807b351870, count: 7 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}> set $maxwidth = 0 ddb{1}> show panic pool_do_get: shmpl free list modified: page 0xfffffd8077512000; item addr 0xfffffd8077512630; offset 0x10=0xdead4000 ddb{1}> trace db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:398 panic() at panic+0x15c sys/kern/subr_prf.c:212 pool_do_get(ffffffff8235e8f8,1,ffff800023e4b248) at pool_do_get+0x483 sys/kern/subr_pool.c:744 pool_get() at pool_get+0xeb sys/kern/subr_pool.c:581 shmget_allocate_segment(ffff800020b61398,ffff800023e4b3d8,0,ffff800023e4b440) at shmget_allocate_segment+0x15e sys/kern/sysv_shm.c:409 sys_shmget(ffff800020b61398,ffff800023e4b3d8,ffff800023e4b440) at sys_shmget+0x13f sys/kern/sysv_shm.c:472 syscall(ffff800023e4b4b0) at syscall+0x552 mi_syscall sys/sys/syscall_mi.h:90 [inline] syscall(ffff800023e4b4b0) at syscall+0x552 sys/arch/amd64/amd64/trap.c:554 Xsyscall(6,0,fffffffffffffff4,0,4,67da2145010) at Xsyscall+0x128 end of kernel end trace frame: 0x6807b351870, count: -8 ddb{1}> show registers rdi 0xffffffff8168b087 db_enter+0x17 rsi 0x295f __ALIGN_SIZE+0x195f rbp 0xffff800023e4b090 rbx 0xffff800023e4b140 rdx 0x2960 __ALIGN_SIZE+0x1960 rcx 0xffff800020c0c000 rax 0xffff800020c0c000 r8 0xffffffff81633a63 kprintf+0x173 r9 0x1 r10 0x25 r11 0x63d1592424a5c85f r12 0x3000000008 r13 0xffff800023e4b0a0 r14 0x100 r15 0x1 rip 0xffffffff8168b088 db_enter+0x18 cs 0x8 rflags 0x246 rsp 0xffff800023e4b080 ss 0x10 db_enter+0x18: addq $0x8,%rsp ddb{1}> show proc PROC (syz-executor.0) pid=333453 stat=onproc flags process=10 proc=4000000 pri=80, usrpri=80, nice=20 forw=0xffffffffffffffff, list=0xffff800020b60c48,0xffff800020b61618 process=0xffff800020b8d3c8 user=0xffff800023e46000, vmspace=0xfffffd807f00ba10 estcpu=36, cpticks=5, pctcpu=0.0 user=0, sys=1, intr=0 ddb{1}> ps PID TID PPID UID S FLAGS WAIT COMMAND 15388 34438 16867 0 7 0 syz-executor.1 15388 275229 16867 0 3 0x4000080 nanosleep syz-executor.1 73489 221213 79656 60929 2 0x10 syz-executor.0 *73489 333453 79656 60929 7 0x4000010 syz-executor.0 73489 318940 79656 60929 3 0x4000090 fsleep syz-executor.0 73489 340866 79656 60929 3 0x4000090 fsleep syz-executor.0 79656 447147 63986 0 3 0x82 nanosleep syz-executor.0 61358 70555 0 0 3 0x14200 bored sosplice 16867 476387 63986 0 3 0x82 nanosleep syz-executor.1 63986 140472 70836 0 3 0x82 thrsleep syz-fuzzer 63986 390432 70836 0 3 0x4000082 thrsleep syz-fuzzer 63986 251445 70836 0 3 0x4000082 thrsleep syz-fuzzer 63986 434674 70836 0 3 0x4000082 kqread syz-fuzzer 63986 506764 70836 0 3 0x4000082 thrsleep syz-fuzzer 63986 309088 70836 0 3 0x4000082 thrsleep syz-fuzzer 63986 33817 70836 0 3 0x4000082 thrsleep syz-fuzzer 63986 153576 70836 0 3 0x4000082 thrsleep syz-fuzzer 63986 385200 70836 0 3 0x4000082 thrsleep syz-fuzzer 63986 167678 70836 0 3 0x4000082 thrsleep syz-fuzzer 70836 391594 96184 0 3 0x10008a pause ksh 96184 440120 28779 0 3 0x92 select sshd 88967 110548 1 0 3 0x100083 ttyin getty 28779 12091 1 0 3 0x80 select sshd 77103 377966 66031 74 3 0x100092 bpf pflogd 66031 312457 1 0 3 0x80 netio pflogd 32219 356202 63502 73 3 0x100090 kqread syslogd 63502 124261 1 0 3 0x100082 netio syslogd 62758 58954 1 77 3 0x100090 poll dhclient 43367 274149 1 0 3 0x80 poll dhclient 46939 47406 0 0 2 0x14200 zerothread 31863 459738 0 0 3 0x14200 aiodoned aiodoned 81684 164822 0 0 3 0x14200 syncer update 843 346445 0 0 3 0x14200 cleaner cleaner 8350 477893 0 0 3 0x14200 reaper reaper 81151 312285 0 0 3 0x14200 pgdaemon pagedaemon 74355 446776 0 0 3 0x14200 bored crynlk 30608 395955 0 0 3 0x14200 bored crypto 14562 480504 0 0 3 0x40014200 acpi0 acpi0 73921 482559 0 0 3 0x40014200 idle1 6226 362751 0 0 3 0x14200 bored softnet 60688 107347 0 0 3 0x14200 bored systqmp 9336 144649 0 0 3 0x14200 bored systq 80326 172124 0 0 3 0x40014200 bored softclock 44923 32636 0 0 3 0x40014200 idle0 77386 395239 0 0 3 0x14200 bored smr 1 188669 0 0 3 0x82 wait init 0 0 -1 0 3 0x10200 scheduler swapper ddb{1}> show all locks CPU 1: exclusive mutex shmpl r = 0 (0xffffffff8235e908) #0 witness_lock+0x52e sys/kern/subr_witness.c:1161 #1 mtx_enter_try+0x102 #2 mtx_enter+0x4b sys/kern/kern_lock.c:266 #3 pool_get+0xbf sys/kern/subr_pool.c:578 #4 shmget_allocate_segment+0x15e sys/kern/sysv_shm.c:409 #5 sys_shmget+0x13f sys/kern/sysv_shm.c:472 #6 syscall+0x552 mi_syscall sys/sys/syscall_mi.h:90 [inline] #6 syscall+0x552 sys/arch/amd64/amd64/trap.c:554 #7 Xsyscall+0x128 Process 73489 (syz-executor.0) thread 0xffff800020b61398 (333453) exclusive kernel_lock &kernel_lock r = 0 (0xffffffff82348b80) #0 witness_lock+0x52e sys/kern/subr_witness.c:1161 #1 syscall+0x412 mi_syscall sys/sys/syscall_mi.h:81 [inline] #1 syscall+0x412 sys/arch/amd64/amd64/trap.c:554 #2 Xsyscall+0x128 exclusive mutex shmpl r = 0 (0xffffffff8235e908) #0 witness_lock+0x52e sys/kern/subr_witness.c:1161 #1 mtx_enter_try+0x102 #2 mtx_enter+0x4b sys/kern/kern_lock.c:266 #3 pool_get+0xbf sys/kern/subr_pool.c:578 #4 shmget_allocate_segment+0x15e sys/kern/sysv_shm.c:409 #5 sys_shmget+0x13f sys/kern/sysv_shm.c:472 #6 syscall+0x552 mi_syscall sys/sys/syscall_mi.h:90 [inline] #6 syscall+0x552 sys/arch/amd64/amd64/trap.c:554 #7 Xsyscall+0x128 ddb{1}> show malloc Type InUse MemUse HighUse Limit Requests Type Lim Kern Lim devbuf 9532 6433K 7577K 78643K 14475 0 0 pcb 25 9K 11K 78643K 735 0 0 rtable 120 4K 5K 78643K 809 0 0 ifaddr 63 14K 14K 78643K 257 0 0 counters 39 33K 33K 78643K 39 0 0 ioctlops 0 0K 4K 78643K 1526 0 0 iov 0 0K 24K 78643K 184 0 0 mount 1 1K 1K 78643K 1 0 0 vnodes 1205 76K 77K 78643K 2759 0 0 UFS quota 1 32K 32K 78643K 1 0 0 UFS mount 5 36K 36K 78643K 5 0 0 shm 2 1K 5K 78643K 24 0 0 VM map 2 1K 1K 78643K 2 0 0 sem 12 0K 0K 78643K 122 0 0 dirhash 12 2K 2K 78643K 12 0 0 ACPI 1808 196K 290K 78643K 12628 0 0 file desc 6 17K 25K 78643K 1739 0 0 sigio 0 0K 0K 78643K 10 0 0 proc 54 51K 83K 78643K 774 0 0 subproc 32 2K 2K 78643K 136 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 141 0 0 in_multi 33 2K 2K 78643K 146 0 0 ether_multi 1 0K 0K 78643K 5 0 0 mrt 0 0K 0K 78643K 2 0 0 ISOFS mount 1 32K 32K 78643K 1 0 0 MSDOSFS mount 1 16K 16K 78643K 1 0 0 ttys 96 424K 424K 78643K 96 0 0 exec 0 0K 1K 78643K 375 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 94 21K 30K 78643K 6563 0 0 UVM aobj 81 3K 3K 78643K 86 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 73 0 0 NDP 13 0K 0K 78643K 76 0 0 temp 181 2736K 3366K 78643K 9161 0 0 kqueue 0 0K 0K 78643K 19 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 18 0 12 1 0 1 1 0 8 0 inpcbpl 280 714 0 707 1 0 1 1 0 8 0 plcache 128 20 0 0 1 0 1 1 0 8 0 rtentry 112 123 0 75 2 0 2 2 0 8 0 syncache 264 4 0 4 1 1 0 1 0 8 0 tcpqe 32 35 0 35 1 1 0 1 0 8 0 tcpcb 544 233 0 229 1 0 1 1 0 8 0 nd6 48 24 0 18 1 0 1 1 0 8 0 ppxss 1128 37 0 36 7 6 1 1 0 8 0 pfosfp 40 846 0 423 5 0 5 5 0 8 0 pfosfpen 112 1428 0 714 21 0 21 21 0 8 0 pfstitem 24 35 0 24 1 0 1 1 0 8 0 pfstkey 112 35 0 24 1 0 1 1 0 8 0 pfstate 328 35 0 24 2 0 2 2 0 8 0 pfrule 1360 21 0 16 2 1 1 2 0 8 0 art_heap8 4096 1 0 0 1 0 1 1 0 8 0 art_heap4 256 452 0 264 12 0 12 12 0 8 0 art_table 32 453 0 264 2 0 2 2 0 8 0 art_node 16 114 0 74 1 0 1 1 0 8 0 sysvmsgpl 40 17 0 5 1 0 1 1 0 8 0 semupl 112 1 0 1 1 1 0 1 0 8 0 semapl 112 120 0 110 1 0 1 1 0 8 0 shmpl 112 84 0 5 3 0 3 3 0 8 0 shmpl: pool(0xffffffff8235e8f8:shmpl): page inconsistency: page 0xfffffd8077512000; item ordinal 0; addr 0x624afd9d1cdd0d74 dirhash 1024 17 0 0 3 0 3 3 0 8 0 dino1pl 128 4109 0 2679 47 0 47 47 0 8 0 ffsino 272 4109 0 2679 96 0 96 96 0 8 0 nchpl 144 6570 0 4937 61 0 61 61 0 8 0 uvmvnodes 72 5168 0 0 94 0 94 94 0 8 0 vnodes 200 5168 0 0 272 0 272 272 0 8 0 namei 1024 20647 0 20647 3 2 1 1 0 8 1 percpumem 16 30 0 0 1 0 1 1 0 8 0 scsiplug 64 3 0 3 1 1 0 1 0 8 0 scxspl 192 19554 0 19554 12 11 1 6 0 8 1 plimitpl 152 78 0 70 1 0 1 1 0 8 0 sigapl 432 1921 0 1905 3 1 2 3 0 8 0 futexpl 56 17920 0 17918 2 1 1 1 0 8 0 knotepl 112 416 0 397 1 0 1 1 0 8 0 kqueuepl 104 340 0 337 1 0 1 1 0 8 0 pipepl 112 1062 0 1043 4 3 1 2 0 8 0 fdescpl 488 1922 0 1905 3 0 3 3 0 8 0 filepl 152 10848 0 10744 9 4 5 7 0 8 0 lockfpl 104 501 0 500 3 2 1 1 0 8 0 lockfspl 48 185 0 184 3 2 1 1 0 8 0 sessionpl 112 24 0 13 1 0 1 1 0 8 0 pgrppl 48 32 0 21 1 0 1 1 0 8 0 ucredpl 96 2281 0 2271 1 0 1 1 0 8 0 zombiepl 144 1905 0 1905 3 2 1 1 0 8 1 processpl 840 1938 0 1905 4 0 4 4 0 8 0 procpl 624 5533 0 5487 4 0 4 4 0 8 0 srpgc 64 36 0 36 1 1 0 1 0 8 0 sosppl 128 31 0 31 8 7 1 1 0 8 1 sockpl 384 1352 0 1333 6 3 3 4 0 8 1 mcl64k 65536 265 0 0 34 3 31 34 0 8 1 mcl16k 16384 2 0 0 1 0 1 1 0 8 0 mcl12k 12288 10 0 0 1 0 1 1 0 8 0 mcl9k 9216 14 0 0 1 0 1 1 0 8 0 mcl8k 8192 4 0 0 1 0 1 1 0 8 0 mcl4k 4096 11 0 0 2 0 2 2 0 8 0 mcl2k2 2112 3 0 0 1 0 1 1 0 8 0 mcl2k 2048 177 0 0 21 0 21 21 0 8 0 mtagpl 80 4 0 0 1 0 1 1 0 8 0 mbufpl 256 430 0 0 21 0 21 21 0 8 0 bufpl 256 9406 0 2398 439 0 439 439 0 8 0 anonpl 16 173265 0 162521 112 55 57 59 0 125 12 amapchunkpl 152 11273 0 11157 17 12 5 10 0 158 0 amappl16 192 8255 0 7669 87 52 35 41 0 8 5 amappl15 184 801 0 798 1 0 1 1 0 8 0 amappl14 176 875 0 870 2 1 1 1 0 8 0 amappl13 168 2 0 2 1 1 0 1 0 8 0 amappl12 160 81 0 81 2 2 0 1 0 8 0 amappl11 152 840 0 819 1 0 1 1 0 8 0 amappl10 144 94 0 90 1 0 1 1 0 8 0 amappl9 136 676 0 673 1 0 1 1 0 8 0 amappl8 128 195 0 180 1 0 1 1 0 8 0 amappl7 120 61 0 55 1 0 1 1 0 8 0 amappl6 112 798 0 790 1 0 1 1 0 8 0 amappl5 104 240 0 226 1 0 1 1 0 8 0 amappl4 96 1264 0 1236 2 1 1 2 0 8 0 amappl3 88 1848 0 1834 1 0 1 1 0 8 0 amappl2 80 14004 0 13926 4 2 2 3 0 8 0 amappl1 72 51129 0 50665 25 15 10 20 0 8 0 amappl 80 5867 0 5826 1 0 1 1 0 84 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 85 0 5 2 0 2 2 0 8 0 uaddrrnd 24 1922 0 1905 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 1922 0 1905 1 0 1 1 0 8 0 vmmpekpl 168 18025 0 17993 2 0 2 2 0 8 0 vmmpepl 168 211505 0 209761 139 55 84 89 0 357 8 vmsppl 368 1921 0 1905 2 0 2 2 0 8 0 pdppl 4096 3851 0 3810 6 0 6 6 0 8 0 pvpl 32 517479 0 502901 228 82 146 148 0 265 28 pmappl 232 1921 0 1905 2 1 1 2 0 8 0 extentpl 40 41 0 26 1 0 1 1 0 8 0 phpool 112 651 0 8 19 0 19 19 0 8 0