Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/usermode/usermode Use the signal's signo instead of...
details: https://anonhg.NetBSD.org/src/rev/5505880415e4
branches: trunk
changeset: 777770:5505880415e4
user: reinoud <reinoud%NetBSD.org@localhost>
date: Sat Mar 03 21:29:02 2012 +0000
description:
Use the signal's signo instead of just returning SIGSEGV and add a comment
diffstat:
sys/arch/usermode/usermode/trap.c | 11 ++++++++---
1 files changed, 8 insertions(+), 3 deletions(-)
diffs (39 lines):
diff -r 219c2e65462d -r 5505880415e4 sys/arch/usermode/usermode/trap.c
--- a/sys/arch/usermode/usermode/trap.c Sat Mar 03 21:15:15 2012 +0000
+++ b/sys/arch/usermode/usermode/trap.c Sat Mar 03 21:29:02 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: trap.c,v 1.64 2012/03/03 21:15:16 reinoud Exp $ */
+/* $NetBSD: trap.c,v 1.65 2012/03/03 21:29:02 reinoud Exp $ */
/*-
* Copyright (c) 2011 Reinoud Zandijk <reinoud%netbsd.org@localhost>
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: trap.c,v 1.64 2012/03/03 21:15:16 reinoud Exp $");
+__KERNEL_RCSID(0, "$NetBSD: trap.c,v 1.65 2012/03/03 21:29:02 reinoud Exp $");
#include <sys/types.h>
#include <sys/param.h>
@@ -480,7 +480,7 @@
KASSERT(from_userland);
KSI_INIT_TRAP(&ksi);
- ksi.ksi_signo = SIGSEGV;
+ ksi.ksi_signo = info->si_signo;
ksi.ksi_trap = 0; /* XXX */
ksi.ksi_code = (error == EPERM) ? SEGV_ACCERR : SEGV_MAPERR;
ksi.ksi_addr = (void *) va;
@@ -552,6 +552,11 @@
}
+/*
+ * handle pass to userland signals
+ *
+ * arguments other than the origional siginfo_t are not used
+ */
static void
pass_on(siginfo_t *info, vaddr_t from_userland, vaddr_t pc, vaddr_t va)
{
Home |
Main Index |
Thread Index |
Old Index