diff options
author | Andrey Smetanin <asmetanin@virtuozzo.com> | 2015-10-16 10:07:48 +0300 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2015-10-16 10:34:30 +0200 |
commit | f33143d80907602deb1b96db42da93507ed03b31 (patch) | |
tree | fa4ee9ba5c31e2652db7dcf32c89f9b0f8dcd3d1 /virt/kvm | |
parent | c9a5eccac1abf50649949f15754a7635f263a1ff (diff) | |
download | linux-rpi3-f33143d80907602deb1b96db42da93507ed03b31.tar.gz linux-rpi3-f33143d80907602deb1b96db42da93507ed03b31.tar.bz2 linux-rpi3-f33143d80907602deb1b96db42da93507ed03b31.zip |
kvm/irqchip: allow only multiple irqchip routes per GSI
Any other irq routing types (MSI, S390_ADAPTER, upcoming Hyper-V
SynIC) map one-to-one to GSI.
Signed-off-by: Andrey Smetanin <asmetanin@virtuozzo.com>
Reviewed-by: Roman Kagan <rkagan@virtuozzo.com>
Signed-off-by: Denis V. Lunev <den@openvz.org>
CC: Vitaly Kuznetsov <vkuznets@redhat.com>
CC: "K. Y. Srinivasan" <kys@microsoft.com>
CC: Gleb Natapov <gleb@kernel.org>
CC: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'virt/kvm')
-rw-r--r-- | virt/kvm/irqchip.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/virt/kvm/irqchip.c b/virt/kvm/irqchip.c index 716a1c4db528..f0b08a2a48ba 100644 --- a/virt/kvm/irqchip.c +++ b/virt/kvm/irqchip.c @@ -144,11 +144,11 @@ static int setup_routing_entry(struct kvm_irq_routing_table *rt, /* * Do not allow GSI to be mapped to the same irqchip more than once. - * Allow only one to one mapping between GSI and MSI. + * Allow only one to one mapping between GSI and non-irqchip routing. */ hlist_for_each_entry(ei, &rt->map[ue->gsi], link) - if (ei->type == KVM_IRQ_ROUTING_MSI || - ue->type == KVM_IRQ_ROUTING_MSI || + if (ei->type != KVM_IRQ_ROUTING_IRQCHIP || + ue->type != KVM_IRQ_ROUTING_IRQCHIP || ue->u.irqchip.irqchip == ei->irqchip.irqchip) return r; |