]> git.baikalelectronics.ru Git - kernel.git/commit
mac80211: minstrel: remove deferred sampling code
authorFelix Fietkau <nbd@nbd.name>
Wed, 11 Nov 2020 18:33:58 +0000 (19:33 +0100)
committerJohannes Berg <johannes.berg@intel.com>
Thu, 12 Nov 2020 10:24:43 +0000 (11:24 +0100)
commit93bdfe14d3328b1d0102f1e16585691ed41dd6bc
tree6c402a7dba18eaaf8be7d4963443c833df43e535
parente4b222baf0e62e3addab367ee4b5a87b68a8196e
mac80211: minstrel: remove deferred sampling code

Deferring sampling attempts to the second stage has some bad interactions
with drivers that process the rate table in hardware and use the probe flag
to indicate probing packets (e.g. most mt76 drivers). On affected drivers
it can lead to probing not working at all.

If the link conditions turn worse, it might not be such a good idea to
do a lot of sampling for lower rates in this case.

Fix this by simply skipping the sample attempt instead of deferring it,
but keep the checks that would allow it to be sampled if it was skipped
too often, but only if it has less than 95% success probability.

Also ensure that IEEE80211_TX_CTL_RATE_CTRL_PROBE is set for all probing
packets.

Cc: stable@vger.kernel.org
Fixes: e94ee7e3e9b7 ("mac80211: add the 'minstrel' rate control algorithm")
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Link: https://lore.kernel.org/r/20201111183359.43528-2-nbd@nbd.name
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
net/mac80211/rc80211_minstrel.c
net/mac80211/rc80211_minstrel.h