]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
4.9-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 3 Mar 2020 17:07:38 +0000 (18:07 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 3 Mar 2020 17:07:38 +0000 (18:07 +0100)
added patches:
drivers-net-xgene-fix-the-order-of-the-arguments-of-alloc_etherdev_mqs.patch
mm-huge_memory.c-use-head-to-check-huge-zero-page.patch
padata-always-acquire-cpu_hotplug_lock-before-pinst-lock.patch
perf-hists-browser-restore-esc-as-zoom-out-of-dso-thread-etc.patch

queue-4.9/drivers-net-xgene-fix-the-order-of-the-arguments-of-alloc_etherdev_mqs.patch [new file with mode: 0644]
queue-4.9/mm-huge_memory.c-use-head-to-check-huge-zero-page.patch [new file with mode: 0644]
queue-4.9/padata-always-acquire-cpu_hotplug_lock-before-pinst-lock.patch [new file with mode: 0644]
queue-4.9/perf-hists-browser-restore-esc-as-zoom-out-of-dso-thread-etc.patch [new file with mode: 0644]
queue-4.9/series

diff --git a/queue-4.9/drivers-net-xgene-fix-the-order-of-the-arguments-of-alloc_etherdev_mqs.patch b/queue-4.9/drivers-net-xgene-fix-the-order-of-the-arguments-of-alloc_etherdev_mqs.patch
new file mode 100644 (file)
index 0000000..c8a1820
--- /dev/null
@@ -0,0 +1,37 @@
+From 5a44c71ccda60a50073c5d7fe3f694cdfa3ab0c2 Mon Sep 17 00:00:00 2001
+From: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
+Date: Sun, 26 Jan 2020 11:44:29 +0100
+Subject: drivers: net: xgene: Fix the order of the arguments of 'alloc_etherdev_mqs()'
+
+From: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
+
+commit 5a44c71ccda60a50073c5d7fe3f694cdfa3ab0c2 upstream.
+
+'alloc_etherdev_mqs()' expects first 'tx', then 'rx'. The semantic here
+looks reversed.
+
+Reorder the arguments passed to 'alloc_etherdev_mqs()' in order to keep
+the correct semantic.
+
+In fact, this is a no-op because both XGENE_NUM_[RT]X_RING are 8.
+
+Fixes: 107dec2749fe ("drivers: net: xgene: Add support for multiple queues")
+Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/net/ethernet/apm/xgene/xgene_enet_main.c |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/drivers/net/ethernet/apm/xgene/xgene_enet_main.c
++++ b/drivers/net/ethernet/apm/xgene/xgene_enet_main.c
+@@ -1711,7 +1711,7 @@ static int xgene_enet_probe(struct platf
+       int ret;
+       ndev = alloc_etherdev_mqs(sizeof(struct xgene_enet_pdata),
+-                                XGENE_NUM_RX_RING, XGENE_NUM_TX_RING);
++                                XGENE_NUM_TX_RING, XGENE_NUM_RX_RING);
+       if (!ndev)
+               return -ENOMEM;
diff --git a/queue-4.9/mm-huge_memory.c-use-head-to-check-huge-zero-page.patch b/queue-4.9/mm-huge_memory.c-use-head-to-check-huge-zero-page.patch
new file mode 100644 (file)
index 0000000..9aff9da
--- /dev/null
@@ -0,0 +1,36 @@
+From cb829624867b5ab10bc6a7036d183b1b82bfe9f8 Mon Sep 17 00:00:00 2001
+From: Wei Yang <richardw.yang@linux.intel.com>
+Date: Thu, 30 Jan 2020 22:14:29 -0800
+Subject: mm/huge_memory.c: use head to check huge zero page
+
+From: Wei Yang <richardw.yang@linux.intel.com>
+
+commit cb829624867b5ab10bc6a7036d183b1b82bfe9f8 upstream.
+
+The page could be a tail page, if this is the case, this BUG_ON will
+never be triggered.
+
+Link: http://lkml.kernel.org/r/20200110032610.26499-1-richardw.yang@linux.intel.com
+Fixes: e9b61f19858a ("thp: reintroduce split_huge_page()")
+
+Signed-off-by: Wei Yang <richardw.yang@linux.intel.com>
+Acked-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>
+Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
+Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ mm/huge_memory.c |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/mm/huge_memory.c
++++ b/mm/huge_memory.c
+@@ -2095,7 +2095,7 @@ int split_huge_page_to_list(struct page
+       unsigned long flags;
+       pgoff_t end;
+-      VM_BUG_ON_PAGE(is_huge_zero_page(page), page);
++      VM_BUG_ON_PAGE(is_huge_zero_page(head), head);
+       VM_BUG_ON_PAGE(!PageLocked(page), page);
+       VM_BUG_ON_PAGE(!PageSwapBacked(page), page);
+       VM_BUG_ON_PAGE(!PageCompound(page), page);
diff --git a/queue-4.9/padata-always-acquire-cpu_hotplug_lock-before-pinst-lock.patch b/queue-4.9/padata-always-acquire-cpu_hotplug_lock-before-pinst-lock.patch
new file mode 100644 (file)
index 0000000..e09bd23
--- /dev/null
@@ -0,0 +1,67 @@
+From 38228e8848cd7dd86ccb90406af32de0cad24be3 Mon Sep 17 00:00:00 2001
+From: Daniel Jordan <daniel.m.jordan@oracle.com>
+Date: Tue, 3 Dec 2019 14:31:11 -0500
+Subject: padata: always acquire cpu_hotplug_lock before pinst->lock
+
+From: Daniel Jordan <daniel.m.jordan@oracle.com>
+
+commit 38228e8848cd7dd86ccb90406af32de0cad24be3 upstream.
+
+lockdep complains when padata's paths to update cpumasks via CPU hotplug
+and sysfs are both taken:
+
+  # echo 0 > /sys/devices/system/cpu/cpu1/online
+  # echo ff > /sys/kernel/pcrypt/pencrypt/parallel_cpumask
+
+  ======================================================
+  WARNING: possible circular locking dependency detected
+  5.4.0-rc8-padata-cpuhp-v3+ #1 Not tainted
+  ------------------------------------------------------
+  bash/205 is trying to acquire lock:
+  ffffffff8286bcd0 (cpu_hotplug_lock.rw_sem){++++}, at: padata_set_cpumask+0x2b/0x120
+
+  but task is already holding lock:
+  ffff8880001abfa0 (&pinst->lock){+.+.}, at: padata_set_cpumask+0x26/0x120
+
+  which lock already depends on the new lock.
+
+padata doesn't take cpu_hotplug_lock and pinst->lock in a consistent
+order.  Which should be first?  CPU hotplug calls into padata with
+cpu_hotplug_lock already held, so it should have priority.
+
+Fixes: 6751fb3c0e0c ("padata: Use get_online_cpus/put_online_cpus")
+Signed-off-by: Daniel Jordan <daniel.m.jordan@oracle.com>
+Cc: Eric Biggers <ebiggers@kernel.org>
+Cc: Herbert Xu <herbert@gondor.apana.org.au>
+Cc: Steffen Klassert <steffen.klassert@secunet.com>
+Cc: linux-crypto@vger.kernel.org
+Cc: linux-kernel@vger.kernel.org
+Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ kernel/padata.c |    4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+--- a/kernel/padata.c
++++ b/kernel/padata.c
+@@ -614,8 +614,8 @@ int padata_set_cpumask(struct padata_ins
+       struct cpumask *serial_mask, *parallel_mask;
+       int err = -EINVAL;
+-      mutex_lock(&pinst->lock);
+       get_online_cpus();
++      mutex_lock(&pinst->lock);
+       switch (cpumask_type) {
+       case PADATA_CPU_PARALLEL:
+@@ -633,8 +633,8 @@ int padata_set_cpumask(struct padata_ins
+       err =  __padata_set_cpumasks(pinst, parallel_mask, serial_mask);
+ out:
+-      put_online_cpus();
+       mutex_unlock(&pinst->lock);
++      put_online_cpus();
+       return err;
+ }
diff --git a/queue-4.9/perf-hists-browser-restore-esc-as-zoom-out-of-dso-thread-etc.patch b/queue-4.9/perf-hists-browser-restore-esc-as-zoom-out-of-dso-thread-etc.patch
new file mode 100644 (file)
index 0000000..df3599e
--- /dev/null
@@ -0,0 +1,35 @@
+From 3f7774033e6820d25beee5cf7aefa11d4968b951 Mon Sep 17 00:00:00 2001
+From: Arnaldo Carvalho de Melo <acme@redhat.com>
+Date: Mon, 16 Dec 2019 13:22:33 -0300
+Subject: perf hists browser: Restore ESC as "Zoom out" of DSO/thread/etc
+
+From: Arnaldo Carvalho de Melo <acme@redhat.com>
+
+commit 3f7774033e6820d25beee5cf7aefa11d4968b951 upstream.
+
+We need to set actions->ms.map since 599a2f38a989 ("perf hists browser:
+Check sort keys before hot key actions"), as in that patch we bail out
+if map is NULL.
+
+Reviewed-by: Jiri Olsa <jolsa@kernel.org>
+Cc: Adrian Hunter <adrian.hunter@intel.com>
+Cc: Namhyung Kim <namhyung@kernel.org>
+Fixes: 599a2f38a989 ("perf hists browser: Check sort keys before hot key actions")
+Link: https://lkml.kernel.org/n/tip-wp1ssoewy6zihwwexqpohv0j@git.kernel.org
+Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ tools/perf/ui/browsers/hists.c |    1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/tools/perf/ui/browsers/hists.c
++++ b/tools/perf/ui/browsers/hists.c
+@@ -2930,6 +2930,7 @@ static int perf_evsel__hists_browse(stru
+                               continue;
+                       }
++                      actions->ms.map = map;
+                       top = pstack__peek(browser->pstack);
+                       if (top == &browser->hists->dso_filter) {
+                               /*
index 6c7b664e8c79b7f01f6267597ddd72f9a95a7512..b1310e9e94a9ab866ba6c774b7e8ed290d045f38 100644 (file)
@@ -44,3 +44,7 @@ namei-only-return-echild-from-follow_dotdot_rcu.patch
 kvm-check-for-a-bad-hva-before-dropping-into-the-ghc-slow-path.patch
 slip-stop-double-free-sl-dev-in-slip_open.patch
 tuntap-correctly-set-sockwq_async_nospace.patch
+drivers-net-xgene-fix-the-order-of-the-arguments-of-alloc_etherdev_mqs.patch
+perf-hists-browser-restore-esc-as-zoom-out-of-dso-thread-etc.patch
+padata-always-acquire-cpu_hotplug_lock-before-pinst-lock.patch
+mm-huge_memory.c-use-head-to-check-huge-zero-page.patch