Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/amiga/amiga Use common pmap_bootstrap_finalize() to...
details: https://anonhg.NetBSD.org/src/rev/93836afaf55e
branches: trunk
changeset: 749619:93836afaf55e
user: tsutsui <tsutsui%NetBSD.org@localhost>
date: Fri Dec 04 17:11:10 2009 +0000
description:
Use common pmap_bootstrap_finalize() to initialize lwp0 uarea etc.
Compile test only.
diffstat:
sys/arch/amiga/amiga/amiga_init.c | 9 ++++-----
sys/arch/amiga/amiga/locore.s | 7 ++-----
2 files changed, 6 insertions(+), 10 deletions(-)
diffs (66 lines):
diff -r 02ec5753af1c -r 93836afaf55e sys/arch/amiga/amiga/amiga_init.c
--- a/sys/arch/amiga/amiga/amiga_init.c Fri Dec 04 16:57:18 2009 +0000
+++ b/sys/arch/amiga/amiga/amiga_init.c Fri Dec 04 17:11:10 2009 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: amiga_init.c,v 1.113 2009/11/26 18:23:48 phx Exp $ */
+/* $NetBSD: amiga_init.c,v 1.114 2009/12/04 17:11:10 tsutsui Exp $ */
/*
* Copyright (c) 1994 Michael L. Hitch
@@ -36,11 +36,10 @@
#include "opt_devreload.h"
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: amiga_init.c,v 1.113 2009/11/26 18:23:48 phx Exp $");
+__KERNEL_RCSID(0, "$NetBSD: amiga_init.c,v 1.114 2009/12/04 17:11:10 tsutsui Exp $");
#include <sys/param.h>
#include <sys/systm.h>
-#include <sys/proc.h>
#include <uvm/uvm_extern.h>
#include <sys/ioctl.h>
#include <sys/select.h>
@@ -353,7 +352,7 @@
/*
* save KVA of lwp0 u-area and allocate it.
*/
- RELOC(lwp0.l_addr, struct user *) = (struct user *)vstart;
+ RELOC(lwp0uarea, vaddr_t) = vstart;
pstart += USPACE;
vstart += USPACE;
avail -= USPACE;
@@ -788,8 +787,8 @@
((volatile struct Custom *)CUSTOMADDR)->color[0] = 0x0a0; /* GREEN */
#endif
- memset(lwp0.l_addr, 0, USPACE);
pmap_bootstrap(start_c_pstart, start_c_fphystart);
+ pmap_bootstrap_finalize();
/*
* to make life easier in locore.s, set these addresses explicitly
diff -r 02ec5753af1c -r 93836afaf55e sys/arch/amiga/amiga/locore.s
--- a/sys/arch/amiga/amiga/locore.s Fri Dec 04 16:57:18 2009 +0000
+++ b/sys/arch/amiga/amiga/locore.s Fri Dec 04 17:11:10 2009 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: locore.s,v 1.146 2009/11/26 00:19:12 matt Exp $ */
+/* $NetBSD: locore.s,v 1.147 2009/12/04 17:11:11 tsutsui Exp $ */
/*
* Copyright (c) 1980, 1990 The Regents of the University of California.
@@ -1024,14 +1024,11 @@
jbsr _C_LABEL(start_c_finish)
/* set kernel stack, user SP, and initial pcb */
- lea _C_LABEL(lwp0),%a2 | grab lwp0 and initialize
- movl %a2,_C_LABEL(curlwp) | curlwp so that
- movl %a2@(L_ADDR),%a1 | we don't dref NULL in trap()
+ movl _C_LABEL(lwp0uarea),%a1 | grab lwp0 uarea
lea %a1@(USPACE),%sp | set kernel stack to end of area
movl #USRSTACK-4,%a2
movl %a2,%usp | init user SP
movl %a2,%a1@(PCB_USP) | and save it
- movl %a1,_C_LABEL(curpcb) | lwp0 is running
clrw %a1@(PCB_FLAGS) | clear flags
#ifdef FPCOPROC
clrl %a1@(PCB_FPCTX) | ensure null FP context
Home |
Main Index |
Thread Index |
Old Index