From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:51428) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TYnkN-0005WF-2Y for qemu-devel@nongnu.org; Wed, 14 Nov 2012 19:56:02 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TYnkJ-0002tB-Vo for qemu-devel@nongnu.org; Wed, 14 Nov 2012 19:55:58 -0500 Received: from cantor2.suse.de ([195.135.220.15]:47202 helo=mx2.suse.de) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TYnkJ-0002t1-MS for qemu-devel@nongnu.org; Wed, 14 Nov 2012 19:55:55 -0500 Message-ID: <50A43D90.6030806@suse.de> Date: Thu, 15 Nov 2012 01:55:44 +0100 From: =?ISO-8859-15?Q?Andreas_F=E4rber?= MIME-Version: 1.0 References: <1352352972-2510-1-git-send-email-liwanp@linux.vnet.ibm.com> <1352352972-2510-4-git-send-email-liwanp@linux.vnet.ibm.com> In-Reply-To: <1352352972-2510-4-git-send-email-liwanp@linux.vnet.ibm.com> Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH v5 3/3] convert pci-host to QOM List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Wanpeng Li Cc: Anthony Liguori , "Michael S. Tsirkin" , Jan Kiszka , qemu-devel@nongnu.org, Ram Pai , Blue Swirl , Stefan Weil , Liu Ping Fan , Paolo Bonzini , Avi Kivity Am 08.11.2012 06:36, schrieb Wanpeng Li: > Take advantage of Andreas's pci-host patchset, add instance_init functi= on > to fully implement convert pci-host to QOM. >=20 > Signed-off-by: Anthony Liguori > Signed-off-by: Wanpeng Li > --- > hw/pci_host.c | 9 +++++++++ > 1 files changed, 9 insertions(+), 0 deletions(-) >=20 > diff --git a/hw/pci_host.c b/hw/pci_host.c > index 68e328c..ce6b28f 100644 > --- a/hw/pci_host.c > +++ b/hw/pci_host.c > @@ -165,11 +165,20 @@ const MemoryRegionOps pci_host_data_be_ops =3D { > .endianness =3D DEVICE_BIG_ENDIAN, > }; > =20 > +static void pci_host_initfn(Object *obj) > +{ > + PCIHostState *s =3D PCI_HOST_BRIDGE(obj); > + > + object_property_add_link(obj, "mmio", "memory-region", > + (Object **)&s->address_space, NULL); This strikes me as wrong, unless I've overlooked something in the previous patches. Also the commit message seems outdated. Please cc me on the next version, I received no response to my question about i440fx status and just noticed this now. Regards, Andreas > +} > + > static const TypeInfo pci_host_type_info =3D { > .name =3D TYPE_PCI_HOST_BRIDGE, > .parent =3D TYPE_SYS_BUS_DEVICE, > .abstract =3D true, > .instance_size =3D sizeof(PCIHostState), > + .instance_init =3D pci_host_initfn, > }; > =20 > static void pci_host_register_types(void) --=20 SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 N=FCrnberg, Germany GF: Jeff Hawn, Jennifer Guild, Felix Imend=F6rffer; HRB 16746 AG N=FCrnbe= rg