ath9k: fix rate control fallback rate selection
authorFelix Fietkau <nbd@openwrt.org>
Fri, 19 Feb 2010 00:46:36 +0000 (01:46 +0100)
committerJohn W. Linville <linville@tuxdriver.com>
Fri, 19 Feb 2010 20:52:48 +0000 (15:52 -0500)
commit5c0ba62fd4b2dce08055a89600f1d834f9f0fe9e
tree269325db69c99e953abdc98cf4fc0f48a69f51fc
parent54f2d7361da09f3fc2b5407f93ad3b86df951577
ath9k: fix rate control fallback rate selection

When selecting the tx fallback rate, rc.c used a separate variable
'nrix' for storing the next rate index, however it did not use that as
reference for further rate index lowering. Because of that, it ended up
reusing the same rate for multiple multi-rate retry stages, thus
decreasing delivery probability under changing link conditions.

This patch removes the separate (unnecessary) variable and fixes
fallback the way it was intended to work.
This should result in increased throughput and better link stability.

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Cc: stable@kernel.org
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/ath/ath9k/rc.c