From: Jan Kiszka <jan.kiszka@siemens.com>
To: Avi Kivity <avi@redhat.com>, Marcelo Tosatti <mtosatti@redhat.com>
Cc: Alex Williamson <alex.williamson@redhat.com>,
Jason Baron <jbaron@redhat.com>,
"kvm@vger.kernel.org" <kvm@vger.kernel.org>,
"qemu-devel@nongnu.org" <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] [PATCH] kvm: set gsi_bits and max_gsi correctly
Date: Wed, 28 Mar 2012 20:27:14 +0200 [thread overview]
Message-ID: <4F735802.1020805@siemens.com> (raw)
In-Reply-To: <1332958820.3799.32.camel@bling.home>
On 2012-03-28 20:20, Alex Williamson wrote:
> On Wed, 2012-03-28 at 14:18 -0400, Jason Baron wrote:
>> The current kvm_init_irq_routing() doesn't set up the used_gsi_bitmap
>> correctly, and as a consequence pins max_gsi to 32 when it really
>> should be 1024. I ran into this limitation while testing pci
>> passthrough, where I consistently got an -ENOSPC return from
>> kvm_get_irq_route_gsi() called from assigned_dev_update_msix_mmio().
>>
>> Signed-off-by: Jason Baron <jbaron@redhat.com>
>> ---
>> kvm-all.c | 2 +-
>> 1 files changed, 1 insertions(+), 1 deletions(-)
>>
>> diff --git a/kvm-all.c b/kvm-all.c
>> index ab88c7c..b616c7d 100644
>> --- a/kvm-all.c
>> +++ b/kvm-all.c
>> @@ -873,7 +873,7 @@ static void kvm_init_irq_routing(KVMState *s)
>> unsigned int gsi_bits, i;
>>
>> /* Round up so we can search ints using ffs */
>> - gsi_bits = (gsi_count + 31) / 32;
>> + gsi_bits = ALIGN(gsi_count, 32);
>> s->used_gsi_bitmap = g_malloc0(gsi_bits / 8);
>> s->max_gsi = gsi_bits;
>>
>
> Acked-by: Alex Williamson <alex.williamson@redhat.com>
>
Acked-by: Jan Kiszka <jan.kiszka@siemens.com>
Tagging this as "PATCH uq/master" may help Avi and Marcelo to identify
and pick it up for that queue.
Thanks,
Jan
--
Siemens AG, Corporate Technology, CT T DE IT 1
Corporate Competence Center Embedded Linux
prev parent reply other threads:[~2012-03-28 18:27 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-03-28 18:18 [Qemu-devel] [PATCH] kvm: set gsi_bits and max_gsi correctly Jason Baron
2012-03-28 18:20 ` Alex Williamson
2012-03-28 18:27 ` Jan Kiszka [this message]
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=4F735802.1020805@siemens.com \
--to=jan.kiszka@siemens.com \
--cc=alex.williamson@redhat.com \
--cc=avi@redhat.com \
--cc=jbaron@redhat.com \
--cc=kvm@vger.kernel.org \
--cc=mtosatti@redhat.com \
--cc=qemu-devel@nongnu.org \
/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;
as well as URLs for NNTP newsgroup(s).