diff options
author | Vivek Goyal <vgoyal@in.ibm.com> | 2005-11-17 19:09:36 +0530 |
---|---|---|
committer | Eric W. Biederman <ebiederm@xmission.com> | 2006-07-27 10:34:40 -0600 |
commit | 4e2f70e3c75f2b81878c34c4f8b3c298ec1b1cd2 (patch) | |
tree | 16d82aa503ca2eaad292f56ab1c34077274dcfac /purgatory | |
parent | 084a640be5c31ce2698ecc5c66c654460f93f53a (diff) | |
download | kexec-tools-4e2f70e3c75f2b81878c34c4f8b3c298ec1b1cd2.tar.gz |
kexec-tools: x86_64 backup first 640k
o This patch adds the support for saving first 640k to the backup
region for x86_64.
Signed-off-by: Murali <muralim@in.ibm.com>
Signed-off-by: Vivek Goyal <vgoyal@in.ibm.com>
Signed-off-by: Maneesh Soni <maneesh@in.ibm.com>
Diffstat (limited to 'purgatory')
-rw-r--r-- | purgatory/arch/i386/crashdump_backup.c | 4 | ||||
-rw-r--r-- | purgatory/arch/x86_64/Makefile | 1 | ||||
-rw-r--r-- | purgatory/arch/x86_64/purgatory-x86_64.c | 3 |
3 files changed, 6 insertions, 2 deletions
diff --git a/purgatory/arch/i386/crashdump_backup.c b/purgatory/arch/i386/crashdump_backup.c index 14e807f..39a1946 100644 --- a/purgatory/arch/i386/crashdump_backup.c +++ b/purgatory/arch/i386/crashdump_backup.c @@ -25,7 +25,9 @@ #define BACKUP_REGION_SIZE 0xa0000 /* Backup region start gets set after /proc/iomem has been parsed. */ -uint32_t backup_start = 0; +/* We reuse the same code for x86_64 also so changing backup_start to + unsigned long */ +unsigned long backup_start = 0; /* Backup first 640K of memory to backup region as reserved by kexec. * Assuming first 640K has to be present on i386 machines and no address diff --git a/purgatory/arch/x86_64/Makefile b/purgatory/arch/x86_64/Makefile index d08edff..29f4340 100644 --- a/purgatory/arch/x86_64/Makefile +++ b/purgatory/arch/x86_64/Makefile @@ -9,6 +9,7 @@ PURGATORY_S_SRCS+= purgatory/arch/x86_64/entry64.S PURGATORY_S_SRCS+= purgatory/arch/x86_64/setup-x86_64.S PURGATORY_S_SRCS+= purgatory/arch/x86_64/stack.S PURGATORY_C_SRCS+= purgatory/arch/x86_64/purgatory-x86_64.c +PURGATORY_C_SRCS+= purgatory/arch/i386/crashdump_backup.c PURGATORY_C_SRCS+= purgatory/arch/i386/console-x86.c PURGATORY_C_SRCS+= purgatory/arch/i386/vga.c PURGATORY_C_SRCS+= purgatory/arch/i386/pic.c diff --git a/purgatory/arch/x86_64/purgatory-x86_64.c b/purgatory/arch/x86_64/purgatory-x86_64.c index 8a2387c..b159ed3 100644 --- a/purgatory/arch/x86_64/purgatory-x86_64.c +++ b/purgatory/arch/x86_64/purgatory-x86_64.c @@ -4,6 +4,7 @@ uint8_t reset_vga = 0; uint8_t legacy_pic = 0; +uint8_t panic_kernel = 0; void setup_arch(void) { @@ -14,5 +15,5 @@ void setup_arch(void) /* This function can be used to execute after the SHA256 verification. */ void post_verification_setup_arch(void) { - /* Nothing for now */ + if (panic_kernel) crashdump_backup_memory(); } |