Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1475026

Re: [PATCH 2/2] KVM: nVMX: make emulated nested preemption timer pinned

From Paolo Bonzini <pbonzini@redhat.com>
Newsgroups linux.kernel
Subject Re: [PATCH 2/2] KVM: nVMX: make emulated nested preemption timer pinned
Date 2016-09-02 13:00 +0200
Message-ID <scUmu-6SO-13@gated-at.bofh.it> (permalink)
References <sbMqZ-2gM-3@gated-at.bofh.it> <sbMqZ-2gM-9@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw



On 30/08/2016 10:14, Wanpeng Li wrote:
> From: Wanpeng Li <wanpeng.li@hotmail.com>
> 
> Commit 61abdbe0bc ("kvm: x86: make lapic hrtimer pinned") pins the emulated 
> lapic timer. This patch does the same for the emulated nested preemption 
> timer to avoid vmexit an unrelated vCPU and the latency of kicking IPI to 
> another vCPU.
> 
> Cc: Paolo Bonzini <pbonzini@redhat.com>
> Cc: Radim Krčmář <rkrcmar@redhat.com>
> Cc: Yunhong Jiang <yunhong.jiang@intel.com>
> Signed-off-by: Wanpeng Li <wanpeng.li@hotmail.com>
> ---
>  arch/x86/kvm/vmx.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
> index 5cede40..090a3f8 100644
> --- a/arch/x86/kvm/vmx.c
> +++ b/arch/x86/kvm/vmx.c
> @@ -7013,7 +7013,7 @@ static int handle_vmon(struct kvm_vcpu *vcpu)
>  	vmx->nested.vmcs02_num = 0;
>  
>  	hrtimer_init(&vmx->nested.preemption_timer, CLOCK_MONOTONIC,
> -		     HRTIMER_MODE_REL);
> +		     HRTIMER_MODE_REL_PINNED);
>  	vmx->nested.preemption_timer.function = vmx_preemption_timer_fn;
>  
>  	vmx->nested.vmxon = true;
> 

Queued for 4.9, thanks.

Paolo

Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH 1/2] KVM: lapic: fix preemption timer backward when TSC backward Wanpeng Li <kernellwp@gmail.com> - 2016-08-30 10:20 +0200
  [PATCH 2/2] KVM: nVMX: make emulated nested preemption timer pinned Wanpeng Li <kernellwp@gmail.com> - 2016-08-30 10:20 +0200
    Re: [PATCH 2/2] KVM: nVMX: make emulated nested preemption timer  pinned Paolo Bonzini <pbonzini@redhat.com> - 2016-09-02 13:00 +0200
  Re: [PATCH 1/2] KVM: lapic: fix preemption timer backward when TSC  backward Paolo Bonzini <pbonzini@redhat.com> - 2016-09-02 13:00 +0200

csiph-web