From mboxrd@z Thu Jan 1 00:00:00 1970 From: Rusty Russell Subject: Re: [PATCHv4 2/2] virtio: refactor find_vqs Date: Thu, 27 Aug 2009 20:32:24 +0930 Message-ID: <200908272032.24724.rusty@rustcorp.com.au> References: <200908271900.34757.rusty@rustcorp.com.au> <20090827094926.GB8391@redhat.com> Mime-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Cc: Christian Borntraeger , virtualization@lists.linux-foundation.org, Anthony Liguori , kvm@vger.kernel.org, avi@redhat.com, Carsten Otte , amit.shah@redhat.com To: "Michael S. Tsirkin" Return-path: Received: from ozlabs.org ([203.10.76.45]:51248 "EHLO ozlabs.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750985AbZH0LC1 (ORCPT ); Thu, 27 Aug 2009 07:02:27 -0400 In-Reply-To: <20090827094926.GB8391@redhat.com> Content-Disposition: inline Sender: kvm-owner@vger.kernel.org List-ID: On Thu, 27 Aug 2009 07:19:26 pm Michael S. Tsirkin wrote: > On Thu, Aug 27, 2009 at 07:00:34PM +0930, Rusty Russell wrote: > > On Tue, 25 Aug 2009 09:34:34 pm Michael S. Tsirkin wrote: > > > > That's because we didn't do the request_irq's for the per_vector case, because > > > > we don't have the names. This is what prevented me from doing a nice > > > > encapsulation. > > > > > > Yes. But let's split free_vectors out into free_msix_vectors and > > > free_intx as well? > > > > Perhaps. Patch welcome :) > > Could you put the end result somewhere so I can work on top of it? Sure, it'll hit linux-next tomorrow, otherwise you can steal from http://ozlabs.org/~rusty/kernel/rr-latest (virtio:pci-minor-cleanups.patch and virtio:pci-minor-cleanups-fix.patch). > > But vector for something which isn't always the vector > > is misleading, IMHO. > > I think you mean it's isn't always used? It's always a vector ... The non-MSI case, it's set to VIRTIO_MSI_NO_VECTOR, and we use a normal interrupt vector. > BTW, let's get rid of msix_enabled completely? > We can always use msix_vectors ... That would be nice. But yes, requiring more audit. Ideally, if msix_vectors == 0, implies intx_enabled. Thanks, Rusty.