summaryrefslogtreecommitdiff
path: root/sys/arch/socppc/include
diff options
context:
space:
mode:
authorMark Kettenis <kettenis@cvs.openbsd.org>2015-01-24 20:59:43 +0000
committerMark Kettenis <kettenis@cvs.openbsd.org>2015-01-24 20:59:43 +0000
commit3d5e5c822ce74913b35bc1e3e912c4f00e177477 (patch)
treec9e0c86be4ff55eb71ee46fd888454935e9c204e /sys/arch/socppc/include
parent53ea9eba39efe4646cebb1e627e4d43199505be6 (diff)
Implement bus_dmamem_alloc_range(9) for macppc/socppc.
Diffstat (limited to 'sys/arch/socppc/include')
-rw-r--r--sys/arch/socppc/include/bus.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/sys/arch/socppc/include/bus.h b/sys/arch/socppc/include/bus.h
index 1150642c755..6c782eba8a2 100644
--- a/sys/arch/socppc/include/bus.h
+++ b/sys/arch/socppc/include/bus.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: bus.h,v 1.10 2015/01/20 17:08:35 mpi Exp $ */
+/* $OpenBSD: bus.h,v 1.11 2015/01/24 20:59:42 kettenis Exp $ */
/*
* Copyright (c) 1997 Per Fogelstrom. All rights reserved.
@@ -521,6 +521,9 @@ struct powerpc_bus_dma_tag {
*/
int (*_dmamem_alloc)(bus_dma_tag_t, bus_size_t, bus_size_t,
bus_size_t, bus_dma_segment_t *, int, int *, int);
+ int (*_dmamem_alloc_range)(bus_dma_tag_t, bus_size_t, bus_size_t,
+ bus_size_t, bus_dma_segment_t *, int, int *, int,
+ bus_addr_t, bus_addr_t);
void (*_dmamem_free)(bus_dma_tag_t, bus_dma_segment_t *, int);
int (*_dmamem_map)(bus_dma_tag_t, bus_dma_segment_t *,
int, size_t, caddr_t *, int);
@@ -549,6 +552,9 @@ struct powerpc_bus_dma_tag {
#define bus_dmamem_alloc(t, s, a, b, sg, n, r, f) \
(*(t)->_dmamem_alloc)((t)->_cookie, (s), (a), (b), (sg), (n), (r), (f))
+#define bus_dmamem_alloc_range(t, s, a, b, sg, n, r, f, l, h) \
+ (*(t)->_dmamem_alloc_range)((t), (s), (a), (b), (sg), \
+ (n), (r), (f), (l), (h))
#define bus_dmamem_free(t, sg, n) \
(*(t)->_dmamem_free)((t)->_cookie, (sg), (n))
#define bus_dmamem_map(t, sg, n, s, k, f) \
@@ -573,6 +579,9 @@ void _dmamap_sync(bus_dma_tag_t, bus_dmamap_t, bus_addr_t, bus_size_t,
int _dmamem_alloc(bus_dma_tag_t, bus_size_t, bus_size_t,
bus_size_t, bus_dma_segment_t *, int, int *, int);
+int _dmamem_alloc_range( bus_dma_tag_t, bus_size_t, bus_size_t,
+ bus_size_t, bus_dma_segment_t *, int, int *, int,
+ bus_addr_t, bus_addr_t);
void _dmamem_free(bus_dma_tag_t, bus_dma_segment_t *, int);
int _dmamem_map(bus_dma_tag_t, bus_dma_segment_t *,
int, size_t, caddr_t *, int);