svn commit: r216973 - head/sys/dev/bge
Pyun YongHyeon
yongari at FreeBSD.org
Tue Jan 4 20:06:26 UTC 2011
Author: yongari
Date: Tue Jan 4 20:06:26 2011
New Revision: 216973
URL: http://svn.freebsd.org/changeset/base/216973
Log:
Limit hardware bug workaround to controllers that have 4GB boundary
bug instead of blindly applying it to all controllers.
Pointed out by: marius
MFC after: 3 days
Modified:
head/sys/dev/bge/if_bge.c
Modified: head/sys/dev/bge/if_bge.c
==============================================================================
--- head/sys/dev/bge/if_bge.c Tue Jan 4 19:32:03 2011 (r216972)
+++ head/sys/dev/bge/if_bge.c Tue Jan 4 20:06:26 2011 (r216973)
@@ -2482,8 +2482,11 @@ bge_dma_alloc(struct bge_softc *sc)
* restriction and limit DMA address space to 32bit. It's not
* clear whether there is another hardware issue here.
*/
+ lowaddr = BUS_SPACE_MAXADDR;
+ if ((sc->bge_flags & BGE_FLAG_40BIT_BUG) != 0)
+ lowaddr = BUS_SPACE_MAXADDR_32BIT;
error = bus_dma_tag_create(bus_get_dma_tag(sc->bge_dev),
- 1, 0, BUS_SPACE_MAXADDR_32BIT, BUS_SPACE_MAXADDR, NULL,
+ 1, 0, lowaddr, BUS_SPACE_MAXADDR, NULL,
NULL, BUS_SPACE_MAXSIZE_32BIT, 0, BUS_SPACE_MAXSIZE_32BIT,
0, NULL, NULL, &sc->bge_cdata.bge_buffer_tag);
if (error != 0) {
More information about the svn-src-head
mailing list