Date: Fri, 12 Dec 2003 02:23:06 -0600 (CST) From: James Van Artsdalen <james-freebsd-amd64@jrv.org> To: freebsd-amd64@freebsd.org Subject: bge usage of bus_dma_tag_create? Message-ID: <200312120823.hBC8N6Ai074269@bigtex.jrv.org>
next in thread | raw e-mail | index | archive | help
I am confused by this code in sys/dev/bge/if_bge.c. Are the values for the lowaddr and highaddr args to bus_dma_tag_create () swapped? The ata and aha drivers seem to have lowaddr <= highaddr, but on AMD64 that's not true below. static int bge_dma_alloc(dev) device_t dev; { struct bge_softc *sc; int nseg, i, error; struct bge_dmamap_arg ctx; sc = device_get_softc(dev); /* * Allocate the parent bus DMA tag appropriate for PCI. */ #define BGE_NSEG_NEW 32 error = bus_dma_tag_create(NULL, /* parent */ PAGE_SIZE, 0, /* alignment, boundary */ BUS_SPACE_MAXADDR, /* lowaddr */ BUS_SPACE_MAXADDR_32BIT,/* highaddr */ NULL, NULL, /* filter, filterarg */ MAXBSIZE, BGE_NSEG_NEW, /* maxsize, nsegments */ BUS_SPACE_MAXSIZE_32BIT,/* maxsegsize */ BUS_DMA_ALLOCNOW, /* flags */ NULL, NULL, /* lockfunc, lockarg */ &sc->bge_cdata.bge_parent_tag);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200312120823.hBC8N6Ai074269>