panic: pool_do_get: shmpl free list modified: page 0xfffffd80683ed000; item addr 0xfffffd80683ede00; offset 0x40=0x682437b1 Stopped at db_enter+0x25: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND 37410 53799 32767 0x10 0 1 syz-executor *231022 53799 32767 0x10 0x4000000 0K syz-executor db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:438 panic(ffffffff833c733e) at panic+0x1e5 sys/kern/subr_prf.c:198 pool_do_get(ffffffff83a07150,2,ffff80003c437398) at pool_do_get+0x5ea sys/kern/subr_pool.c:-1 pool_get(ffffffff83a07150,2) at pool_get+0x149 sys/kern/subr_pool.c:-1 shmget_allocate_segment(ffff80002a2aa2a8,ffff80003c4375f0,160,ffff80003c437540) at shmget_allocate_segment+0x1a7 sys/kern/sysv_shm.c:-1 sys_shmget(ffff80002a2aa2a8,ffff80003c4375f0,ffff80003c437540) at sys_shmget+0x1b2 sys/kern/sysv_shm.c:482 syscall(ffff80003c4375f0) at syscall+0xb08 mi_syscall sys/sys/syscall_mi.h:176 [inline] syscall(ffff80003c4375f0) at syscall+0xb08 sys/arch/amd64/amd64/trap.c:579 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0xed134badac0, 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{0}> ddb{0}> set $lines = 0 ddb{0}> set $maxwidth = 0 ddb{0}> show panic *cpu0: pool_do_get: shmpl free list modified: page 0xfffffd80683ed000; item addr 0xfffffd80683ede00; offset 0x40=0x682437b1 ddb{0}> trace db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:438 panic(ffffffff833c733e) at panic+0x1e5 sys/kern/subr_prf.c:198 pool_do_get(ffffffff83a07150,2,ffff80003c437398) at pool_do_get+0x5ea sys/kern/subr_pool.c:-1 pool_get(ffffffff83a07150,2) at pool_get+0x149 sys/kern/subr_pool.c:-1 shmget_allocate_segment(ffff80002a2aa2a8,ffff80003c4375f0,160,ffff80003c437540) at shmget_allocate_segment+0x1a7 sys/kern/sysv_shm.c:-1 sys_shmget(ffff80002a2aa2a8,ffff80003c4375f0,ffff80003c437540) at sys_shmget+0x1b2 sys/kern/sysv_shm.c:482 syscall(ffff80003c4375f0) at syscall+0xb08 mi_syscall sys/sys/syscall_mi.h:176 [inline] syscall(ffff80003c4375f0) at syscall+0xb08 sys/arch/amd64/amd64/trap.c:579 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0xed134badac0, count: -8 ddb{0}> show registers rdi 0 rsi 0x1 rbp 0xffff80003c4371d0 rbx 0xffffffff83804dcf cpu_info_full_primary+0x2dcf rdx 0 rcx 0xffff80002a2aa2a8 rax 0xffffffff83803ff0 cpu_info_full_primary+0x1ff0 r8 0x101010101010101 r9 0x8080808080808080 r10 0x26104699ba098219 r11 0xed1df9d62eec2dd8 r12 0xffffffff83804bd0 cpu_info_full_primary+0x2bd0 r13 0 r14 0 r15 0x1 rip 0xffffffff826f59b5 db_enter+0x25 cs 0x8 rflags 0x246 rsp 0xffff80003c4371c0 ss 0x10 db_enter+0x25: addq $0x8,%rsp ddb{0}> show proc PROC (syz-executor) tid=231022 pid=53799 tcnt=2 stat=onproc flags process=10 proc=4000000 runpri=50, usrpri=50, slppri=16, nice=20 wchan=0x0, wmesg=, ps_single=0x0 scnt=0 ecnt=0 forw=0xffffffffffffffff, list=0xffff8000ffff19c0,0xffff80002a2aa028 process=0xffff80003c412a98 user=0xffff80003c432000, vmspace=0xfffffd806c00d028 estcpu=7, cpticks=2, pctcpu=0.0, user=0, sys=2, intr=0 ddb{0}> ps PID TID PPID UID S FLAGS WAIT COMMAND 31462 53783 95172 32767 2 0x10 syz-executor 31462 316921 95172 32767 2 0x4000010 syz-executor 12998 110501 62570 32767 2 0x10 syz-executor 53799 37410 22846 32767 7 0x10 syz-executor *53799 231022 22846 32767 7 0x4000010 syz-executor 1383 193547 36610 0 2 0x2 syz-executor 87546 289227 98023 32767 3 0x90 nanoslp syz-executor 87546 30834 98023 32767 3 0x4000090 ttyout syz-executor 87546 505953 98023 32767 3 0x4000090 fsleep syz-executor 87546 518415 98023 32767 3 0x4000090 fsleep syz-executor 29156 143643 3399 32767 3 0x90 nanoslp syz-executor 29156 31704 3399 32767 3 0x4000090 ttyout syz-executor 29156 52666 3399 32767 3 0x4000090 fsleep syz-executor 29156 435150 3399 32767 3 0x4000090 fsleep syz-executor 64716 18295 0 0 3 0x14200 bored sosplice 29367 518663 65073 32767 3 0x90 piperd syz-executor 24585 300832 68320 32767 3 0x90 piperd syz-executor 98023 510376 19720 32767 3 0x90 nanoslp syz-executor 3399 483168 63626 32767 3 0x90 nanoslp syz-executor 95172 13543 19114 32767 3 0x90 nanoslp syz-executor 62570 146745 97674 32767 3 0x90 nanoslp syz-executor 22846 403217 1167 32767 3 0x90 nanoslp syz-executor 65073 73413 36610 0 3 0x82 wait syz-executor 63626 101261 36610 0 3 0x82 wait syz-executor 19720 16107 36610 0 3 0x82 wait syz-executor 68320 357373 36610 0 3 0x82 wait syz-executor 19114 432329 36610 0 3 0x82 wait syz-executor 97674 96589 36610 0 3 0x82 wait syz-executor 1167 105606 36610 0 3 0x82 wait syz-executor 36610 389590 63367 0 2 0x2 syz-executor 63367 2394 48885 0 3 0x10008a sigsusp ksh 48885 30111 7965 0 3 0x98 kqread sshd-session 7965 218223 45154 0 3 0x92 kqread sshd-session 52737 239557 1 0 3 0x100083 ttyin getty 45154 144505 1 0 3 0x88 kqread sshd 21902 249912 31241 73 3 0x1100090 kqread syslogd 31241 217846 1 0 3 0x100082 sbwait syslogd 23667 417847 1 0 3 0x100080 kqread resolvd 98529 128540 22442 77 3 0x100092 kqread dhcpleased 82120 473341 22442 77 3 0x100092 kqread dhcpleased 22442 393150 1 0 3 0x80 kqread dhcpleased 42271 81537 0 0 3 0x14200 bored smr 60774 493476 0 0 2 0x14200 zerothread 8074 17585 0 0 3 0x14200 aiodoned aiodoned 28382 143533 0 0 3 0x14200 syncer update 96954 226869 0 0 3 0x14200 cleaner cleaner 20541 54894 0 0 3 0x14200 reaper reaper 29127 150613 0 0 3 0x14200 pgdaemon pagedaemon 9182 89245 0 0 3 0x14200 bored viomb 63050 194789 0 0 3 0x40014200 acpi0 acpi0 88317 463954 0 0 3 0x40014200 idle1 71235 355861 0 0 3 0x14200 bored softnet3 83031 284653 0 0 3 0x14200 bored softnet2 21759 50034 0 0 3 0x14200 bored softnet1 4206 145228 0 0 3 0x14200 bored softnet0 65801 51456 0 0 3 0x14200 bored systqmp 30217 377934 0 0 3 0x14200 bored systq 70781 473840 0 0 3 0x14200 tmoslp softclockmp 55870 195918 0 0 3 0x40014200 tmoslp softclock 2994 92373 0 0 3 0x40014200 idle0 1 228344 0 0 3 0x82 wait init 0 0 -1 0 3 0x10200 scheduler swapper ddb{0}> show all locks CPU 0: exclusive mutex shmpl r = 0 (0xffffffff83a07168) #0 witness_lock+0x5bb stacktrace_save sys/sys/stacktrace.h:37 [inline] #0 witness_lock+0x5bb sys/kern/subr_witness.c:1160 #1 mtx_enter_try+0x178 sys/kern/kern_lock.c:-1 #2 mtx_enter+0x60 sys/kern/kern_lock.c:239 #3 pool_get+0x10b sys/kern/subr_pool.c:583 #4 shmget_allocate_segment+0x1a7 sys/kern/sysv_shm.c:-1 #5 sys_shmget+0x1b2 sys/kern/sysv_shm.c:482 #6 syscall+0xb08 mi_syscall sys/sys/syscall_mi.h:176 [inline] #6 syscall+0xb08 sys/arch/amd64/amd64/trap.c:579 #7 Xsyscall+0x128 Process 53799 (syz-executor) thread 0xffff80002a2aa2a8 (231022) exclusive kernel_lock &kernel_lock r = 0 (0xffffffff838d2310) #0 witness_lock+0x5bb stacktrace_save sys/sys/stacktrace.h:37 [inline] #0 witness_lock+0x5bb sys/kern/subr_witness.c:1160 #1 syscall+0xae6 mi_syscall sys/sys/syscall_mi.h:176 [inline] #1 syscall+0xae6 sys/arch/amd64/amd64/trap.c:579 #2 Xsyscall+0x128 exclusive mutex shmpl r = 0 (0xffffffff83a07168) #0 witness_lock+0x5bb stacktrace_save sys/sys/stacktrace.h:37 [inline] #0 witness_lock+0x5bb sys/kern/subr_witness.c:1160 #1 mtx_enter_try+0x178 sys/kern/kern_lock.c:-1 #2 mtx_enter+0x60 sys/kern/kern_lock.c:239 #3 pool_get+0x10b sys/kern/subr_pool.c:583 #4 shmget_allocate_segment+0x1a7 sys/kern/sysv_shm.c:-1 #5 sys_shmget+0x1b2 sys/kern/sysv_shm.c:482 #6 syscall+0xb08 mi_syscall sys/sys/syscall_mi.h:176 [inline] #6 syscall+0xb08 sys/arch/amd64/amd64/trap.c:579 #7 Xsyscall+0x128 ddb{0}> show malloc Type InUse MemUse HighUse Limit Requests Type Lim devbuf 10193 10953K 10966K 166960K 11273 0 pcb 17 12K 12K 166960K 17 0 rtable 212 6K 6K 166960K 354 0 pf 29 16K 16K 166960K 31 0 ifaddr 38 6K 7K 166960K 44 0 ifgroup 46 2K 2K 166960K 50 0 sysctl 1 1K 9K 166960K 5 0 counters 64 36K 36K 166960K 66 0 ioctlops 0 0K 2K 166960K 31 0 iov 0 0K 12K 166960K 3 0 mount 1 1K 1K 166960K 1 0 log 0 0K 0K 166960K 4 0 vnodes 1334 84K 84K 166960K 1397 0 UFS quota 1 32K 32K 166960K 1 0 UFS mount 5 36K 36K 166960K 5 0 shm 2 1K 5K 166960K 3 0 VM map 2 1K 1K 166960K 2 0 sem 4 0K 0K 166960K 5 0 dirhash 12 2K 2K 166960K 12 0 ACPI 1692 195K 286K 166960K 12470 0 file desc 22 78K 125K 166960K 235 0 proc 58 79K 115K 166960K 476 0 subproc 63 3K 4K 166960K 117 0 NFS srvsock 1 0K 0K 166960K 1 0 NFS daemon 1 16K 16K 166960K 1 0 ip_moptions 0 0K 0K 166960K 23 0 in_multi 88 6K 7K 166960K 106 0 ether_multi 1 0K 0K 166960K 3 0 ISOFS mount 1 32K 32K 166960K 1 0 MSDOSFS mount 1 16K 16K 166960K 1 0 ttys 103 466K 466K 166960K 103 0 exec 0 0K 1K 166960K 361 0 fusefs mount 1 32K 32K 166960K 1 0 tdb 3 0K 0K 166960K 3 0 VM swap 8 62K 64K 166960K 10 0 UVM amap 218 159K 180K 166960K 3536 0 UVM aobj 10 5K 5K 166960K 11 0 pinsyscall 43 86K 110K 166960K 1269 0 memdesc 1 4K 4K 166960K 1 0 crypto data 1 1K 1K 166960K 1 0 ip6_options 0 0K 0K 166960K 1 0 NDP 10 0K 2K 166960K 27 0 temp 32 8662K 8727K 166960K 4131 0 kqueue 14 22K 31K 166960K 51 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 26 0 0 1 0 1 1 0 8 0 rtpcb 120 43 0 39 1 0 1 1 0 8 0 rtentry 176 111 0 12 5 0 5 5 0 8 0 unpcb 144 130 0 115 4 0 4 4 0 8 3 syncache 336 3 0 3 1 0 1 1 0 8 1 tcpcb 808 100 0 95 7 0 7 7 0 8 6 arp 128 18 0 2 1 0 1 1 0 8 0 ipq 40 1 0 0 1 0 1 1 0 8 0 ipqe 40 2 0 0 1 0 1 1 0 8 0 inpcb 384 194 0 186 3 0 3 3 0 8 1 nd6 144 24 0 3 1 0 1 1 0 8 0 kcovpl 48 13 0 6 1 0 1 1 0 8 0 art_heap8 4096 1 0 0 1 0 1 1 0 8 0 art_heap4 256 453 0 44 29 0 29 29 0 8 2 art_table 32 454 0 44 4 0 4 4 0 8 0 art_node 16 110 0 20 1 0 1 1 0 8 0 sysvmsgpl 40 5 0 2 1 0 1 1 0 8 0 semapl 112 2 0 0 1 0 1 1 0 8 0 shmpl 112 8 0 1 1 0 1 1 0 8 0 pool(0xffffffff83a07150:shmpl): page inconsistency: page 0xfffffd80683ed000; 27 on list, 7 missing, 35 items per page dirhash 1024 17 0 0 3 0 3 3 0 8 0 dino2pl 256 1641 0 132 95 0 95 95 0 8 0 ffsino 288 1641 0 132 108 0 108 108 0 8 0 nchpl 144 1923 0 247 63 0 63 63 0 8 0 uvmvnodes 80 1767 0 0 37 0 37 37 0 8 0 vnodes 216 1767 0 0 99 0 99 99 0 8 0 namei 1024 5865 0 5865 2 0 2 2 0 8 2 percpumem 16 48 0 1 1 0 1 1 0 8 0 kstatmem 264 24 0 2 2 0 2 2 0 8 0 scxspl 216 6467 0 6467 3 2 1 2 1 8 1 plimitpl 152 92 0 69 2 0 2 2 0 8 1 sigapl 424 508 0 455 8 0 8 8 0 8 0 knotepl 120 373 0 0 12 0 12 12 0 8 0 kqueuepl 224 57 0 47 2 0 2 2 0 8 0 pipepl 336 124 0 97 3 0 3 3 0 8 0 fdescpl 520 489 0 455 4 0 4 4 0 8 0 filepl 160 1932 0 1729 12 0 12 12 0 8 2 lockfpl 104 24 0 22 1 0 1 1 0 8 0 lockfspl 48 13 0 11 1 0 1 1 0 8 0 sessionpl 144 26 0 11 1 0 1 1 0 8 0 pgrppl 48 41 0 18 1 0 1 1 0 8 0 ucredpl 104 198 0 180 1 0 1 1 0 8 0 zombiepl 144 455 0 455 1 0 1 1 0 8 1 processpl 1208 508 0 455 5 0 5 5 0 8 0 procpl 656 647 0 586 6 0 6 6 0 8 0 sosppl 168 2 0 2 1 0 1 1 0 8 1 sockpl 728 367 0 340 9 0 9 9 0 8 5 mcl8k 8192 2 0 0 1 0 1 1 0 8 0 mcl4k 4096 118 0 0 15 0 15 15 0 8 0 mcl2k 2048 21 0 0 3 0 3 3 0 8 0 mtagpl 96 3 0 0 1 0 1 1 0 8 0 mbufpl 256 172 0 0 11 0 11 11 0 8 0 bufpl 280 2501 0 118 171 0 171 171 0 8 0 anonpl 32 5269 0 0 43 0 43 43 0 246 0 amapchunkpl 152 10631 0 10187 29 0 29 29 0 158 8 amappl16 200 2108 0 2093 5 1 4 5 0 8 2 amappl15 192 5 0 5 1 0 1 1 0 8 1 amappl14 184 144 0 134 1 0 1 1 0 8 0 amappl13 176 6 0 6 1 1 0 1 0 8 0 amappl12 168 1097 0 1065 2 0 2 2 0 8 0 amappl11 160 45 0 35 1 0 1 1 0 8 0 amappl10 152 7 0 7 1 1 0 1 0 8 0 amappl9 144 276 0 276 1 1 0 1 0 8 0 amappl8 136 44 0 43 1 0 1 1 0 8 0 amappl7 128 96 0 86 1 0 1 1 0 8 0 amappl6 120 178 0 174 1 0 1 1 0 8 0 amappl5 112 112 0 106 1 0 1 1 0 8 0 amappl4 104 285 0 269 1 0 1 1 0 8 0 amappl3 96 1715 0 1611 4 0 4 4 0 8 0 amappl2 88 610 0 555 2 0 2 2 0 8 0 amappl1 80 8189 0 7630 14 0 14 14 0 8 1 amappl 88 2881 0 2726 5 0 5 5 0 92 0 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 6 0 6 1 1 0 1 0 8 0 dma128 128 253 0 253 1 1 0 1 0 8 0 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 10 0 1 1 0 1 1 0 8 0 uaddrrnd 24 489 0 455 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 489 0 455 1 0 1 1 0 8 0 vmmpekpl 168 5699 0 5652 3 0 3 3 0 8 0 vmmpepl 168 37390 0 35471 95 0 95 95 0 357 6 vmsppl 480 488 0 455 7 1 6 6 0 8 1 rwobjpl 72 14741 0 12172 48 0 48 48 0 8 0 pdppl 4096 985 0 910 113 32 81 99 0 8 6 pvpl 32 12215 0 0 100 1 99 99 0 265 0 pmappl 256 488 0 455 4 1 3 3 0 8 0 extentpl 40 45 0 27 1 0 1 1 0 8 0 phpool 112 399 0 35 11 0 11 11 0 8 0 ddb{0}> machine ddbcpu 0 Invalid cpu 0 ddb{0}> trace db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:438 panic(ffffffff833c733e) at panic+0x1e5 sys/kern/subr_prf.c:198 pool_do_get(ffffffff83a07150,2,ffff80003c437398) at pool_do_get+0x5ea sys/kern/subr_pool.c:-1 pool_get(ffffffff83a07150,2) at pool_get+0x149 sys/kern/subr_pool.c:-1 shmget_allocate_segment(ffff80002a2aa2a8,ffff80003c4375f0,160,ffff80003c437540) at shmget_allocate_segment+0x1a7 sys/kern/sysv_shm.c:-1 sys_shmget(ffff80002a2aa2a8,ffff80003c4375f0,ffff80003c437540) at sys_shmget+0x1b2 sys/kern/sysv_shm.c:482 syscall(ffff80003c4375f0) at syscall+0xb08 mi_syscall sys/sys/syscall_mi.h:176 [inline] syscall(ffff80003c4375f0) at syscall+0xb08 sys/arch/amd64/amd64/trap.c:579 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0xed134badac0, count: -8 ddb{0}> machine ddbcpu 1 Stopped at x86_ipi_db+0x27: addq $0x8,%rsp x86_ipi_db(ffff8000299ddff0) at x86_ipi_db+0x27 sys/arch/amd64/amd64/db_interface.c:394 x86_ipi_handler() at x86_ipi_handler+0xd9 sys/arch/amd64/amd64/ipi.c:106 Xresume_lapic_ipi() at Xresume_lapic_ipi+0x27 end of kernel end trace frame: 0x7b67a8609aa0, count: 12 ddb{1}> trace x86_ipi_db(ffff8000299ddff0) at x86_ipi_db+0x27 sys/arch/amd64/amd64/db_interface.c:394 x86_ipi_handler() at x86_ipi_handler+0xd9 sys/arch/amd64/amd64/ipi.c:106 Xresume_lapic_ipi() at Xresume_lapic_ipi+0x27 end of kernel end trace frame: 0x7b67a8609aa0, count: -3