summaryrefslogtreecommitdiff
path: root/sys/arch/sgi/include
diff options
context:
space:
mode:
authorMiod Vallat <miod@cvs.openbsd.org>2007-06-21 20:17:13 +0000
committerMiod Vallat <miod@cvs.openbsd.org>2007-06-21 20:17:13 +0000
commitb03519f8c6e8caccda6520217fb3537d1d063c4a (patch)
tree3ffa85787ef7a55040b36a3c7d5394a637c2162a /sys/arch/sgi/include
parent499eb788d359fe4e2415e514679969123e8dd6d2 (diff)
Extent sgi bus_dma to cope with different views of memory: non-contiguous
for the cpu, contiguous from different bases for devices. This allows memory above 256MB to be used with bus_dma (and we had really been lucky with the first few large-memory builds). Information about memory accesses taken from Linux.
Diffstat (limited to 'sys/arch/sgi/include')
-rw-r--r--sys/arch/sgi/include/bus.h10
1 files changed, 8 insertions, 2 deletions
diff --git a/sys/arch/sgi/include/bus.h b/sys/arch/sgi/include/bus.h
index 1d84ced752b..4e191878a71 100644
--- a/sys/arch/sgi/include/bus.h
+++ b/sys/arch/sgi/include/bus.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: bus.h,v 1.5 2006/05/27 00:29:55 krw Exp $ */
+/* $OpenBSD: bus.h,v 1.6 2007/06/21 20:17:12 miod Exp $ */
/*
* Copyright (c) 2003-2004 Opsycon AB Sweden. All rights reserved.
@@ -345,7 +345,13 @@ struct machine_bus_dma_tag {
void (*_dmamem_unmap)(bus_dma_tag_t, caddr_t, size_t);
paddr_t (*_dmamem_mmap)(bus_dma_tag_t, bus_dma_segment_t *,
int, off_t, int, int);
- paddr_t dma_offs;
+
+ /*
+ * internal memory address translation information.
+ */
+ bus_addr_t (*_pa_to_device)(paddr_t);
+ paddr_t (*_device_to_pa)(bus_addr_t);
+ bus_addr_t _dma_mask;
};
#define bus_dmamap_create(t, s, n, m, b, f, p) \