All of lore.kernel.org
 help / color / mirror / Atom feed
* [ath9k-devel] [RFC] ath9k: improve aggregation throughput by using only first rate
@ 2010-07-26 17:10 ` Björn Smedman
  0 siblings, 0 replies; 14+ messages in thread
From: Björn Smedman @ 2010-07-26 17:10 UTC (permalink / raw)
  To: ath9k-devel

Hi all,

I've been running a lot of iperf on AR913x /
compat-wireless-2010-07-16 (w/ openwrt/trunk at 22388).

I think there are some (in theory) simple improvements that can be
done to the tx aggregation / rate control logic. A proof of concept of
one such improvement is provided below. Basically, it's a hack that
makes ath9k output aggregates with only the first rate in the rate
series. The reasoning is that a failure is not a problem for
aggregates because there is software retry. Retrying in hardware at a
slower rate is counter productive. So, better to fail and do a
software retry at possibly another rate. Also, since the aggregate
size is often limited by the slowest rate in the MRR series (4 ms txop
limit) having a slow rate in the series may affect performance even if
it is never used by the hardware.

In my (not so scientific) tests max AP downstream throughput increases
about 30-40% with the patch below (from 33.9 to 55.7 Mbit/s with HT20
in noisy environment with 20 meters and a few walls between AP and
client).

Of course, if all rates in the series are high then this patch has no effect.

/Bj?rn
---
diff -urpN a/drivers/net/wireless/ath/ath9k/xmit.c
b/drivers/net/wireless/ath/ath9k/xmit.c
--- a/drivers/net/wireless/ath/ath9k/xmit.c	2010-07-26 15:35:17.000000000 +0200
+++ b/drivers/net/wireless/ath/ath9k/xmit.c	2010-07-26 17:11:33.000000000 +0200
@@ -565,7 +565,7 @@ static u32 ath_lookup_rate(struct ath_so
 	 */
 	max_4ms_framelen = ATH_AMPDU_LIMIT_MAX;

-	for (i = 0; i < 4; i++) {
+	for (i = 0; i < 1; i++) {
 		if (rates[i].count) {
 			int modeidx;
 			if (!(rates[i].flags & IEEE80211_TX_RC_MCS)) {
@@ -1553,6 +1553,9 @@ static void ath_buf_set_rate(struct ath_
 	if (sc->sc_flags & SC_OP_PREAMBLE_SHORT)
 		ctsrate |= rate->hw_value_short;

+	if (bf_isaggr(bf))
+		rates[1].count = rates[2].count = rates[3].count = 0;
+
 	for (i = 0; i < 4; i++) {
 		bool is_40, is_sgi, is_sp;
 		int phy;

^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2010-07-27  4:48 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-07-26 17:10 [ath9k-devel] [RFC] ath9k: improve aggregation throughput by using only first rate Björn Smedman
2010-07-26 17:10 ` Björn Smedman
2010-07-26 17:44 ` [ath9k-devel] " Felix Fietkau
2010-07-26 17:44   ` Felix Fietkau
2010-07-26 19:23   ` Björn Smedman
2010-07-26 19:23     ` Björn Smedman
2010-07-26 19:41     ` Felix Fietkau
2010-07-26 19:41       ` Felix Fietkau
2010-07-26 20:37       ` Björn Smedman
2010-07-26 20:37         ` Björn Smedman
2010-07-26 20:41         ` Felix Fietkau
2010-07-26 20:41           ` Felix Fietkau
2010-07-27  4:48       ` Ranga Rao Ravuri
2010-07-27  4:48         ` Ranga Rao Ravuri

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.