Re: [Xen-devel] [PATCH 07/10] x86/spec_ctrl: Explicitly set Xen's default MSR_SPEC_CTRL value

2018-05-16 Thread Wei Liu
On Wed, May 16, 2018 at 12:08:02PM +0100, Andrew Cooper wrote: > On 14/05/18 16:52, Jan Beulich wrote: > On 14.05.18 at 17:39, wrote: > >> On Fri, May 11, 2018 at 11:38:11AM +0100, Andrew Cooper wrote: > >>> @@ -417,6 +419,32 @@ void __init init_speculation_mitigations(void) > >>> se

Re: [Xen-devel] [PATCH 07/10] x86/spec_ctrl: Explicitly set Xen's default MSR_SPEC_CTRL value

2018-05-16 Thread Andrew Cooper
On 14/05/18 16:52, Jan Beulich wrote: On 14.05.18 at 17:39, wrote: >> On Fri, May 11, 2018 at 11:38:11AM +0100, Andrew Cooper wrote: >>> @@ -417,6 +419,32 @@ void __init init_speculation_mitigations(void) >>> setup_clear_cpu_cap(X86_FEATURE_NO_XPTI); >>> >>> print_details(thun

Re: [Xen-devel] [PATCH 07/10] x86/spec_ctrl: Explicitly set Xen's default MSR_SPEC_CTRL value

2018-05-14 Thread Jan Beulich
>>> On 14.05.18 at 17:39, wrote: > On Fri, May 11, 2018 at 11:38:11AM +0100, Andrew Cooper wrote: >> @@ -417,6 +419,32 @@ void __init init_speculation_mitigations(void) >> setup_clear_cpu_cap(X86_FEATURE_NO_XPTI); >> >> print_details(thunk, caps); >> + >> +/* >> + * If MSR_

Re: [Xen-devel] [PATCH 07/10] x86/spec_ctrl: Explicitly set Xen's default MSR_SPEC_CTRL value

2018-05-14 Thread Wei Liu
On Fri, May 11, 2018 at 11:38:11AM +0100, Andrew Cooper wrote: > @@ -417,6 +419,32 @@ void __init init_speculation_mitigations(void) > setup_clear_cpu_cap(X86_FEATURE_NO_XPTI); > > print_details(thunk, caps); > + > +/* > + * If MSR_SPEC_CTRL is available, apply Xen's default

[Xen-devel] [PATCH 07/10] x86/spec_ctrl: Explicitly set Xen's default MSR_SPEC_CTRL value

2018-05-11 Thread Andrew Cooper
With the impending ability to disable MSR_SPEC_CTRL handling on a per-guest-type basis, the first exit-from-guest may not have the side effect of loading Xen's choice of value. Explicitly set Xen's default during the BSP and AP boot paths. For the BSP however, delay setting a non-zero MSR_SPEC_CT