diff options
author | Felix Fietkau <nbd@nbd.name> | 2016-12-15 11:48:12 +0100 |
---|---|---|
committer | Felix Fietkau <nbd@nbd.name> | 2016-12-19 13:51:21 +0100 |
commit | 00bc7f0357d082e73699fb561776088e48e53101 (patch) | |
tree | 92396001e5678f24e207464bd83fe63e8b5caaca /package/kernel/mac80211/patches/339-mac80211-minstrel-reduce-MINSTREL_SCALE.patch | |
parent | 6f77b8d510e2308f85344cd46de96dadc07a6cb9 (diff) | |
download | upstream-00bc7f0357d082e73699fb561776088e48e53101.tar.gz upstream-00bc7f0357d082e73699fb561776088e48e53101.tar.bz2 upstream-00bc7f0357d082e73699fb561776088e48e53101.zip |
mac80211: merge a number of minstrel/minstrel_ht performance and memory usage improvements
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'package/kernel/mac80211/patches/339-mac80211-minstrel-reduce-MINSTREL_SCALE.patch')
-rw-r--r-- | package/kernel/mac80211/patches/339-mac80211-minstrel-reduce-MINSTREL_SCALE.patch | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/package/kernel/mac80211/patches/339-mac80211-minstrel-reduce-MINSTREL_SCALE.patch b/package/kernel/mac80211/patches/339-mac80211-minstrel-reduce-MINSTREL_SCALE.patch new file mode 100644 index 0000000000..0416cf5900 --- /dev/null +++ b/package/kernel/mac80211/patches/339-mac80211-minstrel-reduce-MINSTREL_SCALE.patch @@ -0,0 +1,22 @@ +From: Felix Fietkau <nbd@nbd.name> +Date: Wed, 14 Dec 2016 20:15:33 +0100 +Subject: [PATCH] mac80211: minstrel: reduce MINSTREL_SCALE + +The loss of a bit of extra precision does not hurt the calculation, 12 +bits is still enough to calculate probabilities well. Reducing the scale +makes it easier to avoid overflows + +Signed-off-by: Felix Fietkau <nbd@nbd.name> +--- + +--- a/net/mac80211/rc80211_minstrel.h ++++ b/net/mac80211/rc80211_minstrel.h +@@ -14,7 +14,7 @@ + #define SAMPLE_COLUMNS 10 /* number of columns in sample table */ + + /* scaled fraction values */ +-#define MINSTREL_SCALE 16 ++#define MINSTREL_SCALE 12 + #define MINSTREL_FRAC(val, div) (((val) << MINSTREL_SCALE) / div) + #define MINSTREL_TRUNC(val) ((val) >> MINSTREL_SCALE) + |