public inbox for linux-ia64@vger.kernel.org
 help / color / mirror / Atom feed
* Re: [Fastboot] Zero size /proc/vmcore on ia64
@ 2007-02-12 18:57 Bernhard Walle
  2007-02-12 21:49 ` Bernhard Walle
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: Bernhard Walle @ 2007-02-12 18:57 UTC (permalink / raw)
  To: linux-ia64

* Zou, Nanhai <nanhai.zou@intel.com> [2007-02-09 00:45]:
>  I have not implement serial print in purgatory code yet, see
>  comments in purgatory/arch/ia64/console-ia64.c However from your
>  print, I can see last 2 entries of efi mem map are corrupt. 

I have the same problem (corrupted memory map entries), and the cause
was in kexec-tools, patch below. I'm not sure if the fix is right, at
least the problem is the uninitialised value of size. :)

Signed-off-by: Bernhard Walle <bwalle@suse.de>

---
 crashdump-ia64.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/kexec/arch/ia64/crashdump-ia64.c b/kexec/arch/ia64/crashdump-ia64.c
index 14e95a6..be61dc1 100644
--- a/kexec/arch/ia64/crashdump-ia64.c
+++ b/kexec/arch/ia64/crashdump-ia64.c
@@ -221,7 +221,7 @@ int load_crashdump_segments(struct kexec_info *info, struct mem_ehdr *ehdr,
 	struct memory_range *mem_range;
 	int nr_ranges;
 	unsigned long sz;
-	size_t size;
+	size_t size = 0;
 	void *tmp;
 	if (info->kexec_flags & KEXEC_ON_CRASH ) {
 		if (get_crash_memory_ranges(&mem_range, &nr_ranges) = 0) {
@@ -238,7 +238,7 @@ int load_crashdump_segments(struct kexec_info *info, struct mem_ehdr *ehdr,
 			elfcorehdr = add_buffer(info, tmp, sz, sz, EFI_PAGE_SIZE, min_base,
 					max_addr, -1);
 			loaded_segments[loaded_segments_num].start = elfcorehdr;
-			loaded_segments[loaded_segments_num].end = elfcorehdr + size;
+			loaded_segments[loaded_segments_num].end = elfcorehdr + sz;
 			loaded_segments[loaded_segments_num].reserved = 1;
 			loaded_segments_num++;
 			cmdline_add_elfcorehdr(cmdline, elfcorehdr);

^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2007-02-15  2:28 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-02-12 18:57 [Fastboot] Zero size /proc/vmcore on ia64 Bernhard Walle
2007-02-12 21:49 ` Bernhard Walle
2007-02-13  1:08 ` Zou, Nanhai
2007-02-14  1:38 ` Horms
2007-02-14 19:59 ` Bernhard Walle
2007-02-15  2:15 ` Magnus Damm
2007-02-15  2:28 ` Horms

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox