summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEric DeVolder <eric.devolder@oracle.com>2023-09-27 14:11:35 -0400
committerSimon Horman <horms@kernel.org>2023-10-04 14:04:41 +0200
commitd59d17f372398d270f9d0f1aaf37f5ad1c4a601d (patch)
tree864958aef173b6e9ab2a8fed5a5d05b3f49b8560
parenta56376080a9378a40a85cef455f7455a48d171ce (diff)
downloadkexec-tools-d59d17f372398d270f9d0f1aaf37f5ad1c4a601d.tar.gz
crashdump/x86: identify elfcorehdr segment for hotplug
Identify the segment containing the elfcorehdr buffer so that it can be excluded from the purgatory checksum/digest, if hotplug support is in effect. Signed-off-by: Eric DeVolder <eric.devolder@oracle.com> Signed-off-by: Simon Horman <horms@kernel.org>
-rw-r--r--kexec/arch/i386/crashdump-x86.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/kexec/arch/i386/crashdump-x86.c b/kexec/arch/i386/crashdump-x86.c
index df1f24cb..cb86ca71 100644
--- a/kexec/arch/i386/crashdump-x86.c
+++ b/kexec/arch/i386/crashdump-x86.c
@@ -956,6 +956,9 @@ int load_crashdump_segments(struct kexec_info *info, char* mod_cmdline,
} else {
memsz = bufsz;
}
+
+ /* Record the location of the elfcorehdr for hotplug handling */
+ info->elfcorehdr =
elfcorehdr = add_buffer(info, tmp, bufsz, memsz, align, min_base,
max_addr, -1);
dbgprintf("Created elf header segment at 0x%lx\n", elfcorehdr);