Module Name: src
Committed By: dyoung
Date: Wed Sep 28 01:38:19 UTC 2011
Modified Files:
src/sys/arch/x86/x86: bus_dma.c
Log Message:
After bouncing in bus_dmamap_load{,_mbuf,_uio}, call bus_dmamap_load(9)
instead of _bus_dmamap_load() so that a bus_dmamap_load(9) override has
a shot at loading the map.
XXX Perhaps bounce buffers should be rewritten in terms of bus_dma(9)
XXX overrides.
To generate a diff of this commit:
cvs rdiff -u -r1.65 -r1.66 src/sys/arch/x86/x86/bus_dma.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sys/arch/x86/x86/bus_dma.c
diff -u src/sys/arch/x86/x86/bus_dma.c:1.65 src/sys/arch/x86/x86/bus_dma.c:1.66
--- src/sys/arch/x86/x86/bus_dma.c:1.65 Wed Sep 28 01:35:58 2011
+++ src/sys/arch/x86/x86/bus_dma.c Wed Sep 28 01:38:19 2011
@@ -1,4 +1,4 @@
-/* $NetBSD: bus_dma.c,v 1.65 2011/09/28 01:35:58 dyoung Exp $ */
+/* $NetBSD: bus_dma.c,v 1.66 2011/09/28 01:38:19 dyoung Exp $ */
/*-
* Copyright (c) 1996, 1997, 1998, 2007 The NetBSD Foundation, Inc.
@@ -31,7 +31,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: bus_dma.c,v 1.65 2011/09/28 01:35:58 dyoung Exp $");
+__KERNEL_RCSID(0, "$NetBSD: bus_dma.c,v 1.66 2011/09/28 01:38:19 dyoung Exp $");
/*
* The following is included because _bus_dma_uiomove is derived from
@@ -424,7 +424,7 @@ _bus_dmamap_load(bus_dma_tag_t t, bus_dm
cookie->id_origbuflen = buflen;
cookie->id_buftype = X86_DMA_BUFTYPE_LINEAR;
map->dm_nsegs = 0;
- error = _bus_dmamap_load(t, map, cookie->id_bouncebuf, buflen,
+ error = bus_dmamap_load(t, map, cookie->id_bouncebuf, buflen,
p, flags);
if (error)
return (error);
@@ -620,7 +620,7 @@ _bus_dmamap_load_mbuf(bus_dma_tag_t t, b
cookie->id_origbuf = m0;
cookie->id_origbuflen = m0->m_pkthdr.len; /* not really used */
cookie->id_buftype = X86_DMA_BUFTYPE_MBUF;
- error = _bus_dmamap_load(t, map, cookie->id_bouncebuf,
+ error = bus_dmamap_load(t, map, cookie->id_bouncebuf,
m0->m_pkthdr.len, NULL, flags);
if (error)
return (error);
@@ -700,7 +700,7 @@ _bus_dmamap_load_uio(bus_dma_tag_t t, bu
cookie->id_origbuf = uio;
cookie->id_origbuflen = uio->uio_resid;
cookie->id_buftype = X86_DMA_BUFTYPE_UIO;
- error = _bus_dmamap_load(t, map, cookie->id_bouncebuf,
+ error = bus_dmamap_load(t, map, cookie->id_bouncebuf,
uio->uio_resid, NULL, flags);
if (error)
return (error);