summaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorMartin Schwidefsky <schwidefsky@de.ibm.com>2015-04-16 14:47:33 +0200
committerMartin Schwidefsky <schwidefsky@de.ibm.com>2015-04-23 16:52:01 +0200
commit7e01b5acd88b3f3108d8c4ce44e3205d67437202 (patch)
tree8278dc40fdf14dedb0b89435a659de3fd413faec /arch
parent27cf3a16b2535a490f8cf1d29a6634f1c70f7831 (diff)
downloadlinux-stable-7e01b5acd88b3f3108d8c4ce44e3205d67437202.tar.gz
linux-stable-7e01b5acd88b3f3108d8c4ce44e3205d67437202.tar.bz2
linux-stable-7e01b5acd88b3f3108d8c4ce44e3205d67437202.zip
kexec: allocate the kexec control page with KEXEC_CONTROL_MEMORY_GFP
Introduce KEXEC_CONTROL_MEMORY_GFP to allow the architecture code to override the gfp flags of the allocation for the kexec control page. The loop in kimage_alloc_normal_control_pages allocates pages with GFP_KERNEL until a page is found that happens to have an address smaller than the KEXEC_CONTROL_MEMORY_LIMIT. On systems with a large memory size but a small KEXEC_CONTROL_MEMORY_LIMIT the loop will keep allocating memory until the oom killer steps in. Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Diffstat (limited to 'arch')
-rw-r--r--arch/s390/include/asm/kexec.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/arch/s390/include/asm/kexec.h b/arch/s390/include/asm/kexec.h
index 694bcd6bd927..2f924bc30e35 100644
--- a/arch/s390/include/asm/kexec.h
+++ b/arch/s390/include/asm/kexec.h
@@ -26,6 +26,9 @@
/* Not more than 2GB */
#define KEXEC_CONTROL_MEMORY_LIMIT (1UL<<31)
+/* Allocate control page with GFP_DMA */
+#define KEXEC_CONTROL_MEMORY_GFP GFP_DMA
+
/* Maximum address we can use for the crash control pages */
#define KEXEC_CRASH_CONTROL_MEMORY_LIMIT (-1UL)