Date: Sun, 19 Jun 2011 08:11:50 +0800 From: Adrian Chadd <adrian@freebsd.org> To: freebsd-wireless@freebsd.org Subject: [RFC] adding a timeout method to addba negotiation Message-ID: <BANLkTinOz_1THASWdw%2BtrZu52e41d5hk9A@mail.gmail.com>
index | next in thread | raw e-mail
[-- Attachment #1 --]
Hi,
This patch adds ic_addba_req_timeout() to ieee80211com. It's called if
the AMPDU TX negotiation times out.
Since TX for the given node/TID should be paused during the ADDBA
exchange (and unpaused once completed), the timeout method is needed
to also unpause the TID.
Thanks,
Adrian
[-- Attachment #2 --]
Index: ieee80211_ht.c
===================================================================
--- ieee80211_ht.c (revision 223169)
+++ ieee80211_ht.c (working copy)
@@ -217,6 +217,9 @@
int code, int baparamset, int batimeout);
static void ieee80211_addba_stop(struct ieee80211_node *ni,
struct ieee80211_tx_ampdu *tap);
+static void ieee80211_addba_req_timeout(struct ieee80211_node *ni,
+ struct ieee80211_tx_ampdu *tap);
+
static void ieee80211_bar_response(struct ieee80211_node *ni,
struct ieee80211_tx_ampdu *tap, int status);
static void ampdu_tx_stop(struct ieee80211_tx_ampdu *tap);
@@ -234,6 +237,7 @@
ic->ic_ampdu_enable = ieee80211_ampdu_enable;
ic->ic_addba_request = ieee80211_addba_request;
ic->ic_addba_response = ieee80211_addba_response;
+ ic->ic_addba_req_timeout = ieee80211_addba_req_timeout;
ic->ic_addba_stop = ieee80211_addba_stop;
ic->ic_bar_response = ieee80211_bar_response;
ic->ic_ampdu_rx_start = ampdu_rx_start;
@@ -1695,10 +1699,13 @@
addba_timeout(void *arg)
{
struct ieee80211_tx_ampdu *tap = arg;
+ struct ieee80211_node *ni = tap->txa_ni;
+ struct ieee80211com *ic = ni->ni_ic;
/* XXX ? */
tap->txa_flags &= ~IEEE80211_AGGR_XCHGPEND;
tap->txa_attempts++;
+ ic->ic_addba_req_timeout(ni, tap);
}
static void
@@ -1722,6 +1729,18 @@
}
/*
+ * Default method for an ADDBA request timeout.
+ *
+ * If software aggregation and per-TID queue management was done here,
+ * that queue would be unpaused after the ADDBA timeout occurs.
+ */
+static void
+ieee80211_addba_req_timeout(struct ieee80211_node *ni,
+ struct ieee80211_tx_ampdu *tap)
+{
+}
+
+/*
* Default method for requesting A-MPDU tx aggregation.
* We setup the specified state block and start a timer
* to wait for an ADDBA response frame.
Index: ieee80211_var.h
===================================================================
--- ieee80211_var.h (revision 223169)
+++ ieee80211_var.h (working copy)
@@ -307,6 +307,8 @@
int status, int baparamset, int batimeout);
void (*ic_addba_stop)(struct ieee80211_node *,
struct ieee80211_tx_ampdu *);
+ void (*ic_addba_req_timeout)(struct ieee80211_node *,
+ struct ieee80211_tx_ampdu *);
/* BAR response received */
void (*ic_bar_response)(struct ieee80211_node *,
struct ieee80211_tx_ampdu *, int status);
help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?BANLkTinOz_1THASWdw%2BtrZu52e41d5hk9A>
