From aac04b32f3e4c63f461459d0e1d6aa01caac6e66 Mon Sep 17 00:00:00 2001 From: Vivek Goyal Date: Mon, 9 Jan 2006 20:51:47 -0800 Subject: [PATCH] kdump: x86_64: add elfcorehdr command line option - elfcorehdr= specifies the location of elf core header stored by the crashed kernel. This command line option will be passed by the kexec-tools to capture kernel. Changes in this version : - Added more comments in kernel-parameters.txt and in code. Signed-off-by: Murali M Chakravarthy Signed-off-by: Vivek Goyal Cc: Andi Kleen Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- arch/i386/kernel/setup.c | 2 +- arch/x86_64/kernel/setup.c | 9 +++++++++ 2 files changed, 10 insertions(+), 1 deletion(-) (limited to 'arch') diff --git a/arch/i386/kernel/setup.c b/arch/i386/kernel/setup.c index 27c956d..f685637 100644 --- a/arch/i386/kernel/setup.c +++ b/arch/i386/kernel/setup.c @@ -898,7 +898,7 @@ static void __init parse_cmdline_early (char ** cmdline_p) } } #endif -#ifdef CONFIG_CRASH_DUMP +#ifdef CONFIG_PROC_VMCORE /* elfcorehdr= specifies the location of elf core header * stored by the crashed kernel. */ diff --git a/arch/x86_64/kernel/setup.c b/arch/x86_64/kernel/setup.c index ff9620b..a0e0c9c 100644 --- a/arch/x86_64/kernel/setup.c +++ b/arch/x86_64/kernel/setup.c @@ -35,6 +35,7 @@ #include #include #include +#include #include #include #include @@ -418,6 +419,14 @@ static __init void parse_cmdline_early (char ** cmdline_p) } #endif +#ifdef CONFIG_PROC_VMCORE + /* elfcorehdr= specifies the location of elf core header + * stored by the crashed kernel. This option will be passed + * by kexec loader to the capture kernel. + */ + else if(!memcmp(from, "elfcorehdr=", 11)) + elfcorehdr_addr = memparse(from+11, &from); +#endif next_char: c = *(from++); if (!c) -- cgit v1.1