]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
patches for 4.4
authorSasha Levin <sashal@kernel.org>
Wed, 19 Dec 2018 00:46:56 +0000 (19:46 -0500)
committerSasha Levin <sashal@kernel.org>
Wed, 19 Dec 2018 00:46:56 +0000 (19:46 -0500)
Signed-off-by: Sasha Levin <sashal@kernel.org>
queue-4.4/mac80211-don-t-warn-on-bad-wmm-parameters-from-buggy.patch [new file with mode: 0644]
queue-4.4/mac80211-fix-condition-validating-wmm-ie.patch [new file with mode: 0644]
queue-4.4/series

diff --git a/queue-4.4/mac80211-don-t-warn-on-bad-wmm-parameters-from-buggy.patch b/queue-4.4/mac80211-don-t-warn-on-bad-wmm-parameters-from-buggy.patch
new file mode 100644 (file)
index 0000000..6480f81
--- /dev/null
@@ -0,0 +1,44 @@
+From 945f5c1ba8b01c5a08ce9a558ac4419f7a31d200 Mon Sep 17 00:00:00 2001
+From: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
+Date: Mon, 26 Mar 2018 16:21:04 +0300
+Subject: mac80211: don't WARN on bad WMM parameters from buggy APs
+
+[ Upstream commit c470bdc1aaf36669e04ba65faf1092b2d1c6cabe ]
+
+Apparently, some APs are buggy enough to send a zeroed
+WMM IE. Don't WARN on this since this is not caused by a bug
+on the client's system.
+
+This aligns the condition of the WARNING in drv_conf_tx
+with the validity check in ieee80211_sta_wmm_params.
+We will now pick the default values whenever we get
+a zeroed WMM IE.
+
+This has been reported here:
+https://bugzilla.kernel.org/show_bug.cgi?id=199161
+
+Fixes: f409079bb678 ("mac80211: sanity check CW_min/CW_max towards driver")
+Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
+Signed-off-by: Johannes Berg <johannes.berg@intel.com>
+Signed-off-by: Sasha Levin <sashal@kernel.org>
+---
+ net/mac80211/mlme.c | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/net/mac80211/mlme.c b/net/mac80211/mlme.c
+index a5e11280f405..51f31e77c19b 100644
+--- a/net/mac80211/mlme.c
++++ b/net/mac80211/mlme.c
+@@ -1886,7 +1886,8 @@ static bool ieee80211_sta_wmm_params(struct ieee80211_local *local,
+               params[ac].acm = acm;
+               params[ac].uapsd = uapsd;
+-              if (params[ac].cw_min > params[ac].cw_max) {
++              if (params->cw_min == 0 ||
++                  params[ac].cw_min > params[ac].cw_max) {
+                       sdata_info(sdata,
+                                  "AP has invalid WMM params (CWmin/max=%d/%d for ACI %d), using defaults\n",
+                                  params[ac].cw_min, params[ac].cw_max, aci);
+-- 
+2.19.1
+
diff --git a/queue-4.4/mac80211-fix-condition-validating-wmm-ie.patch b/queue-4.4/mac80211-fix-condition-validating-wmm-ie.patch
new file mode 100644 (file)
index 0000000..c425372
--- /dev/null
@@ -0,0 +1,38 @@
+From d2ea0de9738f4bc1113f7ab5527411b96d70a22a Mon Sep 17 00:00:00 2001
+From: Ilan Peer <ilan.peer@intel.com>
+Date: Tue, 3 Apr 2018 11:35:22 +0300
+Subject: mac80211: Fix condition validating WMM IE
+
+[ Upstream commit 911a26484c33e10de6237228ca1d7293548e9f49 ]
+
+Commit c470bdc1aaf3 ("mac80211: don't WARN on bad WMM parameters from
+buggy APs") handled cases where an AP reports a zeroed WMM
+IE. However, the condition that checks the validity accessed the wrong
+index in the ieee80211_tx_queue_params array, thus wrongly deducing
+that the parameters are invalid. Fix it.
+
+Fixes: c470bdc1aaf3 ("mac80211: don't WARN on bad WMM parameters from buggy APs")
+Signed-off-by: Ilan Peer <ilan.peer@intel.com>
+Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
+Signed-off-by: Johannes Berg <johannes.berg@intel.com>
+Signed-off-by: Sasha Levin <sashal@kernel.org>
+---
+ net/mac80211/mlme.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/net/mac80211/mlme.c b/net/mac80211/mlme.c
+index 51f31e77c19b..ed4fef32b394 100644
+--- a/net/mac80211/mlme.c
++++ b/net/mac80211/mlme.c
+@@ -1886,7 +1886,7 @@ static bool ieee80211_sta_wmm_params(struct ieee80211_local *local,
+               params[ac].acm = acm;
+               params[ac].uapsd = uapsd;
+-              if (params->cw_min == 0 ||
++              if (params[ac].cw_min == 0 ||
+                   params[ac].cw_min > params[ac].cw_max) {
+                       sdata_info(sdata,
+                                  "AP has invalid WMM params (CWmin/max=%d/%d for ACI %d), using defaults\n",
+-- 
+2.19.1
+
index 678815cf94d4e5368634da4f6e8bdb73514cd0ea..1ada263ae65db101d37b42a4c8623a0d91500e36 100644 (file)
@@ -13,3 +13,5 @@ tracing-fix-memory-leak-of-instance-function-hash-filters.patch
 powerpc-msi-fix-null-pointer-access-in-teardown-code.patch
 revert-drm-rockchip-allow-driver-to-be-shutdown-on-reboot-kexec.patch
 f2fs-fix-a-panic-caused-by-null-flush_cmd_control.patch
+mac80211-don-t-warn-on-bad-wmm-parameters-from-buggy.patch
+mac80211-fix-condition-validating-wmm-ie.patch