diff options
author | Martin Schwidefsky <schwidefsky@de.ibm.com> | 2015-04-16 15:47:33 +0300 |
---|---|---|
committer | Martin Schwidefsky <schwidefsky@de.ibm.com> | 2015-04-23 17:52:01 +0300 |
commit | 7e01b5acd88b3f3108d8c4ce44e3205d67437202 (patch) | |
tree | 8278dc40fdf14dedb0b89435a659de3fd413faec /include/linux | |
parent | 27cf3a16b2535a490f8cf1d29a6634f1c70f7831 (diff) | |
download | linux-7e01b5acd88b3f3108d8c4ce44e3205d67437202.tar.xz |
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 'include/linux')
-rw-r--r-- | include/linux/kexec.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/linux/kexec.h b/include/linux/kexec.h index e60a745ac198..e804306ef5e8 100644 --- a/include/linux/kexec.h +++ b/include/linux/kexec.h @@ -40,6 +40,10 @@ #error KEXEC_CONTROL_MEMORY_LIMIT not defined #endif +#ifndef KEXEC_CONTROL_MEMORY_GFP +#define KEXEC_CONTROL_MEMORY_GFP GFP_KERNEL +#endif + #ifndef KEXEC_CONTROL_PAGE_SIZE #error KEXEC_CONTROL_PAGE_SIZE not defined #endif |