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 Move all i386 specific stuff in a...
details: https://anonhg.NetBSD.org/src/rev/97a71d1e0da4
branches: trunk
changeset: 769368:97a71d1e0da4
user: reinoud <reinoud%NetBSD.org@localhost>
date: Wed Sep 07 10:10:10 2011 +0000
description:
Move all i386 specific stuff in a #ifdef __i386__
diffstat:
sys/arch/usermode/usermode/machdep.c | 38 +++++++++++++++++++----------------
1 files changed, 21 insertions(+), 17 deletions(-)
diffs (83 lines):
diff -r 4a181df0f563 -r 97a71d1e0da4 sys/arch/usermode/usermode/machdep.c
--- a/sys/arch/usermode/usermode/machdep.c Wed Sep 07 10:00:19 2011 +0000
+++ b/sys/arch/usermode/usermode/machdep.c Wed Sep 07 10:10:10 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: machdep.c,v 1.24 2011/09/05 18:31:04 reinoud Exp $ */
+/* $NetBSD: machdep.c,v 1.25 2011/09/07 10:10:10 reinoud Exp $ */
/*-
* Copyright (c) 2007 Jared D. McNeill <jmcneill%invisible.ca@localhost>
@@ -31,7 +31,7 @@
#include "opt_urkelvisor.h"
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.24 2011/09/05 18:31:04 reinoud Exp $");
+__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.25 2011/09/07 10:10:10 reinoud Exp $");
#include <sys/types.h>
#include <sys/param.h>
@@ -142,10 +142,25 @@
}
void
+sendsig_siginfo(const ksiginfo_t *ksi, const sigset_t *mask)
+{
+}
+
+int
+mm_md_physacc(paddr_t pa, vm_prot_t prog)
+{
+ return 0;
+}
+
+
+#ifdef __i386__
+
+void
setregs(struct lwp *l, struct exec_package *pack, vaddr_t stack)
{
struct pcb *pcb = lwp_getpcb(l);
ucontext_t *ucp = &pcb->pcb_userland_ucp;
+ uint *reg, i;
#ifdef DEBUG_EXEC
printf("setregs called: lwp %p, exec package %p, stack %p\n",
@@ -161,10 +176,7 @@
(int) pcb->pcb_userland_ucp.uc_stack.ss_size);
#endif
-#ifdef __i386__
- uint *reg, i;
reg = (int *) &ucp->uc_mcontext;
-
for (i = 4; i < 11; i++)
reg[i] = 0;
@@ -185,9 +197,6 @@
for (i =0; i < 19; i++)
printf("reg[%02d] (%6s) = %"PRIx32"\n", i, name[i], reg[i]);
#endif
-#else
-# error setregs() not yet ported to this architecture
-#endif
#ifdef DEBUG_EXEC
printf("updated pcb %p\n", pcb);
@@ -204,13 +213,8 @@
#endif
}
-void
-sendsig_siginfo(const ksiginfo_t *ksi, const sigset_t *mask)
-{
-}
-int
-mm_md_physacc(paddr_t pa, vm_prot_t prog)
-{
- return 0;
-}
+#else
+# error setregs() not yet ported to this architecture
+#endif
+
Home |
Main Index |
Thread Index |
Old Index