Re: [Qemu-devel] [PATCH 8/8] qom: Make CPU a child of DeviceState

2013-01-02 Thread Eduardo Habkost
On Wed, Jan 02, 2013 at 05:40:58PM +0100, Igor Mammedov wrote: > On Wed, 02 Jan 2013 16:08:42 +0100 > Andreas Färber wrote: > > > Am 05.12.2012 17:49, schrieb Eduardo Habkost: > > > This finally makes the CPU class a child of DeviceState, allowing us to > > > start using DeviceState properties on

Re: [Qemu-devel] [PATCH 8/8] qom: Make CPU a child of DeviceState

2013-01-02 Thread Igor Mammedov
On Wed, 02 Jan 2013 16:08:42 +0100 Andreas Färber wrote: > Am 05.12.2012 17:49, schrieb Eduardo Habkost: > > This finally makes the CPU class a child of DeviceState, allowing us to > > start using DeviceState properties on CPU subclasses. > > To avoid confusion with child<> properties and Device

Re: [Qemu-devel] [PATCH 8/8] qom: Make CPU a child of DeviceState

2013-01-02 Thread Andreas Färber
Am 05.12.2012 17:49, schrieb Eduardo Habkost: > This finally makes the CPU class a child of DeviceState, allowing us to > start using DeviceState properties on CPU subclasses. To avoid confusion with child<> properties and DeviceState vs. DeviceClass I have reworded this to "subclass of Device" in

Re: [Qemu-devel] [PATCH 8/8] qom: Make CPU a child of DeviceState

2012-12-14 Thread Eduardo Habkost
On Fri, Dec 14, 2012 at 04:44:24PM +0100, Andreas Färber wrote: > Am 14.12.2012 16:40, schrieb Paolo Bonzini: > > Il 14/12/2012 16:29, Andreas Färber ha scritto: > >> The latest motivation for making the CPU a device was to have the static > >> properties infrastructure for machine/CPU versioning.

Re: [Qemu-devel] [PATCH 8/8] qom: Make CPU a child of DeviceState

2012-12-14 Thread Andreas Färber
Am 14.12.2012 16:40, schrieb Paolo Bonzini: > Il 14/12/2012 16:29, Andreas Färber ha scritto: >> The latest motivation for making the CPU a device was to have the static >> properties infrastructure for machine/CPU versioning. The global >> property defaults are set in qdev's instance_init, so obje

Re: [Qemu-devel] [PATCH 8/8] qom: Make CPU a child of DeviceState

2012-12-14 Thread Paolo Bonzini
Il 14/12/2012 16:29, Andreas Färber ha scritto: > The latest motivation for making the CPU a device was to have the static > properties infrastructure for machine/CPU versioning. The global > property defaults are set in qdev's instance_init, so object_new() seems > fine for that. > > qdev_[try_]c

Re: [Qemu-devel] [PATCH 8/8] qom: Make CPU a child of DeviceState

2012-12-14 Thread Andreas Färber
Am 12.12.2012 15:27, schrieb Igor Mammedov: > On Wed, 12 Dec 2012 11:59:01 -0200 > Eduardo Habkost wrote: >> On Wed, Dec 12, 2012 at 02:34:08PM +0100, Andreas Färber wrote: >>> This patch makes the CPU a device and looks good so far but does not >>> initialize the devices in cpu_*_init() like Anth

Re: [Qemu-devel] [PATCH 8/8] qom: Make CPU a child of DeviceState

2012-12-12 Thread Eduardo Habkost
On Wed, Dec 12, 2012 at 03:27:24PM +0100, Igor Mammedov wrote: > On Wed, 12 Dec 2012 11:59:01 -0200 > Eduardo Habkost wrote: > > > On Wed, Dec 12, 2012 at 02:34:08PM +0100, Andreas Färber wrote: > > > Am 05.12.2012 17:49, schrieb Eduardo Habkost: > > [...] > > > > static TypeInfo cpu_type_info =

Re: [Qemu-devel] [PATCH 8/8] qom: Make CPU a child of DeviceState

2012-12-12 Thread Igor Mammedov
On Wed, 12 Dec 2012 11:59:01 -0200 Eduardo Habkost wrote: > On Wed, Dec 12, 2012 at 02:34:08PM +0100, Andreas Färber wrote: > > Am 05.12.2012 17:49, schrieb Eduardo Habkost: > [...] > > > static TypeInfo cpu_type_info = { > > > .name = TYPE_CPU, > > > -.parent = TYPE_OBJECT, > > > +

Re: [Qemu-devel] [PATCH 8/8] qom: Make CPU a child of DeviceState

2012-12-12 Thread Eduardo Habkost
On Wed, Dec 12, 2012 at 02:34:08PM +0100, Andreas Färber wrote: > Am 05.12.2012 17:49, schrieb Eduardo Habkost: [...] > > static TypeInfo cpu_type_info = { > > .name = TYPE_CPU, > > -.parent = TYPE_OBJECT, > > +.parent = TYPE_DEVICE, > > .instance_size = sizeof(CPUState), > >

Re: [Qemu-devel] [PATCH 8/8] qom: Make CPU a child of DeviceState

2012-12-12 Thread Andreas Färber
Am 05.12.2012 17:49, schrieb Eduardo Habkost: > This finally makes the CPU class a child of DeviceState, allowing us to > start using DeviceState properties on CPU subclasses. > > It has no_user=1, as creating CPUs using -device doesn't work yet. > > (based on a previous patch from Igor Mammedov)

[Qemu-devel] [PATCH 8/8] qom: Make CPU a child of DeviceState

2012-12-05 Thread Eduardo Habkost
This finally makes the CPU class a child of DeviceState, allowing us to start using DeviceState properties on CPU subclasses. It has no_user=1, as creating CPUs using -device doesn't work yet. (based on a previous patch from Igor Mammedov) Signed-off-by: Eduardo Habkost --- Changes v1 (imammedo