Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

x86/platform: Control warm reset setup via legacy feature flag

Allow to turn off the setup of BIOS-managed warm reset via a new flag in
x86_legacy_features. Besides the UV1, the upcoming jailhose guest support
needs this switched off.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Cc: jailhouse-dev@googlegroups.com
Link: https://lkml.kernel.org/r/44376558129d70a2c1527959811371ef4b82e829.1511770314.git.jan.kiszka@siemens.com

authored by

Jan Kiszka and committed by
Thomas Gleixner
e348caef 32c9c801

+5 -2
+1
arch/x86/include/asm/x86_init.h
··· 212 212 struct x86_legacy_features { 213 213 enum x86_legacy_i8042_state i8042; 214 214 int rtc; 215 + int warm_reset; 215 216 int no_vga; 216 217 int reserve_bios_regions; 217 218 struct x86_legacy_devices devices;
+1
arch/x86/kernel/apic/x2apic_uv_x.c
··· 316 316 } else if (!strcmp(oem_table_id, "UVH")) { 317 317 /* Only UV1 systems: */ 318 318 uv_system_type = UV_NON_UNIQUE_APIC; 319 + x86_platform.legacy.warm_reset = 0; 319 320 __this_cpu_write(x2apic_extra_bits, pnodeid << uvh_apicid.s.pnode_shift); 320 321 uv_set_apicid_hibit(); 321 322 uv_apic = 1;
+1
arch/x86/kernel/platform-quirks.c
··· 9 9 { 10 10 x86_platform.legacy.i8042 = X86_LEGACY_I8042_EXPECTED_PRESENT; 11 11 x86_platform.legacy.rtc = 1; 12 + x86_platform.legacy.warm_reset = 1; 12 13 x86_platform.legacy.reserve_bios_regions = 0; 13 14 x86_platform.legacy.devices.pnpbios = 1; 14 15
+2 -2
arch/x86/kernel/smpboot.c
··· 934 934 * the targeted processor. 935 935 */ 936 936 937 - if (get_uv_system_type() != UV_NON_UNIQUE_APIC) { 937 + if (x86_platform.legacy.warm_reset) { 938 938 939 939 pr_debug("Setting warm reset code and vector.\n"); 940 940 ··· 1006 1006 /* mark "stuck" area as not stuck */ 1007 1007 *trampoline_status = 0; 1008 1008 1009 - if (get_uv_system_type() != UV_NON_UNIQUE_APIC) { 1009 + if (x86_platform.legacy.warm_reset) { 1010 1010 /* 1011 1011 * Cleanup possible dangling ends... 1012 1012 */