if_ath_tx.h revision 227346
1218065Sadrian/*- 2218065Sadrian * Copyright (c) 2002-2009 Sam Leffler, Errno Consulting 3218065Sadrian * All rights reserved. 4218065Sadrian * 5218065Sadrian * Redistribution and use in source and binary forms, with or without 6218065Sadrian * modification, are permitted provided that the following conditions 7218065Sadrian * are met: 8218065Sadrian * 1. Redistributions of source code must retain the above copyright 9218065Sadrian * notice, this list of conditions and the following disclaimer, 10218065Sadrian * without modification. 11218065Sadrian * 2. Redistributions in binary form must reproduce at minimum a disclaimer 12218065Sadrian * similar to the "NO WARRANTY" disclaimer below ("Disclaimer") and any 13218065Sadrian * redistribution must be conditioned upon including a substantially 14218065Sadrian * similar Disclaimer requirement for further binary redistribution. 15218065Sadrian * 16218065Sadrian * NO WARRANTY 17218065Sadrian * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 18218065Sadrian * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 19218065Sadrian * LIMITED TO, THE IMPLIED WARRANTIES OF NONINFRINGEMENT, MERCHANTIBILITY 20218065Sadrian * AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL 21218065Sadrian * THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY, 22218065Sadrian * OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 23218065Sadrian * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 24218065Sadrian * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER 25218065Sadrian * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 26218065Sadrian * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 27218065Sadrian * THE POSSIBILITY OF SUCH DAMAGES. 28218065Sadrian * 29218065Sadrian * $FreeBSD: head/sys/dev/ath/if_ath_tx.h 227346 2011-11-08 18:10:04Z adrian $ 30218065Sadrian */ 31218065Sadrian#ifndef __IF_ATH_TX_H__ 32218065Sadrian#define __IF_ATH_TX_H__ 33218065Sadrian 34227346Sadrian/* 35227346Sadrian * How 'busy' to try and keep the hardware txq 36227346Sadrian */ 37227346Sadrian#define ATH_AGGR_MIN_QDEPTH 2 38227346Sadrian 39227346Sadrian/* 40227346Sadrian * Watermark for scheduling TIDs in order to maximise aggregation. 41227346Sadrian * 42227346Sadrian * If hwq_depth is greater than this, don't schedule the TID 43227346Sadrian * for packet scheduling - the hardware is already busy servicing 44227346Sadrian * this TID. 45227346Sadrian * 46227346Sadrian * If hwq_depth is less than this, schedule the TID for packet 47227346Sadrian * scheduling in the completion handler. 48227346Sadrian */ 49227346Sadrian#define ATH_AGGR_SCHED_HIGH 4 50227346Sadrian#define ATH_AGGR_SCHED_LOW 2 51227346Sadrian 52218065Sadrianextern void ath_freetx(struct mbuf *m); 53218065Sadrianextern void ath_txfrag_cleanup(struct ath_softc *sc, ath_bufhead *frags, 54218065Sadrian struct ieee80211_node *ni); 55218065Sadrianextern int ath_txfrag_setup(struct ath_softc *sc, ath_bufhead *frags, 56218065Sadrian struct mbuf *m0, struct ieee80211_node *ni); 57218065Sadrianextern int ath_tx_start(struct ath_softc *sc, struct ieee80211_node *ni, 58218065Sadrian struct ath_buf *bf, struct mbuf *m0); 59218065Sadrianextern int ath_raw_xmit(struct ieee80211_node *ni, struct mbuf *m, 60218065Sadrian const struct ieee80211_bpf_params *params); 61218065Sadrian 62218065Sadrian#endif 63