Lines Matching refs:bf
248 ath_legacy_rxbuf_init(struct ath_softc *sc, struct ath_buf *bf) in ath_legacy_rxbuf_init() argument
257 m = bf->bf_m; in ath_legacy_rxbuf_init()
276 bf->bf_dmamap, m, in ath_legacy_rxbuf_init()
277 bf->bf_segs, &bf->bf_nseg, in ath_legacy_rxbuf_init()
287 KASSERT(bf->bf_nseg == 1, in ath_legacy_rxbuf_init()
288 ("multi-segment packet; nseg %u", bf->bf_nseg)); in ath_legacy_rxbuf_init()
289 bf->bf_m = m; in ath_legacy_rxbuf_init()
291 bus_dmamap_sync(sc->sc_dmat, bf->bf_dmamap, BUS_DMASYNC_PREREAD); in ath_legacy_rxbuf_init()
314 ds = bf->bf_desc; in ath_legacy_rxbuf_init()
316 ds->ds_link = bf->bf_daddr; /* link to self */ in ath_legacy_rxbuf_init()
319 ds->ds_data = bf->bf_segs[0].ds_addr; in ath_legacy_rxbuf_init()
326 *sc->sc_rxlink = bf->bf_daddr; in ath_legacy_rxbuf_init()
642 uint64_t tsf, int nf, HAL_RX_QUEUE qtype, struct ath_buf *bf, in ath_rx_pkt() argument
823 ath_printrxbuf(sc, bf, 0, status == HAL_OK); in ath_rx_pkt()
1041 struct ath_buf *bf; in ath_rx_proc() local
1085 bf = TAILQ_FIRST(&sc->sc_rxbuf); in ath_rx_proc()
1086 if (sc->sc_rxslink && bf == NULL) { /* NB: shouldn't happen */ in ath_rx_proc()
1089 } else if (bf == NULL) { in ath_rx_proc()
1097 m = bf->bf_m; in ath_rx_proc()
1105 TAILQ_REMOVE(&sc->sc_rxbuf, bf, bf_list); in ath_rx_proc()
1108 ds = bf->bf_desc; in ath_rx_proc()
1109 if (ds->ds_link == bf->bf_daddr) { in ath_rx_proc()
1126 rs = &bf->bf_status.ds_rxstat; in ath_rx_proc()
1128 bf->bf_daddr, PA2DESC(sc, ds->ds_link), rs); in ath_rx_proc()
1131 ath_printrxbuf(sc, bf, 0, status == HAL_OK); in ath_rx_proc()
1143 TAILQ_REMOVE(&sc->sc_rxbuf, bf, bf_list); in ath_rx_proc()
1149 bus_dmamap_sync(sc->sc_dmat, bf->bf_dmamap, BUS_DMASYNC_POSTREAD); in ath_rx_proc()
1150 bus_dmamap_unload(sc->sc_dmat, bf->bf_dmamap); in ath_rx_proc()
1151 bf->bf_m = NULL; in ath_rx_proc()
1152 if (ath_rx_pkt(sc, rs, status, tsf, nf, HAL_RX_QUEUE_HP, bf, m)) in ath_rx_proc()
1173 sc->sc_rxedma[HAL_RX_QUEUE_HP].m_holdbf = bf; in ath_rx_proc()
1227 bf = TAILQ_FIRST(&sc->sc_rxbuf); in ath_rx_proc()
1228 ath_hal_putrxbuf(ah, bf->bf_daddr, HAL_RX_QUEUE_HP); in ath_rx_proc()
1317 struct ath_buf *bf; in ath_legacy_flush_rxholdbf() local
1327 bf = sc->sc_rxedma[HAL_RX_QUEUE_HP].m_holdbf; in ath_legacy_flush_rxholdbf()
1328 if (bf != NULL) { in ath_legacy_flush_rxholdbf()
1329 if (bf->bf_m != NULL) in ath_legacy_flush_rxholdbf()
1330 m_freem(bf->bf_m); in ath_legacy_flush_rxholdbf()
1331 bf->bf_m = NULL; in ath_legacy_flush_rxholdbf()
1332 TAILQ_INSERT_TAIL(&sc->sc_rxbuf, bf, bf_list); in ath_legacy_flush_rxholdbf()
1333 (void) ath_rxbuf_init(sc, bf); in ath_legacy_flush_rxholdbf()
1337 bf = sc->sc_rxedma[HAL_RX_QUEUE_LP].m_holdbf; in ath_legacy_flush_rxholdbf()
1338 if (bf != NULL) { in ath_legacy_flush_rxholdbf()
1339 if (bf->bf_m != NULL) in ath_legacy_flush_rxholdbf()
1340 m_freem(bf->bf_m); in ath_legacy_flush_rxholdbf()
1341 bf->bf_m = NULL; in ath_legacy_flush_rxholdbf()
1342 TAILQ_INSERT_TAIL(&sc->sc_rxbuf, bf, bf_list); in ath_legacy_flush_rxholdbf()
1343 (void) ath_rxbuf_init(sc, bf); in ath_legacy_flush_rxholdbf()
1376 struct ath_buf *bf; in ath_legacy_stoprecv() local
1385 TAILQ_FOREACH(bf, &sc->sc_rxbuf, bf_list) { in ath_legacy_stoprecv()
1386 struct ath_desc *ds = bf->bf_desc; in ath_legacy_stoprecv()
1387 struct ath_rx_status *rs = &bf->bf_status.ds_rxstat; in ath_legacy_stoprecv()
1389 bf->bf_daddr, PA2DESC(sc, ds->ds_link), rs); in ath_legacy_stoprecv()
1391 ath_printrxbuf(sc, bf, ix, status == HAL_OK); in ath_legacy_stoprecv()
1419 struct ath_buf *bf; in ath_legacy_startrecv() local
1433 TAILQ_FOREACH(bf, &sc->sc_rxbuf, bf_list) { in ath_legacy_startrecv()
1434 int error = ath_rxbuf_init(sc, bf); in ath_legacy_startrecv()
1443 bf = TAILQ_FIRST(&sc->sc_rxbuf); in ath_legacy_startrecv()
1444 ath_hal_putrxbuf(ah, bf->bf_daddr, HAL_RX_QUEUE_HP); in ath_legacy_startrecv()