soc/intel/braswell: add vmx support via CPU_INTEL_COMMON

Braswell allready supported vmx, but offered no mechanism to unset it, nor
to set the lock bit required for Windows to recognize virtualization.
Enable this functionality by adding CPU_INTEL_COMMON config.

Test: build/boot Windows 10 on Braswell ChromeOS device, verify Windows shows
virtualization as enabled.

Change-Id: I0d39abaeb9eebcceb37dc791df6b06e521fe1992
Signed-off-by: Matt DeVillier <matt.devillier@gmail.com>
Reviewed-on: https://review.coreboot.org/29570
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
This commit is contained in:
Matt DeVillier 2018-11-10 17:44:36 -06:00 committed by Patrick Georgi
parent f765d4f275
commit d3d0f07fd5
3 changed files with 6 additions and 0 deletions

View File

@ -47,6 +47,7 @@ config CPU_SPECIFIC_OPTIONS
select GENERIC_GPIO_LIB select GENERIC_GPIO_LIB
select INTEL_GMA_ACPI select INTEL_GMA_ACPI
select INTEL_GMA_SWSMISCI select INTEL_GMA_SWSMISCI
select CPU_INTEL_COMMON
config VBOOT config VBOOT
select VBOOT_STARTS_IN_ROMSTAGE select VBOOT_STARTS_IN_ROMSTAGE

View File

@ -7,6 +7,7 @@ subdirs-y += ../../../cpu/x86/smm
subdirs-y += ../../../cpu/x86/tsc subdirs-y += ../../../cpu/x86/tsc
subdirs-y += ../../../cpu/intel/microcode subdirs-y += ../../../cpu/intel/microcode
subdirs-y += ../../../cpu/intel/turbo subdirs-y += ../../../cpu/intel/turbo
subdirs-y += ../../../cpu/intel/common
romstage-y += gpio_support.c romstage-y += gpio_support.c
romstage-y += iosf.c romstage-y += iosf.c

View File

@ -16,6 +16,7 @@
#include <console/console.h> #include <console/console.h>
#include <cpu/cpu.h> #include <cpu/cpu.h>
#include <cpu/intel/common/common.h>
#include <cpu/intel/microcode.h> #include <cpu/intel/microcode.h>
#include <cpu/intel/turbo.h> #include <cpu/intel/turbo.h>
#include <cpu/x86/cache.h> #include <cpu/x86/cache.h>
@ -60,6 +61,9 @@ static void soc_core_init(struct device *cpu)
if (lapicid()) if (lapicid())
enable_turbo(); enable_turbo();
/* Set virtualization based on Kconfig option */
set_vmx();
/* Set core MSRs */ /* Set core MSRs */
reg_script_run(core_msr_script); reg_script_run(core_msr_script);