syzbot
uvm_fault: sys_shmat (3)
Status:
upstream: reported on 2026/06/24 23:01
Reported-by: syzbot+f5d2ec16c4993e11ed9e@syzkaller.appspotmail.com
First crash: 79d, last: 1d16h
Sample crash report:
uvm_fault(0xfffff8806cf5eb98, 0x0, 0, 1) -> e
kernel: page fault trap, code=0
Stopped at sys_shmat+0x453: movq 0(%r15),%rdi
TID PID UID PRFLAGS PFLAGS CPU COMMAND
170818 583 0 0 0 0 syz-executor
* 69760 10879 0 0 0x4000000 1K syz-executor
sys_shmat(ffff800045ffd4c8,ffff80002a2b2e40,ffff80002a2b2d90) at sys_shmat+0x453 sys/kern/sysv_shm.c:290
syscall(ffff80002a2b2e40) at syscall+0xb17 mi_syscall sys/sys/syscall_mi.h:176 [inline]
syscall(ffff80002a2b2e40) at syscall+0xb17 sys/arch/amd64/amd64/trap.c:791
Xsyscall() at Xsyscall+0x128
end of kernel
end trace frame: 0xe637ad81c10, count: 12
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
*cpu1: uvm_fault(0xfffff8806cf5eb98, 0x0, 0, 1) -> e
ddb{1}> show kasan
No such command
ddb{1}> trace
sys_shmat(ffff800045ffd4c8,ffff80002a2b2e40,ffff80002a2b2d90) at sys_shmat+0x453 sys/kern/sysv_shm.c:290
syscall(ffff80002a2b2e40) at syscall+0xb17 mi_syscall sys/sys/syscall_mi.h:176 [inline]
syscall(ffff80002a2b2e40) at syscall+0xb17 sys/arch/amd64/amd64/trap.c:791
Xsyscall() at Xsyscall+0x128
end of kernel
end trace frame: 0xe637ad81c10, count: -3
ddb{1}> show registers
rdi 0
rsi 0x2000 __ALIGN_SIZE+0x1000
rbp 0xffff80002a2b2d60
rbx 0xfffff8807ca75ee8
rdx 0
rcx 0
rax 0
r8 0x100
r9 0xfffff880097fd208
r10 0
r11 0xe8842df077c790ff
r12 0xffff800045ffd4c8
r13 0xffff800001602010
r14 0x1
r15 0
rip 0xffffffff832350f3 sys_shmat+0x453
cs 0x8
rflags 0x10246 __ALIGN_SIZE+0xf246
rsp 0xffff80002a2b2cd0
ss 0x10
sys_shmat+0x453: movq 0(%r15),%rdi
ddb{1}> show proc
PROC (syz-executor) tid=69760 pid=10879 tcnt=4 stat=onproc
flags process=0 proc=4000000<THREAD>
runpri=86, usrpri=86, slppri=32, nice=20
wchan=0x0, wmesg=, ps_single=0x0 scnt=0 ecnt=0
forw=0xffffffffffffffff, list=0xffff800045ffc008,0xffff800045ffdca0
process=0xffff800045fef508 user=0xffff80002a2ad000, vmspace=0xfffff8806cf5eb98
estcpu=36, cpticks=1, pctcpu=0.0, user=0, sys=1, intr=0
ddb{1}> ps
PID TID PPID UID S PRLAGS PFLAGS WAIT COMMAND
92061 476834 33842 0 2 0x100002 0 sh
583 170818 67592 0 7 0 0 syz-executor
583 30937 67592 0 3 0 0x4000080 fsleep syz-executor
583 267988 67592 0 2 0 0x4000000 syz-executor
43825 241339 37195 0 2 0 0 syz-executor
43825 95669 37195 0 3 0 0x4000080 fsleep syz-executor
85316 437336 30265 0 2 0 0 syz-executor
85316 243643 30265 0 3 0 0x4000080 fsleep syz-executor
85316 411392 30265 0 3 0 0x4000080 fsleep syz-executor
85316 353464 30265 0 3 0 0x4000080 fsleep syz-executor
10879 160550 41758 0 2 0 0 syz-executor
10879 352231 41758 0 2 0 0x4000000 syz-executor
*10879 69760 41758 0 7 0 0x4000000 syz-executor
10879 50462 41758 0 2 0 0x4000000 syz-executor
33842 135338 74166 0 3 0x2 0x80 wait syz-executor
56685 522480 74166 0 2 0x2 0 syz-executor
53884 199567 22526 0 3 0x100002 0x80 sbwait arp
22526 27891 99716 0 3 0x100002 0x88 sigsusp sh
99716 42533 74166 0 3 0x2 0x80 wait syz-executor
67592 492195 74166 0 3 0x2 0x80 nanoslp syz-executor
10003 391354 74166 0 2 0x2 0x1 syz-executor
37195 373066 74166 0 3 0x2 0x80 nanoslp syz-executor
41758 199055 74166 0 3 0x2 0x80 nanoslp syz-executor
30265 513271 74166 0 3 0x2 0x80 nanoslp syz-executor
74166 99433 94345 0 3 0x2 0x80 kqread syz-executor
94345 202655 92798 0 3 0x100002 0x88 sigsusp ksh
92798 226594 69391 0 3 0x10 0x88 kqread sshd-session
69391 162258 67383 0 3 0x12 0x80 kqread sshd-session
72235 498250 1 0 3 0x100003 0x80 ttyin getty
67383 352518 1 0 3 0 0x88 kqread sshd
45710 236505 98320 74 3 0x1100012 0x80 bpf pflogd
98320 267668 1 0 3 0 0x80 sbwait pflogd
42677 183117 41245 73 3 0x1100010 0x80 kqread syslogd
41245 170066 1 0 3 0x100002 0x80 sbwait syslogd
94118 508350 1 0 3 0x100000 0x80 kqread resolvd
15136 204614 17987 77 3 0x100012 0x80 kqread dhcpleased
86746 311879 17987 77 3 0x100012 0x80 kqread dhcpleased
17987 412936 1 0 3 0 0x80 kqread dhcpleased
49419 90673 0 0 3 0x14000 0x200 bored smr
93368 503510 0 0 2 0x14000 0x200 zerothread
79216 19058 0 0 3 0x14000 0x200 aiodoned aiodoned
57239 246226 0 0 3 0x14000 0x200 syncer update
39305 110275 0 0 3 0x14000 0x200 cleaner cleaner
19207 331374 0 0 3 0x14000 0x200 reaper reaper
53838 165911 0 0 3 0x14000 0x200 pgdaemon pagedaemon
36229 253111 0 0 3 0x14000 0x200 bored viomb
36360 317574 0 0 3 0x14000 0x40000200 acpi0 acpi0
76812 523262 0 0 3 0x14000 0x40000200 idle1
43313 67319 0 0 3 0x14000 0x200 bored softnet1
13788 256719 0 0 3 0x14000 0x200 bored softnet0
90097 64508 0 0 3 0x14000 0x200 smrbar systqmp
59042 401551 0 0 3 0x14000 0x200 bored systq
48342 333644 0 0 3 0x14000 0x200 tmoslp softclockmp
84251 506578 0 0 3 0x14000 0x40000200 tmoslp softclock
25736 24292 0 0 3 0x14000 0x40000200 idle0
1 24195 0 0 3 0x2 0x80 wait init
0 0 -1 0 3 0x10000 0x200 scheduler swapper
ddb{1}> show all locks
Process 583 (syz-executor) thread 0xffff800045fead18 (267988)
exclusive rwlock vmmaplk r = 0 (0xfffff8806cf5e4f8)
#0 witness_lock+0x5f1 stacktrace_save sys/sys/stacktrace.h:37 [inline]
#0 witness_lock+0x5f1 sys/kern/subr_witness.c:1160
#1 rw_do_enter_read+0x3e8 sys/kern/kern_rwlock.c:413
#2 uvmfault_lookup+0x122 sys/uvm/uvm_fault.c:1880
#3 uvm_fault_check+0x4f sys/uvm/uvm_fault.c:693
#4 uvm_fault+0x106 sys/uvm/uvm_fault.c:627
#5 upageflttrap+0xa9 sys/arch/amd64/amd64/trap.c:194
#6 usertrap+0x430 sys/arch/amd64/amd64/trap.c:648
#7 recall_trap+0x8
Process 10879 (syz-executor) thread 0xffff800045ffd4c8 (69760)
exclusive kernel_lock &kernel_lock r = 0 (0xffffffff83ad7b00)
#0 witness_lock+0x5f1 stacktrace_save sys/sys/stacktrace.h:37 [inline]
#0 witness_lock+0x5f1 sys/kern/subr_witness.c:1160
#1 __mp_acquire_count+0x58 sys/kern/kern_lock.c:-1
#2 malloc+0xe3 sys/kern/kern_malloc.c:175
#3 sys_shmat+0x9f sys/kern/sysv_shm.c:-1
#4 syscall+0xb17 mi_syscall sys/sys/syscall_mi.h:176 [inline]
#4 syscall+0xb17 sys/arch/amd64/amd64/trap.c:791
#5 Xsyscall+0x128
Process 56685 (syz-executor) thread 0xffff800045fea020 (522480)
exclusive rrwlock inode r = 0 (0xfffff8806bb7f318)
#0 witness_lock+0x5f1 stacktrace_save sys/sys/stacktrace.h:37 [inline]
#0 witness_lock+0x5f1 sys/kern/subr_witness.c:1160
#1 rw_do_enter_write+0x419 sys/kern/kern_rwlock.c:320
#2 rrw_enter+0xc6 sys/kern/kern_rwlock.c:621
#3 VOP_LOCK+0xbd sys/kern/vfs_vops.c:527
#4 vn_lock+0xa4 sys/kern/vfs_vnops.c:576
#5 vfs_lookup+0x12b sys/kern/vfs_lookup.c:431
#6 namei+0x7c5 sys/kern/vfs_lookup.c:250
#7 domkdirat+0x8b sys/kern/vfs_syscalls.c:3048
#8 syscall+0xb17 mi_syscall sys/sys/syscall_mi.h:176 [inline]
#8 syscall+0xb17 sys/arch/amd64/amd64/trap.c:791
#9 Xsyscall+0x128
Process 90097 (systqmp) thread 0xffff800045ffe000 (64508)
shared rwlock systqmp r = 0 (0xffffffff83961388)
#0 witness_lock+0x5f1 stacktrace_save sys/sys/stacktrace.h:37 [inline]
#0 witness_lock+0x5f1 sys/kern/subr_witness.c:1160
#1 taskq_thread+0x12a sys/kern/kern_task.c:442
#2 proc_trampoline+0x10
ddb{1}> show malloc
Type InUse MemUse HighUse Limit Requests Type Lim
devbuf 11054 12085K 12093K 166960K 12157 0
pcb 17 12K 12K 166960K 23 0
rtable 225 8K 8K 166960K 406 0
pf 34 17K 24K 166960K 71 0
ifaddr 41 7K 7K 166960K 51 0
ifgroup 55 2K 2K 166960K 63 0
sysctl 3 1K 9K 166960K 7 0
counters 70 37K 37K 166960K 74 0
ioctlops 0 0K 4K 166960K 1487 0
mount 1 1K 1K 166960K 1 0
log 0 0K 0K 166960K 4 0
vnodes 1290 81K 81K 166960K 1391 0
UFS quota 1 32K 32K 166960K 1 0
UFS mount 5 36K 36K 166960K 5 0
shm 3 5K 5K 166960K 4 0
VM map 2 1K 1K 166960K 2 0
sem 2 0K 0K 166960K 2 0
dirhash 12 2K 2K 166960K 12 0
ACPI 1692 195K 286K 166960K 12470 0
file desc 17 61K 89K 166960K 186 0
proc 70 115K 180K 166960K 602 0
subproc 72 4K 4K 166960K 90 0
NFS srvsock 1 0K 0K 166960K 1 0
NFS daemon 1 16K 16K 166960K 1 0
ip_moptions 0 0K 0K 166960K 5 0
in_multi 89 6K 6K 166960K 111 0
ether_multi 1 0K 0K 166960K 1 0
mrt 0 0K 0K 166960K 1 0
ISOFS mount 1 32K 32K 166960K 1 0
MSDOSFS mount 1 16K 16K 166960K 1 0
ttys 49 228K 228K 166960K 49 0
exec 0 0K 1K 166960K 417 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 224 170K 176K 166960K 3497 0
UVM aobj 4 2K 2K 166960K 5 0
pinsyscall 43 86K 102K 166960K 1412 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 16 0K 1K 166960K 32 0
temp 38 9114K 9135K 166960K 5656 0
kqueue 13 20K 24K 166960K 31 0
SYN cache 2 16K 16K 166960K 2 0
ddb{1}> 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 42 0 38 1 0 1 1 0 8 0
rtentry 176 124 0 23 5 0 5 5 0 8 0
unpcb 144 56 0 37 1 0 1 1 0 8 0
syncache 336 4 0 4 1 1 0 1 0 8 0
tcpcb 736 78 0 74 7 6 1 7 0 8 0
arp 136 21 0 4 1 0 1 1 0 8 0
inpcb 328 159 0 152 7 5 2 6 0 8 1
nd6 152 26 0 6 1 0 1 1 0 8 0
kcovpl 48 10 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
pfanchor 1288 4 0 4 1 0 1 1 0 8 1
pfstitem 24 28 0 0 1 0 1 1 0 8 0
pfstkey 128 28 0 0 1 0 1 1 0 8 0
pfstate 448 28 0 0 4 0 4 4 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 499 0 88 26 0 26 26 0 8 0
art_table 40 500 0 88 5 0 5 5 0 8 0
art_node 32 124 0 31 1 0 1 1 0 8 0
sysvmsgpl 40 1 0 0 1 0 1 1 0 8 0
shmpl 112 2 0 1 2 1 1 1 0 8 0
dirhash 1024 17 0 0 3 0 3 3 0 8 0
dino2pl 256 1610 0 139 93 0 93 93 0 8 0
ffsino 296 1610 0 139 114 0 114 114 0 8 0
nchpl 144 1846 0 139 64 0 64 64 0 8 0
vnodes 216 1722 0 0 96 0 96 96 0 8 0
namei 1024 6661 0 6660 5 3 2 2 0 8 1
percpumem 16 53 0 2 1 0 1 1 0 8 0
kstatmem 264 31 0 4 2 0 2 2 0 8 0
scxspl 216 6364 0 6364 4 3 1 3 1 8 1
plimitpl 152 37 0 20 1 0 1 1 0 8 0
sigapl 424 508 0 461 7 1 6 7 0 8 0
knotepl 120 57 0 0 2 0 2 2 0 8 0
kqueuepl 224 29 0 20 1 0 1 1 0 8 0
pipepl 344 138 0 111 3 0 3 3 0 8 0
fdescpl 528 492 0 461 3 0 3 3 0 8 0
filepl 160 1831 0 1618 12 2 10 12 0 8 0
lockfpl 104 14 0 11 1 0 1 1 0 8 0
lockfspl 48 8 0 5 1 0 1 1 0 8 0
sessionpl 144 26 0 17 1 0 1 1 0 8 0
pgrppl 48 36 0 19 1 0 1 1 0 8 0
ucredpl 104 116 0 103 1 0 1 1 0 8 0
zombiepl 144 471 0 471 1 0 1 1 0 8 1
processpl 1232 508 0 461 5 0 5 5 0 8 0
procpl 664 569 0 512 6 1 5 6 0 8 0
sockpl 752 258 0 228 10 6 4 10 0 8 0
mcl64k 65536 2 0 0 1 0 1 1 0 8 0
mcl8k 8192 1 0 0 1 0 1 1 0 8 0
mcl4k 4096 116 0 0 15 0 15 15 0 8 0
mcl2k 2048 25 0 0 4 0 4 4 0 8 0
mextrefs 64 20 0 0 1 0 1 1 0 8 0
mtagpl 96 3 0 0 1 0 1 1 0 8 0
mbufpl 256 218 0 0 14 0 14 14 0 8 0
bufpl 272 2333 0 105 149 0 149 149 0 8 0
anonpl 32 3834 0 0 31 0 31 31 0 247 0
amapchunkpl 152 9470 0 9040 20 1 19 19 0 158 1
amappl16 200 1881 0 1865 5 4 1 5 0 8 0
amappl15 192 6 0 6 1 1 0 1 0 8 0
amappl14 184 461 0 458 1 0 1 1 0 8 0
amappl13 176 127 0 114 1 0 1 1 0 8 0
amappl12 168 760 0 730 2 0 2 2 0 8 0
amappl11 160 2 0 2 1 1 0 1 0 8 0
amappl10 152 63 0 49 1 0 1 1 0 8 0
amappl9 144 276 0 275 1 0 1 1 0 8 0
amappl8 136 113 0 111 1 0 1 1 0 8 0
amappl7 128 154 0 139 1 0 1 1 0 8 0
amappl6 120 175 0 172 1 0 1 1 0 8 0
amappl5 112 103 0 93 1 0 1 1 0 8 0
amappl4 104 304 0 284 1 0 1 1 0 8 0
amappl3 96 1627 0 1541 3 0 3 3 0 8 0
amappl2 88 612 0 534 2 0 2 2 0 8 0
amappl1 80 10886 0 10259 15 1 14 15 0 8 0
amappl 88 2732 0 2585 4 0 4 4 0 92 0
uvmvnodes 80 99 0 0 3 0 3 3 0 8 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 4 0 1 1 0 1 1 0 8 0
uaddrrnd 24 493 0 462 1 0 1 1 0 8 0
uaddrbest 32 2 0 0 1 0 1 1 0 8 0
uaddr 24 493 0 462 1 0 1 1 0 8 0
vmmpekpl 168 6017 0 5970 3 0 3 3 0 8 0
vmmpepl 168 41247 0 39395 88 2 86 88 0 357 1
vmsppl 488 492 0 462 6 1 5 5 0 8 0
rwobjpl 80 15423 0 14373 24 1 23 24 0 8 0
pdppl 4096 993 0 924 105 30 75 83 0 8 6
pvpl 32 10035 0 0 84 3 81 82 0 265 0
pmappl 256 492 0 462 3 0 3 3 0 8 0
extentpl 40 45 0 27 1 0 1 1 0 8 0
phpool 112 437 0 43 12 0 12 12 0 8 0
ddb{1}> machine ddbcpu 0
Stopped at x86_ipi_db+0x27: addq $0x8,%rsp
x86_ipi_db(ffffffff83925ff0) 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
__sanitizer_cov_trace_pc() at __sanitizer_cov_trace_pc+0x2c kd_curproc sys/dev/kcov.c:584 [inline]
__sanitizer_cov_trace_pc() at __sanitizer_cov_trace_pc+0x2c sys/dev/kcov.c:153
__mp_lock(ffffffff83ad7300) at __mp_lock+0x1a3 __mp_lock_spin sys/kern/kern_lock.c:142 [inline]
__mp_lock(ffffffff83ad7300) at __mp_lock+0x1a3 sys/kern/kern_lock.c:173
softintr_dispatch(0) at softintr_dispatch+0x125 sys/kern/kern_softintr.c:83
dosoftint(0) at dosoftint+0x54 sys/arch/amd64/amd64/intr.c:862
Xsoftclock() at Xsoftclock+0x27
end of kernel
end trace frame: 0x742812258550, count: 7
ddb{0}> trace
x86_ipi_db(ffffffff83925ff0) 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
__sanitizer_cov_trace_pc() at __sanitizer_cov_trace_pc+0x2c kd_curproc sys/dev/kcov.c:584 [inline]
__sanitizer_cov_trace_pc() at __sanitizer_cov_trace_pc+0x2c sys/dev/kcov.c:153
__mp_lock(ffffffff83ad7300) at __mp_lock+0x1a3 __mp_lock_spin sys/kern/kern_lock.c:142 [inline]
__mp_lock(ffffffff83ad7300) at __mp_lock+0x1a3 sys/kern/kern_lock.c:173
softintr_dispatch(0) at softintr_dispatch+0x125 sys/kern/kern_softintr.c:83
dosoftint(0) at dosoftint+0x54 sys/arch/amd64/amd64/intr.c:862
Xsoftclock() at Xsoftclock+0x27
end of kernel
end trace frame: 0x742812258550, count: -8
ddb{0}> machine ddbcpu 1
Stopped at sys_shmat+0x453: movq 0(%r15),%rdi
sys_shmat(ffff800045ffd4c8,ffff80002a2b2e40,ffff80002a2b2d90) at sys_shmat+0x453 sys/kern/sysv_shm.c:290
syscall(ffff80002a2b2e40) at syscall+0xb17 mi_syscall sys/sys/syscall_mi.h:176 [inline]
syscall(ffff80002a2b2e40) at syscall+0xb17 sys/arch/amd64/amd64/trap.c:791
Xsyscall() at Xsyscall+0x128
end of kernel
end trace frame: 0xe637ad81c10, count: 12
ddb{1}> trace
sys_shmat(ffff800045ffd4c8,ffff80002a2b2e40,ffff80002a2b2d90) at sys_shmat+0x453 sys/kern/sysv_shm.c:290
syscall(ffff80002a2b2e40) at syscall+0xb17 mi_syscall sys/sys/syscall_mi.h:176 [inline]
syscall(ffff80002a2b2e40) at syscall+0xb17 sys/arch/amd64/amd64/trap.c:791
Xsyscall() at Xsyscall+0x128
end of kernel
end trace frame: 0xe637ad81c10, count: -3
* Struck through repros no longer work on HEAD.