mirror of
git://projects.qi-hardware.com/openwrt-xburst.git
synced 2024-09-04 01:49:17 +03:00
mac80211: fix a few more minstrel_ht bugs (thx to Christian Lamparter)
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@20040 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
parent
bcd6a465a2
commit
ece5bacf60
@ -68,7 +68,7 @@
|
|||||||
|
|
||||||
--- /dev/null
|
--- /dev/null
|
||||||
+++ b/net/mac80211/rc80211_minstrel_ht.c
|
+++ b/net/mac80211/rc80211_minstrel_ht.c
|
||||||
@@ -0,0 +1,807 @@
|
@@ -0,0 +1,809 @@
|
||||||
+/*
|
+/*
|
||||||
+ * Copyright (C) 2010 Felix Fietkau <nbd@openwrt.org>
|
+ * Copyright (C) 2010 Felix Fietkau <nbd@openwrt.org>
|
||||||
+ *
|
+ *
|
||||||
@ -479,13 +479,15 @@
|
|||||||
+ * downgrade to a lower number of streams if necessary.
|
+ * downgrade to a lower number of streams if necessary.
|
||||||
+ */
|
+ */
|
||||||
+ rate = minstrel_get_ratestats(mi, mi->max_tp_rate);
|
+ rate = minstrel_get_ratestats(mi, mi->max_tp_rate);
|
||||||
+ if (MINSTREL_FRAC(rate->success, rate->attempts) <
|
+ if (rate->attempts > 30 &&
|
||||||
+ MINSTREL_FRAC(20, 100) && rate->attempts > 30)
|
+ MINSTREL_FRAC(rate->success, rate->attempts) <
|
||||||
|
+ MINSTREL_FRAC(20, 100))
|
||||||
+ minstrel_downgrade_rate(mi, &mi->max_tp_rate, true);
|
+ minstrel_downgrade_rate(mi, &mi->max_tp_rate, true);
|
||||||
+
|
+
|
||||||
+ rate2 = minstrel_get_ratestats(mi, mi->max_tp_rate2);
|
+ rate2 = minstrel_get_ratestats(mi, mi->max_tp_rate2);
|
||||||
+ if (MINSTREL_FRAC(rate->success, rate->attempts) <
|
+ if (rate->attempts > 30 &&
|
||||||
+ MINSTREL_FRAC(20, 100) && rate->attempts > 30)
|
+ MINSTREL_FRAC(rate->success, rate->attempts) <
|
||||||
|
+ MINSTREL_FRAC(20, 100))
|
||||||
+ minstrel_downgrade_rate(mi, &mi->max_tp_rate2, false);
|
+ minstrel_downgrade_rate(mi, &mi->max_tp_rate2, false);
|
||||||
+
|
+
|
||||||
+ if (time_after(jiffies, mi->stats_update + (mp->update_interval / 2 * HZ) / 1000))
|
+ if (time_after(jiffies, mi->stats_update + (mp->update_interval / 2 * HZ) / 1000))
|
||||||
@ -1062,7 +1064,7 @@
|
|||||||
+ struct minstrel_rate_stats *mr = &mi->groups[i].rates[j];
|
+ struct minstrel_rate_stats *mr = &mi->groups[i].rates[j];
|
||||||
+ int idx = i * MCS_GROUP_RATES + j;
|
+ int idx = i * MCS_GROUP_RATES + j;
|
||||||
+
|
+
|
||||||
+ if (!mi->groups[i].supported & BIT(j))
|
+ if (!(mi->groups[i].supported & BIT(j)))
|
||||||
+ continue;
|
+ continue;
|
||||||
+
|
+
|
||||||
+ p += sprintf(p, "HT%c0/%cGI ", htmode, gimode);
|
+ p += sprintf(p, "HT%c0/%cGI ", htmode, gimode);
|
||||||
|
Loading…
Reference in New Issue
Block a user