summaryrefslogtreecommitdiff
path: root/kexec/arch/ia64/crashdump-ia64.c
diff options
context:
space:
mode:
authorMagnus Damm <magnus@valinux.co.jp>2007-02-15 22:42:35 +0900
committerSimon Horman <horms@verge.net.au>2007-03-07 14:54:10 +0900
commitbcd72df212636eee645276a2409b0eef8c250dee (patch)
treef1ebe4805d30348295247ba7ba5e3afc3dac9f43 /kexec/arch/ia64/crashdump-ia64.c
parent56595256907a3b31d2849dfe185d0d16b2ead471 (diff)
kexec-tools: Use EFI_LOADER_DATA for ELF core header (ia64)
The address where the ELF core header is stored is passed to the secondary kernel as a kernel command line option. The memory area for this header is also marked as a separate EFI memory descriptor on ia64. The separate EFI memory descriptor is at the moment of the type EFI_UNUSABLE_MEMORY. With such a type the secondary kernel skips over the entire memory granule (config option, 16M or 64M) when detecting memory. If we are lucky we will just lose some memory, but if we happen to have data in the same granule (such as an initramfs image), then this data will never get mapped and the kernel bombs out when trying to access it. So this is an attempt to fix this by changing the EFI memory descriptor type into EFI_LOADER_DATA. This type is the same type used for the kernel data and for initramfs. In the secondary kernel we then handle the ELF core header data the same way as we handle the initramfs image. This strategy requires changes in the secondary kernel as well, I'll post the kernel patches in a little while. Signed-off-by: Magnus Damm <magnus@valinux.co.jp> Signed-off-by: Simon Horman <horms@verge.net.au>
Diffstat (limited to 'kexec/arch/ia64/crashdump-ia64.c')
-rw-r--r--kexec/arch/ia64/crashdump-ia64.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/kexec/arch/ia64/crashdump-ia64.c b/kexec/arch/ia64/crashdump-ia64.c
index 35f7a72..31e5a8c 100644
--- a/kexec/arch/ia64/crashdump-ia64.c
+++ b/kexec/arch/ia64/crashdump-ia64.c
@@ -55,7 +55,6 @@ static unsigned long kernel_code_end;
struct loaded_segment {
unsigned long start;
unsigned long end;
- unsigned long reserved;
};
#define MAX_LOAD_SEGMENTS 128
@@ -90,7 +89,6 @@ static void add_loaded_segments_info(struct kexec_info *info,
start&~(ELF_PAGE_SIZE-1);
loaded_segments[loaded_segments_num].end =
(end + ELF_PAGE_SIZE - 1)&~(ELF_PAGE_SIZE - 1);
- loaded_segments[loaded_segments_num].reserved = 0;
loaded_segments_num++;
}
}
@@ -243,7 +241,6 @@ int load_crashdump_segments(struct kexec_info *info, struct mem_ehdr *ehdr,
loaded_segments[loaded_segments_num].start = elfcorehdr;
loaded_segments[loaded_segments_num].end = elfcorehdr +
sz;
- loaded_segments[loaded_segments_num].reserved = 1;
loaded_segments_num++;
cmdline_add_elfcorehdr(cmdline, elfcorehdr);
}