diff options
author | Martin Reindl <martin@cvs.openbsd.org> | 2005-10-26 18:57:52 +0000 |
---|---|---|
committer | Martin Reindl <martin@cvs.openbsd.org> | 2005-10-26 18:57:52 +0000 |
commit | 1d2a657595f111606ebb683f9d9da32839f2948c (patch) | |
tree | 02498ff5ef6207a3a129fa8473556157dba53e66 /sys | |
parent | 7b916e37e03ee6d7f7f3c34e002cdfaa3ba0f6f9 (diff) |
Mach-macro wipeout
'do it' deraadt@
Diffstat (limited to 'sys')
-rw-r--r-- | sys/arch/macppc/macppc/dma.c | 4 | ||||
-rw-r--r-- | sys/arch/macppc/pci/vgafb.c | 16 | ||||
-rw-r--r-- | sys/arch/mvmeppc/mvmeppc/bus_dma.c | 4 | ||||
-rw-r--r-- | sys/arch/powerpc/include/param.h | 8 |
4 files changed, 6 insertions, 26 deletions
diff --git a/sys/arch/macppc/macppc/dma.c b/sys/arch/macppc/macppc/dma.c index 9249c4b3c4b..f0526ab1523 100644 --- a/sys/arch/macppc/macppc/dma.c +++ b/sys/arch/macppc/macppc/dma.c @@ -1,4 +1,4 @@ -/* $OpenBSD: dma.c,v 1.22 2004/11/09 19:17:01 claudio Exp $ */ +/* $OpenBSD: dma.c,v 1.23 2005/10/26 18:57:51 martin Exp $ */ /* $NetBSD: machdep.c,v 1.214 1996/11/10 03:16:17 thorpej Exp $ */ /*- @@ -509,7 +509,7 @@ _dmamem_mmap(bus_dma_tag_t t, bus_dma_segment_t *segs, int nsegs, off_t off, continue; } - return (powerpc_btop((caddr_t)segs[i].ds_addr + off)); + return (atop(segs[i].ds_addr + off)); } /* Page not found. */ diff --git a/sys/arch/macppc/pci/vgafb.c b/sys/arch/macppc/pci/vgafb.c index d4da7a89e7b..58a66e7f030 100644 --- a/sys/arch/macppc/pci/vgafb.c +++ b/sys/arch/macppc/pci/vgafb.c @@ -1,4 +1,4 @@ -/* $OpenBSD: vgafb.c,v 1.25 2005/10/08 05:47:25 drahn Exp $ */ +/* $OpenBSD: vgafb.c,v 1.26 2005/10/26 18:57:51 martin Exp $ */ /* $NetBSD: vga.c,v 1.3 1996/12/02 22:24:54 cgd Exp $ */ /* @@ -366,21 +366,7 @@ vgafb_mmap(void *v, off_t offset, int prot) h = -1; } -#ifdef alpha - port = (u_int32_t *)(h << 5); - return alpha_btop(port); /* XXX */ -#elif defined(i386) - port = (u_int32_t *)(h << 5); - return i386_btop(port); -#elif defined(__powerpc__) - { - /* huh ??? */ return h; - /* - return powerpc_btop(port); - */ - } -#endif } diff --git a/sys/arch/mvmeppc/mvmeppc/bus_dma.c b/sys/arch/mvmeppc/mvmeppc/bus_dma.c index f771d919e17..9b497843e9f 100644 --- a/sys/arch/mvmeppc/mvmeppc/bus_dma.c +++ b/sys/arch/mvmeppc/mvmeppc/bus_dma.c @@ -1,4 +1,4 @@ -/* $OpenBSD: bus_dma.c,v 1.17 2004/12/25 23:02:25 miod Exp $ */ +/* $OpenBSD: bus_dma.c,v 1.18 2005/10/26 18:57:51 martin Exp $ */ /* $NetBSD: bus_dma.c,v 1.2 2001/06/10 02:31:25 briggs Exp $ */ /*- @@ -584,7 +584,7 @@ _bus_dmamem_mmap(t, segs, nsegs, off, prot, flags) continue; } - return (powerpc_btop(PCI_MEM_TO_PHYS(segs[i].ds_addr) + off)); + return (atop(PCI_MEM_TO_PHYS(segs[i].ds_addr) + off)); } /* Page not found. */ diff --git a/sys/arch/powerpc/include/param.h b/sys/arch/powerpc/include/param.h index e733b223c3d..cab06b9e71e 100644 --- a/sys/arch/powerpc/include/param.h +++ b/sys/arch/powerpc/include/param.h @@ -1,4 +1,4 @@ -/* $OpenBSD: param.h,v 1.26 2005/09/12 23:05:05 miod Exp $ */ +/* $OpenBSD: param.h,v 1.27 2005/10/26 18:57:51 martin Exp $ */ /* $NetBSD: param.h,v 1.1 1996/09/30 16:34:28 ws Exp $ */ /*- @@ -107,12 +107,6 @@ #define btodb(x) ((x) >> DEV_BSHIFT) /* - * Mach derived conversion macros - */ -#define powerpc_btop(x) ((unsigned)(x) >> PGSHIFT) -#define powerpc_ptob(x) ((unsigned)(x) << PGSHIFT) - -/* * Segment handling stuff */ #define PPC_SEGMENT_LENGTH 0x10000000 |