summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorMiod Vallat <miod@cvs.openbsd.org>2008-03-30 18:25:14 +0000
committerMiod Vallat <miod@cvs.openbsd.org>2008-03-30 18:25:14 +0000
commitd8c08bc5c8a27b13250288737421ac6e6c4c5cac (patch)
tree575184f3d49fa8522220a1260f25abf02518e267 /sys
parentf70b2a3816f37851dbad8bcd97eb612ae4cacf6c (diff)
Use vaddr_t instead of void * for some initial virtual memory layout arithmetic.
Diffstat (limited to 'sys')
-rw-r--r--sys/arch/vax/vax/locore.c6
-rw-r--r--sys/arch/vax/vax/pmap.c12
2 files changed, 9 insertions, 9 deletions
diff --git a/sys/arch/vax/vax/locore.c b/sys/arch/vax/vax/locore.c
index a5e38e0f895..7181a51d144 100644
--- a/sys/arch/vax/vax/locore.c
+++ b/sys/arch/vax/vax/locore.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: locore.c,v 1.32 2006/08/27 16:55:41 miod Exp $ */
+/* $OpenBSD: locore.c,v 1.33 2008/03/30 18:25:13 miod Exp $ */
/* $NetBSD: locore.c,v 1.43 2000/03/26 11:39:45 ragge Exp $ */
/*
* Copyright (c) 1994, 1998 Ludd, University of Lule}, Sweden.
@@ -89,7 +89,7 @@ extern struct cpu_dep vxt_calls;
void
start(struct rpb *prpb)
{
- extern void *scratch;
+ extern vaddr_t scratch;
mtpr(AST_NO, PR_ASTLVL); /* Turn off ASTs */
@@ -344,7 +344,7 @@ start(struct rpb *prpb)
/* Now running virtual. set red zone for proc0 */
*kvtopte((u_int)proc0.p_addr + REDZONEADDR) &= ~PG_V;
- ((struct pcb *)proc0paddr)->framep = scratch;
+ ((struct pcb *)proc0paddr)->framep = (void *)scratch;
/*
* Change mode down to userspace is done by faking a stack
diff --git a/sys/arch/vax/vax/pmap.c b/sys/arch/vax/vax/pmap.c
index 52949b19bc9..6bf64c95fa1 100644
--- a/sys/arch/vax/vax/pmap.c
+++ b/sys/arch/vax/vax/pmap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pmap.c,v 1.41 2007/09/10 18:49:45 miod Exp $ */
+/* $OpenBSD: pmap.c,v 1.42 2008/03/30 18:25:13 miod Exp $ */
/* $NetBSD: pmap.c,v 1.74 1999/11/13 21:32:25 matt Exp $ */
/*
* Copyright (c) 1994, 1998, 1999 Ludd, University of Lule}, Sweden.
@@ -69,7 +69,7 @@ vaddr_t istack;
struct pmap kernel_pmap_store;
pt_entry_t *Sysmap; /* System page table */
-void *scratch;
+vaddr_t scratch;
vaddr_t iospace;
vaddr_t ptemapstart, ptemapend;
@@ -176,13 +176,13 @@ pmap_bootstrap()
mtpr((unsigned)Sysmap - KERNBASE, PR_SBR);
/* Map Interrupt stack and set red zone */
- istack = (unsigned)Sysmap + ROUND_PAGE(sysptsize * 4);
+ istack = (vaddr_t)Sysmap + ROUND_PAGE(sysptsize * 4);
mtpr(istack + ISTACK_SIZE, PR_ISP);
*kvtopte(istack) &= ~PG_V;
/* Some scratch pages */
- scratch = (void *)((u_int)istack + ISTACK_SIZE);
- avail_start = (u_int)scratch + 4 * VAX_NBPG - KERNBASE;
+ scratch = istack + ISTACK_SIZE;
+ avail_start = scratch + 4 * VAX_NBPG - KERNBASE;
/* Kernel message buffer */
avail_end -= MSGBUFSIZE;
@@ -221,7 +221,7 @@ pmap_bootstrap()
#if 0 /* Breaks cninit() on some machines */
cninit();
- printf("Sysmap %p, istack %lx, scratch %p\n",Sysmap,istack,scratch);
+ printf("Sysmap %p, istack %p, scratch %p\n",Sysmap,istack,scratch);
printf("etext %p\n", &etext);
printf("SYSPTSIZE %x\n",sysptsize);
printf("ptemapstart %lx ptemapend %lx\n", ptemapstart, ptemapend);