Re: [RFC 02/10] x86/kvm: Add IBPB support

From: Woodhouse, David
Date: Sat Jan 20 2018 - 15:19:34 EST


On Sat, 2018-01-20 at 20:22 +0100, KarimAllah Ahmed wrote:
>
> @@ -6791,6 +6792,9 @@ static __init int hardware_setup(void)
> ÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂkvm_tsc_scaling_ratio_frac_bits = 48;
> ÂÂÂÂÂÂÂÂ}
> Â
> +ÂÂÂÂÂÂÂif (boot_cpu_has(X86_FEATURE_SPEC_CTRL))
> +ÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂvmx_disable_intercept_for_msr(MSR_IA32_PRED_CMD, false);
> +

I've updated that to allow X86_FEATURE_AMD_PRED_CMD too, since some
hypervisors may expose *only* that MSR to guests even on Intel
hardware. PRED_CMD is a lot easier to expose as it doesn't need
storage, live migration support, and all that crap.

Our shared tree at
http://git.infradead.org/linux-retpoline.git/shortlog/refs/heads/ibpb
updated accordingly.

Attachment: smime.p7s
Description: S/MIME cryptographic signature