From: "Radim Krčmář" <rkrcmar@redhat.com>
To: linux-kernel@vger.kernel.org, kvm@vger.kernel.org
Cc: Paolo Bonzini <pbonzini@redhat.com>,
Igor Mammedov <imammedo@redhat.com>,
David Hildenbrand <david@redhat.com>
Subject: [PATCH v2 1/4] KVM: x86: use delivery to self in hyperv synic
Date: Tue, 13 Dec 2016 17:29:58 +0100 [thread overview]
Message-ID: <20161213163001.4567-2-rkrcmar@redhat.com> (raw)
In-Reply-To: <20161213163001.4567-1-rkrcmar@redhat.com>
Interrupt to self can be sent without knowing the APIC ID.
Reviewed-by: David Hildenbrand <david@redhat.com>
Signed-off-by: Radim Krčmář <rkrcmar@redhat.com>
---
v2: r-b David
arch/x86/kvm/hyperv.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/x86/kvm/hyperv.c b/arch/x86/kvm/hyperv.c
index 99cde5220e07..313957ec9a9d 100644
--- a/arch/x86/kvm/hyperv.c
+++ b/arch/x86/kvm/hyperv.c
@@ -305,13 +305,13 @@ static int synic_set_irq(struct kvm_vcpu_hv_synic *synic, u32 sint)
return -ENOENT;
memset(&irq, 0, sizeof(irq));
- irq.dest_id = kvm_apic_id(vcpu->arch.apic);
+ irq.shorthand = APIC_DEST_SELF;
irq.dest_mode = APIC_DEST_PHYSICAL;
irq.delivery_mode = APIC_DM_FIXED;
irq.vector = vector;
irq.level = 1;
- ret = kvm_irq_delivery_to_apic(vcpu->kvm, NULL, &irq, NULL);
+ ret = kvm_irq_delivery_to_apic(vcpu->kvm, vcpu->arch.apic, &irq, NULL);
trace_kvm_hv_synic_set_irq(vcpu->vcpu_id, sint, irq.vector, ret);
return ret;
}
--
2.11.0
next prev parent reply other threads:[~2016-12-13 16:29 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-12-13 16:29 [PATCH v2 0/4] KVM: x86: allow hotplug of VCPU with APIC ID over 0xff Radim Krčmář
2016-12-13 16:29 ` Radim Krčmář [this message]
2016-12-13 16:29 ` [PATCH v2 2/4] KVM: x86: replace kvm_apic_id with kvm_{x,x2}apic_id Radim Krčmář
2016-12-14 12:39 ` David Hildenbrand
2016-12-14 13:41 ` Radim Krčmář
2016-12-14 15:50 ` Paolo Bonzini
2016-12-14 16:15 ` David Hildenbrand
2016-12-14 16:59 ` Paolo Bonzini
2016-12-14 17:15 ` Radim Krčmář
2016-12-14 17:12 ` Radim Krčmář
2016-12-14 17:26 ` David Hildenbrand
2016-12-13 16:30 ` [PATCH v2 3/4] KVM: x86: make interrupt delivery fast and slow path behave the same Radim Krčmář
2016-12-13 16:30 ` [PATCH v2 4/4] KVM: x86: allow hotplug of VCPU with APIC ID over 0xff Radim Krčmář
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=20161213163001.4567-2-rkrcmar@redhat.com \
--to=rkrcmar@redhat.com \
--cc=david@redhat.com \
--cc=imammedo@redhat.com \
--cc=kvm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=pbonzini@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox