]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
4.14-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 4 Sep 2018 17:22:45 +0000 (19:22 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 4 Sep 2018 17:22:45 +0000 (19:22 +0200)
added patches:
mm-move-tlb_table_flush-to-tlb_flush_mmu_free.patch

queue-4.14/mm-move-tlb_table_flush-to-tlb_flush_mmu_free.patch [new file with mode: 0644]
queue-4.14/series

diff --git a/queue-4.14/mm-move-tlb_table_flush-to-tlb_flush_mmu_free.patch b/queue-4.14/mm-move-tlb_table_flush-to-tlb_flush_mmu_free.patch
new file mode 100644 (file)
index 0000000..262e47a
--- /dev/null
@@ -0,0 +1,49 @@
+From db7ddef301128dad394f1c0f77027f86ee9a4edb Mon Sep 17 00:00:00 2001
+From: Nicholas Piggin <npiggin@gmail.com>
+Date: Thu, 23 Aug 2018 18:47:08 +1000
+Subject: mm: move tlb_table_flush to tlb_flush_mmu_free
+
+From: Nicholas Piggin <npiggin@gmail.com>
+
+commit db7ddef301128dad394f1c0f77027f86ee9a4edb upstream.
+
+There is no need to call this from tlb_flush_mmu_tlbonly, it logically
+belongs with tlb_flush_mmu_free.  This makes future fixes simpler.
+
+[ This was originally done to allow code consolidation for the
+  mmu_notifier fix, but it also ends up helping simplify the
+  HAVE_RCU_TABLE_INVALIDATE fix.    - Linus ]
+
+Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
+Acked-by: Will Deacon <will.deacon@arm.com>
+Cc: Peter Zijlstra <peterz@infradead.org>
+Cc: stable@kernel.org
+Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ mm/memory.c |    6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+--- a/mm/memory.c
++++ b/mm/memory.c
+@@ -246,9 +246,6 @@ static void tlb_flush_mmu_tlbonly(struct
+       tlb_flush(tlb);
+       mmu_notifier_invalidate_range(tlb->mm, tlb->start, tlb->end);
+-#ifdef CONFIG_HAVE_RCU_TABLE_FREE
+-      tlb_table_flush(tlb);
+-#endif
+       __tlb_reset_range(tlb);
+ }
+@@ -256,6 +253,9 @@ static void tlb_flush_mmu_free(struct mm
+ {
+       struct mmu_gather_batch *batch;
++#ifdef CONFIG_HAVE_RCU_TABLE_FREE
++      tlb_table_flush(tlb);
++#endif
+       for (batch = &tlb->local; batch && batch->nr; batch = batch->next) {
+               free_pages_and_swap_cache(batch->pages, batch->nr);
+               batch->nr = 0;
index 89745e470f138c7d6bf5aa58eaedc29ee838a9b2..7d2d168e95a5c62f112a9140ea9068a23a4c1079 100644 (file)
@@ -163,3 +163,4 @@ watchdog-mark-watchdog-touch-functions-as-notrace.patch
 cdrom-fix-info-leak-oob-read-in-cdrom_ioctl_drive_status.patch
 gcc-plugins-add-include-required-by-gcc-release-8.patch
 gcc-plugins-use-dynamic-initializers.patch
+mm-move-tlb_table_flush-to-tlb_flush_mmu_free.patch