kexec-tools: s390: Do not create ELF header by default

For s390 we have two modes for kdump:

For the first mode, as on all other architectures, the kexec tool creates
the ELF header and the 2nd kernel processes it for /proc/vmcore setup.

This mode has the disadvantage that for memory and CPU hotplug the kdump
kernel has to be reloaded by the kexec tool. For s390 this is a real problem
because we have a cpuplugd daemon that sets CPUs online and offline
according to the current workload. So CPU online/offline events occur very
often.

For the second mode on s390, the ELF header is created by the kdump kernel.
This is done automatically when the kernel is booted in kdump mode
and no "elfcorehdr" kernel parameter is specified. On s390 the kdump kernel
can get all necessary information to build the ELF header. We can get
the memory map, all CPU registers, and vmcoreinfo

With this patch a compile switch WITH_ELF_HEADER is introduced. When the
macro is defined, kexec will create the ELF header and add the "elfcorehdr"
kernel parameter. If it is not specified (default), no header is created.

For s390 we want to have the 2nd mode as default because it has only
advantages for us.

Signed-off-by: Michael Holzheu <holzheu@linux.vnet.ibm.com>
Signed-off-by: Simon Horman <horms@verge.net.au>
1 file changed