summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/ath9k/recv.c
diff options
context:
space:
mode:
authorSujith <Sujith.Manoharan@atheros.com>2008-10-29 07:43:31 +0300
committerJohn W. Linville <linville@tuxdriver.com>2008-11-10 23:14:55 +0300
commitb5aa9bf9460f9e97f2c10940b029d75c6557ad7c (patch)
tree60bc06b72761339e048139fdb076de14f2f4273e /drivers/net/wireless/ath9k/recv.c
parent17683c65c8a5f3f29f5408334992986b996d8205 (diff)
downloadlinux-b5aa9bf9460f9e97f2c10940b029d75c6557ad7c.tar.xz
ath9k: Node cleanup
Start removing the internal node list in ath9k, in preparation for using mac80211's STA list. Remove lists, locks, routines, flags, functions managing nodes in ath9k. Signed-off-by: Sujith <Sujith.Manoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath9k/recv.c')
-rw-r--r--drivers/net/wireless/ath9k/recv.c42
1 files changed, 6 insertions, 36 deletions
diff --git a/drivers/net/wireless/ath9k/recv.c b/drivers/net/wireless/ath9k/recv.c
index 828322840a86..6b4006ed4e01 100644
--- a/drivers/net/wireless/ath9k/recv.c
+++ b/drivers/net/wireless/ath9k/recv.c
@@ -1095,7 +1095,7 @@ rx_next:
/* Process ADDBA request in per-TID data structure */
int ath_rx_aggr_start(struct ath_softc *sc,
- const u8 *addr,
+ struct ieee80211_sta *sta,
u16 tid,
u16 *ssn)
{
@@ -1105,17 +1105,7 @@ int ath_rx_aggr_start(struct ath_softc *sc,
struct ieee80211_supported_band *sband;
u16 buffersize = 0;
- spin_lock_bh(&sc->node_lock);
- an = ath_node_find(sc, (u8 *) addr);
- spin_unlock_bh(&sc->node_lock);
-
- if (!an) {
- DPRINTF(sc, ATH_DBG_AGGR,
- "%s: Node not found to initialize RX aggregation\n",
- __func__);
- return -1;
- }
-
+ an = (struct ath_node *)sta->drv_priv;
sband = hw->wiphy->bands[hw->conf.channel->band];
buffersize = IEEE80211_MIN_AMPDU_BUF <<
sband->ht_cap.ampdu_factor; /* FIXME */
@@ -1172,21 +1162,9 @@ int ath_rx_aggr_start(struct ath_softc *sc,
/* Process DELBA */
-int ath_rx_aggr_stop(struct ath_softc *sc,
- const u8 *addr,
- u16 tid)
+int ath_rx_aggr_stop(struct ath_softc *sc, struct ieee80211_sta *sta, u16 tid)
{
- struct ath_node *an;
-
- spin_lock_bh(&sc->node_lock);
- an = ath_node_find(sc, (u8 *) addr);
- spin_unlock_bh(&sc->node_lock);
-
- if (!an) {
- DPRINTF(sc, ATH_DBG_AGGR,
- "%s: RX aggr stop for non-existent node\n", __func__);
- return -1;
- }
+ struct ath_node *an = (struct ath_node *)sta->drv_priv;
ath_rx_aggr_teardown(sc, an, tid);
return 0;
@@ -1194,8 +1172,7 @@ int ath_rx_aggr_stop(struct ath_softc *sc,
/* Rx aggregation tear down */
-void ath_rx_aggr_teardown(struct ath_softc *sc,
- struct ath_node *an, u8 tid)
+void ath_rx_aggr_teardown(struct ath_softc *sc, struct ath_node *an, u8 tid)
{
struct ath_arx_tid *rxtid = &an->an_aggr.rx.tid[tid];
@@ -1253,7 +1230,7 @@ void ath_rx_node_init(struct ath_softc *sc, struct ath_node *an)
}
}
-void ath_rx_node_cleanup(struct ath_softc *sc, struct ath_node *an)
+void ath_rx_node_free(struct ath_softc *sc, struct ath_node *an)
{
if (sc->sc_flags & SC_OP_RXAGGR) {
struct ath_arx_tid *rxtid;
@@ -1281,10 +1258,3 @@ void ath_rx_node_cleanup(struct ath_softc *sc, struct ath_node *an)
}
}
-
-/* Cleanup per-node receive state */
-
-void ath_rx_node_free(struct ath_softc *sc, struct ath_node *an)
-{
- ath_rx_node_cleanup(sc, an);
-}