aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/kexec.h
diff options
context:
space:
mode:
authorAmerigo Wang <amwang@redhat.com>2009-12-15 19:47:46 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2009-12-16 10:20:13 -0500
commit06a7f711246b081afc21fff859f1003f1f2a0fbc (patch)
treeaece49693ad751923ce71387201d3c3e6214e335 /include/linux/kexec.h
parent1f2c19f8c959c1d0ccd3e33b1f480593b66d95dd (diff)
kexec: premit reduction of the reserved memory size
Implement shrinking the reserved memory for crash kernel, if it is more than enough. For example, if you have already reserved 128M, now you just want 100M, you can do: # echo $((100*1024*1024)) > /sys/kernel/kexec_crash_size Note, you can only do this before loading the crash kernel. Signed-off-by: WANG Cong <amwang@redhat.com> Cc: Neil Horman <nhorman@redhat.com> Acked-by: Eric W. Biederman <ebiederm@xmission.com> Cc: Andi Kleen <andi@firstfloor.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux/kexec.h')
-rw-r--r--include/linux/kexec.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/kexec.h b/include/linux/kexec.h
index adc34f2c6eff..c356b6914ffd 100644
--- a/include/linux/kexec.h
+++ b/include/linux/kexec.h
@@ -206,6 +206,8 @@ extern size_t vmcoreinfo_max_size;
206 206
207int __init parse_crashkernel(char *cmdline, unsigned long long system_ram, 207int __init parse_crashkernel(char *cmdline, unsigned long long system_ram,
208 unsigned long long *crash_size, unsigned long long *crash_base); 208 unsigned long long *crash_size, unsigned long long *crash_base);
209int crash_shrink_memory(unsigned long new_size);
210size_t crash_get_memory_size(void);
209 211
210#else /* !CONFIG_KEXEC */ 212#else /* !CONFIG_KEXEC */
211struct pt_regs; 213struct pt_regs;