tmp_suning_uos_patched/arch/x86/boot
Baoquan He f2d08c5d3b x86/boot: Add xloadflags bits to check for 5-level paging support
The current kernel supports 5-level paging mode, and supports dynamically
choosing the paging mode during bootup depending on the kernel image,
hardware and kernel parameter settings. This flexibility brings several
issues to kexec/kdump:

1) Dynamic switching between paging modes requires support in the target
   kernel. This means kexec from a 5-level paging kernel into a kernel
   which does not support mode switching is not possible. So the loader
   needs to be able to analyze the supported paging modes of the kexec
   target kernel.

2) If running on a 5-level paging kernel and the kexec target kernel is a
   4-level paging kernel, the target immage cannot be loaded above the 64TB
   address space limit. But the kexec loader searches for a load area from
   top to bottom which would eventually put the target kernel above 64TB
   when the machine has large enough RAM size. So the loader needs to be
   able to analyze the paging mode of the target kernel to load it at a
   suitable spot in the address space.

Solution:

Add two bits XLF_5LEVEL and XLF_5LEVEL_ENABLED:

 - Bit XLF_5LEVEL indicates whether 5-level paging mode switching support
   is available. (Issue #1)

 - Bit XLF_5LEVEL_ENABLED indicates whether the kernel was compiled with
   full 5-level paging support (CONFIG_X86_5LEVEL=y). (Issue #2)

The loader will use these bits to verify whether the target kernel is
suitable to be kexec'ed to from a 5-level paging kernel and to determine
the constraints of the target kernel load address.

The flags will be used by the kernel kexec subsystem and the userspace
kexec tools.

[ tglx: Massaged changelog ]

Signed-off-by: Baoquan He <bhe@redhat.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Acked-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>
Cc: bp@alien8.de
Cc: hpa@zytor.com
Cc: dyoung@redhat.com
Link: https://lkml.kernel.org/r/20190524073810.24298-2-bhe@redhat.com
2019-06-28 07:14:59 +02:00
..
compressed x86/boot: Make the GDT 8-byte aligned 2019-06-27 10:56:11 +02:00
tools x86/boot: Add missing va_end() to die() 2018-11-28 20:06:07 +01:00
.gitignore x86/build: Add more generated files to the .gitignore file 2017-11-07 11:22:21 +01:00
a20.c
apm.c
bioscall.S treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 83 2019-05-24 17:37:52 +02:00
bitops.h x86/boot: Use CC_SET()/CC_OUT() instead of open coding it 2018-08-02 14:30:42 +02:00
boot.h x86/boot: Simplify the detect_memory*() control flow 2018-11-06 21:05:01 +01:00
cmdline.c
code16gcc.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
copy.S x86/boot: Remove unused copy_*_gs() functions 2017-06-05 09:35:16 +02:00
cpu.c Revert "x86/boot: Fail the boot if !M486 and CPUID is missing" 2016-12-19 11:54:20 +01:00
cpucheck.c x86: Clean up 'sizeof x' => 'sizeof(x)' 2018-10-29 07:13:28 +01:00
cpuflags.c License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
cpuflags.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
ctype.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
early_serial_console.c x86: Clean up 'sizeof x' => 'sizeof(x)' 2018-10-29 07:13:28 +01:00
edd.c x86: Clean up 'sizeof x' => 'sizeof(x)' 2018-10-29 07:13:28 +01:00
genimage.sh x86/build: Make isoimage work on Debian 2017-12-16 16:23:31 +01:00
header.S x86/boot: Add xloadflags bits to check for 5-level paging support 2019-06-28 07:14:59 +02:00
install.sh
main.c x86: Clean up 'sizeof x' => 'sizeof(x)' 2018-10-29 07:13:28 +01:00
Makefile x86/build: Specify elf_i386 linker emulation explicitly for i386 objects 2019-01-12 00:11:39 +01:00
memory.c x86/boot: Simplify the detect_memory*() control flow 2018-11-06 21:05:01 +01:00
mkcpustr.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 83 2019-05-24 17:37:52 +02:00
mtools.conf.in
pm.c
pmjump.S
printf.c x86/boot: Fix a sanity check in printf.c 2013-08-14 11:48:41 +02:00
regs.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 83 2019-05-24 17:37:52 +02:00
setup.ld x86/build: Use the single-argument OUTPUT_FORMAT() linker script command 2019-01-16 12:21:53 +01:00
string.c x86/boot: Restrict header scope to make Clang happy 2019-03-21 12:24:38 +01:00
string.h x86/boot: Copy kstrtoull() to boot/string.c 2019-02-01 11:52:54 +01:00
tty.c
version.c
vesa.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 48 2019-05-24 17:27:13 +02:00
video-bios.c
video-mode.c x86/mm: Fix regression with huge pages on PAE 2015-12-04 09:14:27 +01:00
video-vesa.c x86: Clean up 'sizeof x' => 'sizeof(x)' 2018-10-29 07:13:28 +01:00
video-vga.c x86: Use ARRAY_SIZE 2017-10-19 16:15:47 +02:00
video.c x86: Clean up 'sizeof x' => 'sizeof(x)' 2018-10-29 07:13:28 +01:00
video.h x86/boot/video: Move the 'video_segment' variable to video.c 2015-02-19 00:25:05 +01:00