From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [PATCH v6] kvm: Use a bitmap for tracking used GSIs Date: Sun, 17 May 2009 23:54:38 +0300 Message-ID: <4A10798E.4030301@redhat.com> References: <20090513150815.8221.49221.stgit@dl380g6-3.ned.telco.ned.telco> <20090513172350.8722.70990.stgit@dl380g6-3.ned.telco.ned.telco> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: kvm@vger.kernel.org, sheng.yang@intel.com, mst@redhat.com To: Alex Williamson Return-path: Received: from mx2.redhat.com ([66.187.237.31]:38144 "EHLO mx2.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752628AbZEQUyl (ORCPT ); Sun, 17 May 2009 16:54:41 -0400 In-Reply-To: <20090513172350.8722.70990.stgit@dl380g6-3.ned.telco.ned.telco> Sender: kvm-owner@vger.kernel.org List-ID: Alex Williamson wrote: > We're currently using a counter to track the most recent GSI we've > handed out. This quickly hits KVM_MAX_IRQ_ROUTES when using device > assignment with a driver that regularly toggles the MSI enable bit. > This can mean only a few minutes of usable run time. Instead, track > used GSIs in a bitmap. > > v6: Make use of ALIGN macro, per Michael > Define KVM_IOAPIC_NUM_PINS if not already, per Michael > Due to me being slow I nacked this after you prepared the new patch. Sorry. We could define have platform_gsis passed from qemu to tell us how many GSIs to reserve (let's pretend libkvm isn't on death row for a moment). -- Do not meddle in the internals of kernels, for they are subtle and quick to panic.