diff options
author | ru <ru@FreeBSD.org> | 2006-08-14 15:35:43 +0000 |
---|---|---|
committer | ru <ru@FreeBSD.org> | 2006-08-14 15:35:43 +0000 |
commit | c4f062232737a29db8d03191558d5ab93e9381f3 (patch) | |
tree | 1605199b02ae7df2be2b4d055c32aabb6ac8e21a /sys/dev/nfe | |
parent | b21e8d833ba2e71f643b6457ab29e1857aaa51f3 (diff) | |
download | FreeBSD-src-c4f062232737a29db8d03191558d5ab93e9381f3.zip FreeBSD-src-c4f062232737a29db8d03191558d5ab93e9381f3.tar.gz |
Fix alignment of RX bufs DMA map to be realistic. Maybe it works on
i386 (I don't know) but on amd64 at hand here, it paniced early at
boot.
(I'm pretty sure that PAGE_SIZE here was miscopied from another place
during porting, where in OpenBSD bus_dmamem_alloc() is used, but there
PAGE_SIZE means completely different thing.)
Diffstat (limited to 'sys/dev/nfe')
-rw-r--r-- | sys/dev/nfe/if_nfe.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/dev/nfe/if_nfe.c b/sys/dev/nfe/if_nfe.c index b06189f..5e2f2fd 100644 --- a/sys/dev/nfe/if_nfe.c +++ b/sys/dev/nfe/if_nfe.c @@ -652,7 +652,7 @@ nfe_alloc_rx_ring(struct nfe_softc *sc, struct nfe_rx_ring *ring) physaddr = jbuf->physaddr; } else { error = bus_dma_tag_create(sc->nfe_parent_tag, - PAGE_SIZE, 0, /* alignment, boundary */ + ETHER_ALIGN, 0, /* alignment, boundary */ BUS_SPACE_MAXADDR_32BIT,/* lowaddr */ BUS_SPACE_MAXADDR, /* highaddr */ NULL, NULL, /* filter, filterarg */ @@ -681,7 +681,7 @@ nfe_alloc_rx_ring(struct nfe_softc *sc, struct nfe_rx_ring *ring) error = bus_dmamap_load(data->rx_data_tag, data->rx_data_map, mtod(data->m, void *), MCLBYTES, nfe_dma_map_segs, &data->rx_data_segs, BUS_DMA_NOWAIT); if (error != 0) { - printf("nfe%d: could not load rx buf DMA map", sc->nfe_unit); + printf("nfe%d: could not load rx buf DMA map\n", sc->nfe_unit); goto fail; } |