summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
Diffstat (limited to 'sys')
-rw-r--r--sys/arch/mvme68k/mvme68k/bus_dma.c14
-rw-r--r--sys/arch/mvme88k/mvme88k/bus_dma.c12
-rw-r--r--sys/arch/mvmeppc/mvmeppc/bus_dma.c12
3 files changed, 4 insertions, 34 deletions
diff --git a/sys/arch/mvme68k/mvme68k/bus_dma.c b/sys/arch/mvme68k/mvme68k/bus_dma.c
index 6c3d9c7c29a..b667cf27972 100644
--- a/sys/arch/mvme68k/mvme68k/bus_dma.c
+++ b/sys/arch/mvme68k/mvme68k/bus_dma.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: bus_dma.c,v 1.4 2009/04/20 00:42:06 oga Exp $ */
+/* $OpenBSD: bus_dma.c,v 1.5 2009/06/07 16:02:39 miod Exp $ */
/* $NetBSD: bus_dma.c,v 1.2 2001/06/10 02:31:25 briggs Exp $ */
/*-
@@ -468,18 +468,8 @@ bus_dmamem_alloc(t, size, alignment, boundary, segs, nsegs, rsegs, flags)
int *rsegs;
int flags;
{
- paddr_t avail_start = (paddr_t)-1, avail_end = 0;
- int bank;
-
- for (bank = 0; bank < vm_nphysseg; bank++) {
- if (avail_start > vm_physmem[bank].avail_start << PGSHIFT)
- avail_start = vm_physmem[bank].avail_start << PGSHIFT;
- if (avail_end < vm_physmem[bank].avail_end << PGSHIFT)
- avail_end = vm_physmem[bank].avail_end << PGSHIFT;
- }
-
return _bus_dmamem_alloc_range(t, size, alignment, boundary, segs,
- nsegs, rsegs, flags, avail_start, avail_end - PAGE_SIZE);
+ nsegs, rsegs, flags, 0, -1);
}
/*
diff --git a/sys/arch/mvme88k/mvme88k/bus_dma.c b/sys/arch/mvme88k/mvme88k/bus_dma.c
index 730369e15b5..878f7985216 100644
--- a/sys/arch/mvme88k/mvme88k/bus_dma.c
+++ b/sys/arch/mvme88k/mvme88k/bus_dma.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: bus_dma.c,v 1.12 2009/04/20 00:42:06 oga Exp $ */
+/* $OpenBSD: bus_dma.c,v 1.13 2009/06/07 16:02:41 miod Exp $ */
/* $NetBSD: bus_dma.c,v 1.2 2001/06/10 02:31:25 briggs Exp $ */
/*-
@@ -471,16 +471,6 @@ bus_dmamem_alloc(t, size, alignment, boundary, segs, nsegs, rsegs, flags)
int *rsegs;
int flags;
{
- paddr_t avail_start = (paddr_t)-1, avail_end = 0;
- int bank;
-
- for (bank = 0; bank < vm_nphysseg; bank++) {
- if (avail_start > vm_physmem[bank].avail_start << PGSHIFT)
- avail_start = vm_physmem[bank].avail_start << PGSHIFT;
- if (avail_end < vm_physmem[bank].avail_end << PGSHIFT)
- avail_end = vm_physmem[bank].avail_end << PGSHIFT;
- }
-
return _bus_dmamem_alloc_range(t, size, alignment, boundary, segs,
nsegs, rsegs, flags, 0, -1);
}
diff --git a/sys/arch/mvmeppc/mvmeppc/bus_dma.c b/sys/arch/mvmeppc/mvmeppc/bus_dma.c
index 3bd46697866..ccf2acab2cc 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.24 2009/04/20 00:42:06 oga Exp $ */
+/* $OpenBSD: bus_dma.c,v 1.25 2009/06/07 16:02:41 miod Exp $ */
/* $NetBSD: bus_dma.c,v 1.2 2001/06/10 02:31:25 briggs Exp $ */
/*-
@@ -437,16 +437,6 @@ _bus_dmamem_alloc(t, size, alignment, boundary, segs, nsegs, rsegs, flags)
int *rsegs;
int flags;
{
- paddr_t avail_start = 0xffffffff, avail_end = 0;
- int bank;
-
- for (bank = 0; bank < vm_nphysseg; bank++) {
- if (avail_start > vm_physmem[bank].avail_start << PGSHIFT)
- avail_start = vm_physmem[bank].avail_start << PGSHIFT;
- if (avail_end < vm_physmem[bank].avail_end << PGSHIFT)
- avail_end = vm_physmem[bank].avail_end << PGSHIFT;
- }
-
return _bus_dmamem_alloc_range(t, size, alignment, boundary, segs,
nsegs, rsegs, flags, 0, -1);
}