diff options
Diffstat (limited to 'sys/dev/pci/if_bge.c')
-rw-r--r-- | sys/dev/pci/if_bge.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/sys/dev/pci/if_bge.c b/sys/dev/pci/if_bge.c index dd768e6507d..88a1deb0fbd 100644 --- a/sys/dev/pci/if_bge.c +++ b/sys/dev/pci/if_bge.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_bge.c,v 1.255 2008/11/09 15:08:26 naddy Exp $ */ +/* $OpenBSD: if_bge.c,v 1.256 2008/11/22 18:16:55 dlg Exp $ */ /* * Copyright (c) 2001 Wind River Systems @@ -915,6 +915,9 @@ bge_newbuf_std(struct bge_softc *sc, int i, struct mbuf *m, r->bge_len = m_new->m_len; r->bge_idx = i; + bus_dmamap_sync(sc->bge_dmatag, dmamap, 0, dmamap->dm_mapsize, + BUS_DMASYNC_PREREAD); + bus_dmamap_sync(sc->bge_dmatag, sc->bge_ring_map, offsetof(struct bge_ring_data, bge_rx_std_ring) + i * sizeof (struct bge_rx_bd), @@ -2494,6 +2497,8 @@ bge_rxeof(struct bge_softc *sc) stdcnt++; dmamap = sc->bge_cdata.bge_rx_std_map[rxidx]; sc->bge_cdata.bge_rx_std_map[rxidx] = 0; + bus_dmamap_sync(sc->bge_dmatag, dmamap, 0, + dmamap->dm_mapsize, BUS_DMASYNC_POSTREAD); bus_dmamap_unload(sc->bge_dmatag, dmamap); if (cur_rx->bge_flags & BGE_RXBDFLAG_ERROR) { ifp->if_ierrors++; |