lkml.org 
[lkml]   [2014]   [Jan]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[PATCH v2] x86, kaslr: export offset in VMCOREINFO ELF notes
From: Eugene Surovegin <surovegin@google.com>

Include kASLR offset in VMCOREINFO ELF notes to assist in debugging.

Signed-off-by: Eugene Surovegin <surovegin@google.com>
Signed-off-by: Kees Cook <keescook@chromium.org>
---
v2:
- make sure "From:" got sent correctly
---
arch/x86/kernel/machine_kexec_64.c | 2 ++
1 file changed, 2 insertions(+)

diff --git a/arch/x86/kernel/machine_kexec_64.c b/arch/x86/kernel/machine_kexec_64.c
index 4eabc160696f..679cef0791cd 100644
--- a/arch/x86/kernel/machine_kexec_64.c
+++ b/arch/x86/kernel/machine_kexec_64.c
@@ -279,5 +279,7 @@ void arch_crash_save_vmcoreinfo(void)
VMCOREINFO_SYMBOL(node_data);
VMCOREINFO_LENGTH(node_data, MAX_NUMNODES);
#endif
+ vmcoreinfo_append_str("KERNELOFFSET=%lx\n",
+ (unsigned long)&_text - __START_KERNEL);
}

--
1.7.9.5

--
Kees Cook
Chrome OS Security


\
 
 \ /
  Last update: 2014-01-23 19:01    [W:0.071 / U:0.208 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site