artulab
projects
/
openbsd
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5c4b546
)
pass VM_PROT_READ/VM_PROT_WRITE as si_trapno for SIGSEGV
author
deraadt
<deraadt@openbsd.org>
Tue, 4 Feb 1997 12:23:16 +0000
(12:23 +0000)
committer
deraadt
<deraadt@openbsd.org>
Tue, 4 Feb 1997 12:23:16 +0000
(12:23 +0000)
sys/arch/sparc/sparc/trap.c
patch
|
blob
|
history
diff --git
a/sys/arch/sparc/sparc/trap.c
b/sys/arch/sparc/sparc/trap.c
index
972e848
..
6556912
100644
(file)
--- a/
sys/arch/sparc/sparc/trap.c
+++ b/
sys/arch/sparc/sparc/trap.c
@@
-743,7
+743,8
@@
kfault:
tf->tf_npc = onfault + 4;
return;
}
- trapsignal(p, SIGSEGV, (u_int)v, SEGV_MAPERR, (caddr_t)v);
+ trapsignal(p, SIGSEGV, (ser & SER_WRITE) ? VM_PROT_WRITE :
+ VM_PROT_READ, SEGV_MAPERR, (caddr_t)v);
}
out:
if ((psr & PSR_PS) == 0) {
@@
-1015,7
+1016,7
@@
kfault:
tf->tf_npc = onfault + 4;
return;
}
- trapsignal(p, SIGSEGV,
(u_int)sfva
, SEGV_MAPERR, (caddr_t)sfva);
+ trapsignal(p, SIGSEGV,
ftype
, SEGV_MAPERR, (caddr_t)sfva);
}
out:
if ((psr & PSR_PS) == 0) {