[Bug 1465935] Re: kvm_irqchip_commit_routes: Assertion `ret == 0' failed
Li Chengyuan
chengyuanli at gmail.com
Wed Jul 1 14:10:07 UTC 2015
-----Original Message-----
From: Paolo Bonzini [mailto:pbonzini at redhat.com]
Sent: 2015年7月1日 21:39
To: Li, Chengyuan
Cc: kevinnma at tencent.com
Subject: Re: [Qemu-devel] [PATCH] Fix irq route entries exceed KVM_MAX_IRQ_ROUTES
On 30/06/2015 05:47, Li, Chengyuan wrote:
> Here is my understanding,
>
> 1) why isn't the existing check in kvm_irqchip_get_virq enough to fix
> the bug?
>
> From kvm_pc_setup_irq_routing() function, we can see that 15 routes
> from PIC and 23 routes from IOAPIC are added into irq route table, but
> only
> 23 irq(gsi) are reserved. This leads to irq route table has been full
> but there are still 15 free gsi. So the "retry" part of
> kvm_irqchip_get_virq() shall never have chance to be executed.
>
> 2) If you introduce this extra call to kvm_flush_dynamic_msi_routes,
> does the existing check become obsolete?
>
> As gsi_count is the max number of irq route table, if below code is
> merged, then existing check is obsolete and can be removed.
>
> + if (!s->direct_msi && s->irq_routes->nr == s->gsi_count) {
> + kvm_flush_dynamic_msi_routes(s);
> + }
>
> Please let me know if you have some other comments for the patch? Thanks!
Thanks for finally clearing up my doubts about the patch! I'll apply it
soon.
Paolo
--
You received this bug notification because you are a member of Ubuntu
Server Team, which is subscribed to qemu in Ubuntu.
https://bugs.launchpad.net/bugs/1465935
Title:
kvm_irqchip_commit_routes: Assertion `ret == 0' failed
To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1465935/+subscriptions
More information about the Ubuntu-server-bugs
mailing list