From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MDipq-0006Ae-LN for qemu-devel@nongnu.org; Mon, 08 Jun 2009 13:40:38 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MDipl-00069e-NL for qemu-devel@nongnu.org; Mon, 08 Jun 2009 13:40:38 -0400 Received: from [199.232.76.173] (port=43431 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MDipl-00069X-7g for qemu-devel@nongnu.org; Mon, 08 Jun 2009 13:40:33 -0400 Received: from mail-fx0-f219.google.com ([209.85.220.219]:51131) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MDipk-0003mJ-Qg for qemu-devel@nongnu.org; Mon, 08 Jun 2009 13:40:33 -0400 Received: by fxm19 with SMTP id 19so2816845fxm.34 for ; Mon, 08 Jun 2009 10:40:31 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: <20090608173625.GJ5558@redhat.com> References: <20090608120229.GD27210@redhat.com> <20090608173625.GJ5558@redhat.com> Date: Mon, 8 Jun 2009 20:40:29 +0300 Message-ID: Subject: Re: [Qemu-devel] [PATCH] remove unused field from pci device. From: Blue Swirl Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Gleb Natapov Cc: qemu-devel@nongnu.org On 6/8/09, Gleb Natapov wrote: > On Mon, Jun 08, 2009 at 08:31:09PM +0300, Blue Swirl wrote: > > On 6/8/09, Gleb Natapov wrote: > > > Signed-off-by: Gleb Natapov > > > diff --git a/hw/pci.c b/hw/pci.c > > > index 0ab5b94..02b335f 100644 > > > --- a/hw/pci.c > > > +++ b/hw/pci.c > > > @@ -268,7 +268,7 @@ static PCIDevice *do_pci_register_device(PCIDevice *pci_dev, PCIBus *bus, > > > config_write = pci_default_write_config; > > > pci_dev->config_read = config_read; > > > pci_dev->config_write = config_write; > > > - pci_dev->irq_index = pci_irq_index++; > > > + pci_irq_index++; > > > bus->devices[devfn] = pci_dev; > > > pci_dev->irq = qemu_allocate_irqs(pci_set_irq, pci_dev, 4); > > > return pci_dev; > > > diff --git a/hw/pci.h b/hw/pci.h > > > index 0405837..fb7b89a 100644 > > > --- a/hw/pci.h > > > +++ b/hw/pci.h > > > @@ -154,8 +154,6 @@ struct PCIDevice { > > > PCIConfigReadFunc *config_read; > > > PCIConfigWriteFunc *config_write; > > > PCIUnregisterFunc *unregister; > > > - /* ??? This is a PC-specific hack, and should be removed. */ > > > - int irq_index; > > > > > > /* IRQ objects for the INTA-INTD pins. */ > > > qemu_irq *irq; > > > > After the patch, pci_irq_index no longer tracks irqs but how many PCI > > devices there are in the system, so perhaps it should be renamed as > > well. > > pci_irq_index tracked the number of PCI devices before this patch too > since irq_index is unused anyway. Do you want me to resend the patch > with renaming or do renaming in separate patch? I guess it does not affect bisectability if you also do renaming in the same patch.