diff options
author | Baoquan He <bhe@redhat.com> | 2017-03-03 11:52:15 +0800 |
---|---|---|
committer | Simon Horman <horms@verge.net.au> | 2017-03-10 10:13:29 +0100 |
commit | 263e45ccf27b21e9862cc538ed28978533d04e4b (patch) | |
tree | 0af7115860af4e7d7d5d81d62364e0cfd844fa8c | |
parent | 7dac152d5b47f5e505994026cbfec30dee1a0941 (diff) |
Only print debug message when failed to serach for kernel symbol from /proc/kallsyms
Kernel symbol page_offset_base could be unavailable when mm KASLR code is
not compiled in kernel. It's inappropriate to print out error message
when failed to search for page_offset_base from /proc/kallsyms. Seems now
there is not a way to find out if mm KASLR is compiled in or not. An
alternative approach is only printing out debug message in get_kernel_sym
if failed to search a expected kernel symbol.
Do it in this patch, a simple fix.
Signed-off-by: Baoquan He <bhe@redhat.com>
Reviewed-by: Pratyush Anand <panand@redhat.com>
Acked-by: Dave Young <dyoung@redhat.com>
Signed-off-by: Simon Horman <horms@verge.net.au>
-rw-r--r-- | kexec/arch/i386/crashdump-x86.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/kexec/arch/i386/crashdump-x86.c b/kexec/arch/i386/crashdump-x86.c index 88aeee3..c4cf201 100644 --- a/kexec/arch/i386/crashdump-x86.c +++ b/kexec/arch/i386/crashdump-x86.c @@ -127,7 +127,7 @@ static unsigned long long get_kernel_sym(const char *symbol) } } - fprintf(stderr, "Cannot get kernel %s symbol address\n", symbol); + dbgprintf("Cannot get kernel %s symbol address\n", symbol); return 0; } |