From 72ca6d78f143bd3ad2505e5f14252cea4e72b634 Mon Sep 17 00:00:00 2001 From: Andrew Rybchenko Date: Sun, 22 Feb 2015 18:56:03 +0000 Subject: [PATCH] sfxge: DMA allocated memory is set to zeros because of BUS_DMA_ZERO flag It is not required to set it to zeros once again. Sponsored by: Solarflare Communications, Inc. Approved by: gnn (mentor) --- sys/dev/sfxge/sfxge_rx.c | 1 - sys/dev/sfxge/sfxge_tx.c | 1 - 2 files changed, 2 deletions(-) diff --git a/sys/dev/sfxge/sfxge_rx.c b/sys/dev/sfxge/sfxge_rx.c index e4c74bea5a7b..e73dc7d474fa 100644 --- a/sys/dev/sfxge/sfxge_rx.c +++ b/sys/dev/sfxge/sfxge_rx.c @@ -1113,7 +1113,6 @@ sfxge_rx_qinit(struct sfxge_softc *sc, unsigned int index) /* Allocate and zero DMA space. */ if ((rc = sfxge_dma_alloc(sc, EFX_RXQ_SIZE(sc->rxq_entries), esmp)) != 0) return (rc); - (void)memset(esmp->esm_base, 0, EFX_RXQ_SIZE(sc->rxq_entries)); /* Allocate buffer table entries. */ sfxge_sram_buf_tbl_alloc(sc, EFX_RXQ_NBUFS(sc->rxq_entries), diff --git a/sys/dev/sfxge/sfxge_tx.c b/sys/dev/sfxge/sfxge_tx.c index 6d5146825784..13a83f83079e 100644 --- a/sys/dev/sfxge/sfxge_tx.c +++ b/sys/dev/sfxge/sfxge_tx.c @@ -1400,7 +1400,6 @@ sfxge_tx_qinit(struct sfxge_softc *sc, unsigned int txq_index, /* Allocate and zero DMA space for the descriptor ring. */ if ((rc = sfxge_dma_alloc(sc, EFX_TXQ_SIZE(sc->txq_entries), esmp)) != 0) return (rc); - (void)memset(esmp->esm_base, 0, EFX_TXQ_SIZE(sc->txq_entries)); /* Allocate buffer table entries. */ sfxge_sram_buf_tbl_alloc(sc, EFX_TXQ_NBUFS(sc->txq_entries),