]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
3.10-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 3 Oct 2014 17:54:35 +0000 (10:54 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 3 Oct 2014 17:54:35 +0000 (10:54 -0700)
added patches:
revert-iwlwifi-dvm-don-t-enable-cts-to-self.patch
workqueue-apply-__wq_ordered-to-create_singlethread_workqueue.patch

queue-3.10/revert-iwlwifi-dvm-don-t-enable-cts-to-self.patch [new file with mode: 0644]
queue-3.10/series
queue-3.10/workqueue-apply-__wq_ordered-to-create_singlethread_workqueue.patch [new file with mode: 0644]

diff --git a/queue-3.10/revert-iwlwifi-dvm-don-t-enable-cts-to-self.patch b/queue-3.10/revert-iwlwifi-dvm-don-t-enable-cts-to-self.patch
new file mode 100644 (file)
index 0000000..a3e5696
--- /dev/null
@@ -0,0 +1,48 @@
+From f47f46d7b09cf1d09e4b44b6cc4dd7d68a08028c Mon Sep 17 00:00:00 2001
+From: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
+Date: Sun, 31 Aug 2014 22:11:11 +0300
+Subject: Revert "iwlwifi: dvm: don't enable CTS to self"
+
+From: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
+
+commit f47f46d7b09cf1d09e4b44b6cc4dd7d68a08028c upstream.
+
+This reverts commit 43d826ca5979927131685cc2092c7ce862cb91cd.
+
+This commit caused packet loss.
+
+Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/net/wireless/iwlwifi/dvm/rxon.c |   12 ++++++++++++
+ 1 file changed, 12 insertions(+)
+
+--- a/drivers/net/wireless/iwlwifi/dvm/rxon.c
++++ b/drivers/net/wireless/iwlwifi/dvm/rxon.c
+@@ -1072,6 +1072,13 @@ int iwlagn_commit_rxon(struct iwl_priv *
+       /* recalculate basic rates */
+       iwl_calc_basic_rates(priv, ctx);
++      /*
++       * force CTS-to-self frames protection if RTS-CTS is not preferred
++       * one aggregation protection method
++       */
++      if (!priv->hw_params.use_rts_for_aggregation)
++              ctx->staging.flags |= RXON_FLG_SELF_CTS_EN;
++
+       if ((ctx->vif && ctx->vif->bss_conf.use_short_slot) ||
+           !(ctx->staging.flags & RXON_FLG_BAND_24G_MSK))
+               ctx->staging.flags |= RXON_FLG_SHORT_SLOT_MSK;
+@@ -1477,6 +1484,11 @@ void iwlagn_bss_info_changed(struct ieee
+       else
+               ctx->staging.flags &= ~RXON_FLG_TGG_PROTECT_MSK;
++      if (bss_conf->use_cts_prot)
++              ctx->staging.flags |= RXON_FLG_SELF_CTS_EN;
++      else
++              ctx->staging.flags &= ~RXON_FLG_SELF_CTS_EN;
++
+       memcpy(ctx->staging.bssid_addr, bss_conf->bssid, ETH_ALEN);
+       if (vif->type == NL80211_IFTYPE_AP ||
index 962c527444d4646fbbcff031fcc8657029f18405..8aec9103acb32dfb8dd90f36d3ac7517b6397797 100644 (file)
@@ -89,3 +89,5 @@ iscsi-target-avoid-null-pointer-in-iscsi_copy_param_list-failure.patch
 iscsi-target-fix-memory-corruption-in-iscsit_logout_post_handler_diffcid.patch
 nfc-microread-potential-overflows-in-microread_target_discovered.patch
 scsi-libiscsi-fix-potential-buffer-overrun-in-__iscsi_conn_send_pdu.patch
+revert-iwlwifi-dvm-don-t-enable-cts-to-self.patch
+workqueue-apply-__wq_ordered-to-create_singlethread_workqueue.patch
diff --git a/queue-3.10/workqueue-apply-__wq_ordered-to-create_singlethread_workqueue.patch b/queue-3.10/workqueue-apply-__wq_ordered-to-create_singlethread_workqueue.patch
new file mode 100644 (file)
index 0000000..f987f80
--- /dev/null
@@ -0,0 +1,67 @@
+From e09c2c295468476a239d13324ce9042ec4de05eb Mon Sep 17 00:00:00 2001
+From: Tejun Heo <tj@kernel.org>
+Date: Sat, 13 Sep 2014 04:14:30 +0900
+Subject: workqueue: apply __WQ_ORDERED to create_singlethread_workqueue()
+
+From: Tejun Heo <tj@kernel.org>
+
+commit e09c2c295468476a239d13324ce9042ec4de05eb upstream.
+
+create_singlethread_workqueue() is a compat interface for single
+threaded workqueue which maps to ordered workqueue w/ rescuer in the
+current implementation.  create_singlethread_workqueue() currently
+implemented by invoking alloc_workqueue() w/ appropriate parameters.
+
+8719dceae2f9 ("workqueue: reject adjusting max_active or applying
+attrs to ordered workqueues") introduced __WQ_ORDERED to protect
+ordered workqueues against dynamic attribute changes which can break
+ordering guarantees but forgot to apply it to
+create_singlethread_workqueue().  This in itself is okay as nobody
+currently uses dynamic attribute change on workqueues created with
+create_singlethread_workqueue().
+
+However, 4c16bd327c ("workqueue: implement NUMA affinity for unbound
+workqueues") broke singlethreaded guarantee for ordered workqueues
+through allocating a separate pool_workqueue on each NUMA node by
+default.  A later change 8a2b75384444 ("workqueue: fix ordered
+workqueues in NUMA setups") fixed it by allocating only one global
+pool_workqueue if __WQ_ORDERED is set.
+
+Combined, the __WQ_ORDERED omission in create_singlethread_workqueue()
+became critical breaking its single threadedness and ordering
+guarantee.
+
+Let's make create_singlethread_workqueue() wrap
+alloc_ordered_workqueue() instead so that it inherits __WQ_ORDERED and
+can implicitly track future ordered_workqueue changes.
+
+v2: I missed that __WQ_ORDERED now protects against pwq splitting
+    across NUMA nodes and incorrectly described the patch as a
+    nice-to-have fix to protect against future dynamic attribute
+    usages.  Oleg pointed out that this is actually a critical
+    breakage due to 8a2b75384444 ("workqueue: fix ordered workqueues
+    in NUMA setups").
+
+Signed-off-by: Tejun Heo <tj@kernel.org>
+Reported-by: Mike Anderson <mike.anderson@us.ibm.com>
+Cc: Oleg Nesterov <onestero@redhat.com>
+Cc: Gustavo Luiz Duarte <gduarte@redhat.com>
+Cc: Tomas Henzl <thenzl@redhat.com>
+Fixes: 4c16bd327c ("workqueue: implement NUMA affinity for unbound workqueues")
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ include/linux/workqueue.h |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/include/linux/workqueue.h
++++ b/include/linux/workqueue.h
+@@ -414,7 +414,7 @@ __alloc_workqueue_key(const char *fmt, u
+ #define create_freezable_workqueue(name)                              \
+       alloc_workqueue((name), WQ_FREEZABLE | WQ_UNBOUND | WQ_MEM_RECLAIM, 1)
+ #define create_singlethread_workqueue(name)                           \
+-      alloc_workqueue((name), WQ_UNBOUND | WQ_MEM_RECLAIM, 1)
++      alloc_ordered_workqueue("%s", WQ_MEM_RECLAIM, name)
+ extern void destroy_workqueue(struct workqueue_struct *wq);