summaryrefslogtreecommitdiff
path: root/sys/arch/vax
diff options
context:
space:
mode:
authorArtur Grabowski <art@cvs.openbsd.org>2001-05-05 21:26:48 +0000
committerArtur Grabowski <art@cvs.openbsd.org>2001-05-05 21:26:48 +0000
commitca8a4ccfe938b07fa473a582784074e5f93813cd (patch)
treee9075d1e6c63ae7e0fd9c950fcdebcfb637b3405 /sys/arch/vax
parent368552036fe6029364e1abc2351955db681286fc (diff)
Remove the (vaddr_t) casts inside the round_page and trunc_page macros.
We might want to use them on types that are bigger than vaddr_t. Fix all callers that pass pointers without casts.
Diffstat (limited to 'sys/arch/vax')
-rw-r--r--sys/arch/vax/vax/pmap.c4
-rw-r--r--sys/arch/vax/vax/trap.c4
-rw-r--r--sys/arch/vax/vax/uvax.c4
-rw-r--r--sys/arch/vax/vax/vm_machdep.c4
4 files changed, 8 insertions, 8 deletions
diff --git a/sys/arch/vax/vax/pmap.c b/sys/arch/vax/vax/pmap.c
index 43f4f758abd..80eb65aa8af 100644
--- a/sys/arch/vax/vax/pmap.c
+++ b/sys/arch/vax/vax/pmap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pmap.c,v 1.13 2001/04/10 06:59:13 niklas Exp $ */
+/* $OpenBSD: pmap.c,v 1.14 2001/05/05 21:26:41 art 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.
@@ -717,7 +717,7 @@ if (startpmapdebug)
panic("pmap_enter: bad index %d", index);
#endif
if (pmap->pm_refcnt[index] == 0) {
- vaddr_t ptaddr = trunc_page(&patch[i]);
+ vaddr_t ptaddr = trunc_page((vaddr_t)&patch[i]);
paddr_t phys;
struct vm_page *pg;
#ifdef DEBUG
diff --git a/sys/arch/vax/vax/trap.c b/sys/arch/vax/vax/trap.c
index db589030997..a6be28ca91e 100644
--- a/sys/arch/vax/vax/trap.c
+++ b/sys/arch/vax/vax/trap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: trap.c,v 1.13 2000/11/10 18:15:43 art Exp $ */
+/* $OpenBSD: trap.c,v 1.14 2001/05/05 21:26:41 art Exp $ */
/* $NetBSD: trap.c,v 1.47 1999/08/21 19:26:20 matt Exp $ */
/*
* Copyright (c) 1994 Ludd, University of Lule}, Sweden.
@@ -180,7 +180,7 @@ if(faultdebug)printf("trap accflt type %lx, code %lx, pc %lx, psl %lx\n",
* because we must check for PTE pages anyway we don't
* bother doing it here.
*/
- addr = trunc_page(frame->code);
+ addr = trunc_page((vaddr_t)frame->code);
if ((umode == 0) && (frame->code < 0))
map = kernel_map;
else
diff --git a/sys/arch/vax/vax/uvax.c b/sys/arch/vax/vax/uvax.c
index 592daa5c584..6aaaeba9501 100644
--- a/sys/arch/vax/vax/uvax.c
+++ b/sys/arch/vax/vax/uvax.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: uvax.c,v 1.4 1999/01/11 05:12:08 millert Exp $ */
+/* $OpenBSD: uvax.c,v 1.5 2001/05/05 21:26:42 art Exp $ */
/* $NetBSD: uvax.c,v 1.4 1997/02/19 10:04:27 ragge Exp $ */
/*
* Copyright (c) 1996 Ludd, University of Lule}, Sweden.
@@ -93,7 +93,7 @@ uvax_phys2virt(phys)
for (p = dep_call->cpu_map; p->um_base != 0; p++) {
if (p->um_base > phys || p->um_end < phys)
continue;
- virt = p->um_virt + (phys - trunc_page(p->um_base));
+ virt = p->um_virt + (phys - trunc_page((vaddr_t)p->um_base));
break;
}
diff --git a/sys/arch/vax/vax/vm_machdep.c b/sys/arch/vax/vax/vm_machdep.c
index e93dd48fec0..cc0fa99ecb8 100644
--- a/sys/arch/vax/vax/vm_machdep.c
+++ b/sys/arch/vax/vax/vm_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: vm_machdep.c,v 1.19 2001/02/11 06:34:37 hugh Exp $ */
+/* $OpenBSD: vm_machdep.c,v 1.20 2001/05/05 21:26:42 art Exp $ */
/* $NetBSD: vm_machdep.c,v 1.67 2000/06/29 07:14:34 mrg Exp $ */
/*
@@ -341,7 +341,7 @@ vmapbuf(bp, len)
if ((bp->b_flags & B_PHYS) == 0)
panic("vmapbuf");
p = bp->b_proc;
- faddr = trunc_page((vaddr_t)bp->b_saveaddr = bp->b_data);
+ faddr = trunc_page((vaddr_t)(bp->b_saveaddr = bp->b_data));
off = (vaddr_t)bp->b_data - faddr;
len = round_page(off + len);
taddr = uvm_km_valloc_wait(phys_map, len);