From: Paolo Bonzini <pbonzini@redhat.com>
To: Jan Kiszka <jan.kiszka@siemens.com>,
Gleb Natapov <gleb@kernel.org>,
Marcelo Tosatti <mtosatti@redhat.com>
Cc: kvm <kvm@vger.kernel.org>
Subject: Re: [PATCH v3 1/3] KVM: nVMX: Rework interception of IRQs and NMIs
Date: Fri, 07 Mar 2014 16:44:53 +0100 [thread overview]
Message-ID: <5319E975.1030400@redhat.com> (raw)
In-Reply-To: <df6ee697e66e0dece17357a3ed56f6d3963a324c.1394127237.git.jan.kiszka@siemens.com>
Il 06/03/2014 18:33, Jan Kiszka ha scritto:
> Move the check for leaving L2 on pending and intercepted IRQs or NMIs
> from the *_allowed handler into a dedicated callback. Invoke this
> callback at the relevant points before KVM checks if IRQs/NMIs can be
> injected. The callback has the task to switch from L2 to L1 if needed
> and inject the proper vmexit events.
>
> The rework fixes L2 wakeups from HLT and provides the foundation for
> preemption timer emulation.
>
> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
> ---
> arch/x86/include/asm/kvm_host.h | 2 ++
> arch/x86/kvm/vmx.c | 67 +++++++++++++++++++++++------------------
> arch/x86/kvm/x86.c | 15 +++++++--
> 3 files changed, 53 insertions(+), 31 deletions(-)
With this patch do we still need
if (is_guest_mode(vcpu) && nested_exit_on_intr(vcpu))
/*
* We get here if vmx_interrupt_allowed() said we can't
* inject to L1 now because L2 must run. The caller will have
* to make L2 exit right after entry, so we can inject to L1
* more promptly.
*/
return -EBUSY;
in enable_irq_window? If not, enable_nmi_window and enable_irq_window
can both return void.
And perhaps, vmx_check_nested_events could use the preemption timer trick
from Jailhouse instead of smp_send_reschedule.
Paolo
next prev parent reply other threads:[~2014-03-07 15:44 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-03-06 17:33 [PATCH v3 0/3] KVM: x86: Pending nVMX fixes Jan Kiszka
2014-03-06 17:33 ` [PATCH v3 1/3] KVM: nVMX: Rework interception of IRQs and NMIs Jan Kiszka
2014-03-07 15:44 ` Paolo Bonzini [this message]
2014-03-07 16:29 ` Jan Kiszka
2014-03-07 16:46 ` Paolo Bonzini
2014-03-07 17:28 ` Jan Kiszka
2014-03-07 18:19 ` Jan Kiszka
2014-03-07 18:24 ` Paolo Bonzini
2014-03-07 18:26 ` Jan Kiszka
2014-03-07 19:45 ` Paolo Bonzini
2014-03-06 17:33 ` [PATCH v3 2/3] KVM: nVMX: Fully emulate preemption timer Jan Kiszka
2014-03-07 17:20 ` Marcelo Tosatti
2014-03-07 17:24 ` Paolo Bonzini
2014-03-06 17:33 ` [PATCH v3 3/3] KVM: nVMX: Do not inject NMI vmexits when L2 has a pending interrupt Jan Kiszka
2014-03-06 17:41 ` [PATCH v3 0/3] KVM: x86: Pending nVMX fixes 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=5319E975.1030400@redhat.com \
--to=pbonzini@redhat.com \
--cc=gleb@kernel.org \
--cc=jan.kiszka@siemens.com \
--cc=kvm@vger.kernel.org \
--cc=mtosatti@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.