[PATCH 3/3] KVM: VMX: make MSR bitmaps per-VCPU

2018-01-31 Thread Paolo Bonzini
Place the MSR bitmap in struct loaded_vmcs, and update it in place every time the x2apic or APICv state can change. This is rare and the loop can handle 64 MSRs per iteration, in a similar fashion as nested_vmx_prepare_msr_bitmap. This prepares for choosing, on a per-VM basis, whether to intercep

Re: [PATCH 3/3] KVM: VMX: make MSR bitmaps per-VCPU

2018-01-30 Thread Jim Mattson
On Fri, Jan 26, 2018 at 2:51 PM, Paolo Bonzini wrote: > Place the MSR bitmap in struct loaded_vmcs, and update it in place > every time the x2apic or APICv state can change. This is rare and > the loop can handle 64 MSRs per iteration, in a similar fashion as > nested_vmx_prepare_msr_bitmap. > >

[PATCH 3/3] KVM: VMX: make MSR bitmaps per-VCPU

2018-01-26 Thread Paolo Bonzini
Place the MSR bitmap in struct loaded_vmcs, and update it in place every time the x2apic or APICv state can change. This is rare and the loop can handle 64 MSRs per iteration, in a similar fashion as nested_vmx_prepare_msr_bitmap. This prepares for choosing, on a per-VM basis, whether to intercep

[PATCH 3/3] KVM: VMX: make MSR bitmaps per-VCPU

2018-01-16 Thread Paolo Bonzini
Place the MSR bitmap in struct loaded_vmcs, and update it in place every time the x2apic or APICv state can change. This does not sound too efficient, but (with the exception of nested virt) it's rare and the loop can handle 64 MSRs per iteration, in a similar fashion as nested_vmx_prepare_msr_bit