summaryrefslogtreecommitdiffstats
path: root/0004-powerpc-64s-hash-Fix-fork-with-512TB-process-address.patch
diff options
context:
space:
mode:
Diffstat (limited to '0004-powerpc-64s-hash-Fix-fork-with-512TB-process-address.patch')
-rw-r--r--0004-powerpc-64s-hash-Fix-fork-with-512TB-process-address.patch48
1 files changed, 0 insertions, 48 deletions
diff --git a/0004-powerpc-64s-hash-Fix-fork-with-512TB-process-address.patch b/0004-powerpc-64s-hash-Fix-fork-with-512TB-process-address.patch
deleted file mode 100644
index 75d9d3241..000000000
--- a/0004-powerpc-64s-hash-Fix-fork-with-512TB-process-address.patch
+++ /dev/null
@@ -1,48 +0,0 @@
-From fe50aa4374f20333d9b077bbe09397d38112b081 Mon Sep 17 00:00:00 2001
-From: Nicholas Piggin <npiggin@gmail.com>
-Date: Tue, 28 Nov 2017 11:26:57 +0100
-Subject: [PATCH 4/5] powerpc/64s/hash: Fix fork() with 512TB process address
- space
-
-commit effc1b25088502fbd30305c79773de2d1f7470a6 upstream.
-
-Hash unconditionally resets the addr_limit to default (128TB) when the
-mm context is initialised. If a process has > 128TB mappings when it
-forks, the child will not get the 512TB addr_limit, so accesses to
-valid > 128TB mappings will fail in the child.
-
-Fix this by only resetting the addr_limit to default if it was 0. Non
-zero indicates it was duplicated from the parent (0 means exec()).
-
-Fixes: f4ea6dcb08ea ("powerpc/mm: Enable mappings above 128TB")
-Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
-Reviewed-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
-Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
----
- arch/powerpc/mm/mmu_context_book3s64.c | 8 ++++----
- 1 file changed, 4 insertions(+), 4 deletions(-)
-
-diff --git a/arch/powerpc/mm/mmu_context_book3s64.c b/arch/powerpc/mm/mmu_context_book3s64.c
-index a75f63833284..bb9cdf01fc4f 100644
---- a/arch/powerpc/mm/mmu_context_book3s64.c
-+++ b/arch/powerpc/mm/mmu_context_book3s64.c
-@@ -95,11 +95,11 @@ static int hash__init_new_context(struct mm_struct *mm)
- return index;
-
- /*
-- * We do switch_slb() early in fork, even before we setup the
-- * mm->context.addr_limit. Default to max task size so that we copy the
-- * default values to paca which will help us to handle slb miss early.
-+ * In the case of exec, use the default limit,
-+ * otherwise inherit it from the mm we are duplicating.
- */
-- mm->context.addr_limit = DEFAULT_MAP_WINDOW_USER64;
-+ if (!mm->context.addr_limit)
-+ mm->context.addr_limit = DEFAULT_MAP_WINDOW_USER64;
-
- /*
- * The old code would re-promote on fork, we don't do that when using
---
-2.14.3
-