This patch adds core dump file support to ELF file loader. This can be
used by kexec based hibernation to load hibernated image, which is
from /proc/vmcore, a core dump file.

Signed-off-by: Huang Ying <[EMAIL PROTECTED]>

---
 kexec/kexec-elf-exec.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

--- a/kexec/kexec-elf-exec.c
+++ b/kexec/kexec-elf-exec.c
@@ -20,7 +20,8 @@ int build_elf_exec_info(const char *buf,
        if (result < 0) {
                return result;
        }
-       if ((ehdr->e_type != ET_EXEC) && (ehdr->e_type != ET_DYN)) {
+       if ((ehdr->e_type != ET_EXEC) && (ehdr->e_type != ET_DYN) &&
+           (ehdr->e_type != ET_CORE)) {
                /* not an ELF executable */
                if (probe_debug) {
                        fprintf(stderr, "Not ELF type ET_EXEC or ET_DYN\n");

Attachment: signature.asc
Description: This is a digitally signed message part

_______________________________________________
kexec mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/kexec

Reply via email to