From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MfZ8R-0008S5-7g for qemu-devel@nongnu.org; Mon, 24 Aug 2009 08:58:55 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MfZ8L-0008MS-V6 for qemu-devel@nongnu.org; Mon, 24 Aug 2009 08:58:54 -0400 Received: from [199.232.76.173] (port=51416 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MfZ8L-0008Ly-LO for qemu-devel@nongnu.org; Mon, 24 Aug 2009 08:58:49 -0400 Received: from mx1.redhat.com ([209.132.183.28]:14453) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MfZ8L-0001UB-1T for qemu-devel@nongnu.org; Mon, 24 Aug 2009 08:58:49 -0400 Received: from int-mx08.intmail.prod.int.phx2.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id n7OCwmTw010073 for ; Mon, 24 Aug 2009 08:58:48 -0400 From: Juan Quintela In-Reply-To: <4A92896C.2050808@redhat.com> (Gerd Hoffmann's message of "Mon, 24 Aug 2009 14:37:00 +0200") References: <4A92896C.2050808@redhat.com> Date: Mon, 24 Aug 2009 14:56:27 +0200 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Subject: [Qemu-devel] Re: [PATCH 00/22] Indirection Cleanup List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Gerd Hoffmann Cc: qemu-devel@nongnu.org Gerd Hoffmann wrote: > On 08/24/09 13:03, Juan Quintela wrote: >> This patch series clean up "half" converted qemu drivers that had changed from: >> >> struct FOOState >> >> to >> >> typedef PCIFOOState { >> PCIDevice dev; >> FOOState foo; >> } PCIFOOState; >> >> It just moves PCIDevice to be the 1st field of FOOState. > > Note that there are a bunch of cases where it actually makes sense to > have PCIFOOState because foo can be connected to different busses and > thus there is a ISAFOOState (or will be once ISA is qdevified too). > > Disclaimer: did't look through the patches yet, just scanned the > subjects. But I've seen ne2000 + vga on the list. For both devices > ISA variants exist. Likewise OHCI, there are also non-PCI variants. on the PCI/ISA difference: * ne2000: just looked again at it, we could probably found a way to get that around. * vga: this needs major refactoring. * OHCI: I did the change, and everything compiled, didn't found the other uses :p I didn't changed it because then I had to replicate the save/load functions. (looking at it again, it appears that this ones are the only diff) >> - pcnet: It needs a different approach, because it can be both a PCIDevice >> or a SysBus device. > > That one too ;) > Why do you want to change it? PCNetState first field is PCIDevice *pci_dev. and that device is also for lance. Will take a look at your approach for diferentaiting them. Later, Juan.