All of lore.kernel.org
 help / color / mirror / Atom feed
From: Bandan Das <bsd@redhat.com>
To: Paolo Bonzini <pbonzini@redhat.com>
Cc: linux-kernel@vger.kernel.org, kvm@vger.kernel.org, rkrcmar@redhat.com
Subject: Re: [RFC PATCH 2/2] KVM: x86: use __kvm_guest_exit
Date: Thu, 16 Jun 2016 18:01:44 -0400	[thread overview]
Message-ID: <jpgbn3023p3.fsf@linux.bootlegged.copy> (raw)
In-Reply-To: 1466065297-4644-3-git-send-email-pbonzini@redhat.com

...
>  static bool vmx_has_high_real_mode_segbase(void)
> diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c
> index 7e3041ef050f..cc741b68139c 100644
> --- a/arch/x86/kvm/x86.c
> +++ b/arch/x86/kvm/x86.c
> @@ -6706,21 +6706,13 @@ static int vcpu_enter_guest(struct kvm_vcpu *vcpu)
>  
>  	kvm_put_guest_xcr0(vcpu);
>  
> -	/* Interrupt is enabled by handle_external_intr() */
>  	kvm_x86_ops->handle_external_intr(vcpu);
>  
>  	++vcpu->stat.exits;
>  
> -	/*
> -	 * We must have an instruction between local_irq_enable() and
> -	 * kvm_guest_exit(), so the timer interrupt isn't delayed by
> -	 * the interrupt shadow.  The stat.exits increment will do nicely.
> -	 * But we need to prevent reordering, hence this barrier():
> -	 */
> -	barrier();
> -
> -	kvm_guest_exit();
> +	__kvm_guest_exit();

kvm_guest_exit has no more callers and so can be removed.

Bandan

> +	local_irq_enable();
>  	preempt_enable();
>  
>  	vcpu->srcu_idx = srcu_read_lock(&vcpu->kvm->srcu);

  parent reply	other threads:[~2016-06-16 22:01 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-16  8:21 [RFC PATCH 0/2] KVM: x86: guest exit microoptimization Paolo Bonzini
2016-06-16  8:21 ` [RFC PATCH 1/2] KVM: x86: always use "acknowledge interrupt on exit" Paolo Bonzini
2016-06-16 21:53   ` Bandan Das
2016-06-16  8:21 ` [RFC PATCH 2/2] KVM: x86: use __kvm_guest_exit Paolo Bonzini
2016-06-16 16:43   ` David Matlack
2016-06-16 16:47     ` Paolo Bonzini
2016-06-16 17:03       ` David Matlack
2016-06-16 17:21         ` Paolo Bonzini
2016-06-16 22:01   ` Bandan Das [this message]
2016-06-17  5:20     ` Paolo Bonzini
2016-07-01 16:45 ` [RFC PATCH 0/2] KVM: x86: guest exit microoptimization Paolo Bonzini

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=jpgbn3023p3.fsf@linux.bootlegged.copy \
    --to=bsd@redhat.com \
    --cc=kvm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pbonzini@redhat.com \
    --cc=rkrcmar@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.