Home Home > GIT Browse
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichal Hocko <mhocko@suse.com>2018-04-06 21:31:05 +0200
committerMichal Hocko <mhocko@suse.com>2018-04-06 21:31:05 +0200
commitc26fcc3074ee76b520fb40bab89d0144c51b5582 (patch)
tree9c6c80cb008895f000382f1d2724a6b14f7f6fc7
parent621f10073675b877decec9d1327bd2bf895c297b (diff)
parent080516f91a0e2c78d1eea5343d9c223e306ea8df (diff)
Merge branch 'users/mhocko/SLE15/bnc1082184' into users/mhocko/SLE15/for-next
-rw-r--r--patches.fixes/mm-sparse-do-not-swamp-log-with-huge-vmemmap-allocat-fix.patch30
-rw-r--r--series.conf1
2 files changed, 31 insertions, 0 deletions
diff --git a/patches.fixes/mm-sparse-do-not-swamp-log-with-huge-vmemmap-allocat-fix.patch b/patches.fixes/mm-sparse-do-not-swamp-log-with-huge-vmemmap-allocat-fix.patch
new file mode 100644
index 0000000000..4ce510a4dd
--- /dev/null
+++ b/patches.fixes/mm-sparse-do-not-swamp-log-with-huge-vmemmap-allocat-fix.patch
@@ -0,0 +1,30 @@
+From: Michal Hocko <mhocko@suse.com>
+Subject: [PATCH] mm, sparse: do not swamp log with huge vmemmap allocation
+Patch-mainline: never, SLES specific
+References: bnc#1082184, bnc#1087928
+
+When backporting fcdaf842bd8f ("mm, sparse: do not swamp log with huge vmemmap
+allocation failures") I haven't realized that the upstream code is subtly
+different and it stopped zeroying allocated blocks by f7f99100d8d9 ("mm: stop
+zeroing memory during allocation in vmemmap") which we do not have in our
+kernels. Dropping __GFP_ZERO results in not fully initialized vmemmap page
+tables and random crashes when trying to access them. Fix that by adding
+__GFP_ZERO back.
+
+Signed-off-by: Michal Hocko <mhocko@suse.com>
+
+---
+ mm/sparse-vmemmap.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/mm/sparse-vmemmap.c
++++ b/mm/sparse-vmemmap.c
+@@ -52,7 +52,7 @@ void * __meminit vmemmap_alloc_block(uns
+ {
+ /* If the main allocator is up use that, fallback to bootmem. */
+ if (slab_is_available()) {
+- gfp_t gfp_mask = GFP_KERNEL|__GFP_REPEAT |__GFP_NOWARN;
++ gfp_t gfp_mask = GFP_KERNEL|__GFP_REPEAT |__GFP_NOWARN|__GFP_ZERO;
+ int order = get_order(size);
+ static bool warned;
+ struct page *page;
diff --git a/series.conf b/series.conf
index a6a880a236..3f66716fcd 100644
--- a/series.conf
+++ b/series.conf
@@ -7882,6 +7882,7 @@
patches.fixes/mm-page_alloc-fix-potential-false-positive-in-_zone_watermark_ok.patch
patches.fixes/mm-page_alloc.c-broken-deferred-calculation.patch
patches.fixes/mm-sparse-do-not-swamp-log-with-huge-vmemmap-allocat.patch
+ patches.fixes/mm-sparse-do-not-swamp-log-with-huge-vmemmap-allocat-fix.patch
patches.fixes/mm-do-not-rely-on-preempt_count-in-print_vma_addr.patch
patches.fixes/mm-page_ext.c-check-if-page_ext-is-not-prepared.patch
patches.drivers/media-cx231xx-cards-fix-NULL-deref-on-missing-associ