Re: [Qemu-devel] [PATCH RFC 2/2] qmp: New command qom-new

2012-05-24 Thread Igor Mammedov
On 05/24/2012 04:01 PM, Andreas Färber wrote: Am 24.05.2012 15:48, schrieb Igor Mammedov: On 05/24/2012 03:04 PM, Anthony Liguori wrote: I'm not sure how I feel about this. I never intended for a user to be able to create objects that were arbitrary children of other objects. In some ways, I

Re: [Qemu-devel] [PATCH RFC 2/2] qmp: New command qom-new

2012-05-24 Thread Michael Roth
On Thu, May 24, 2012 at 04:24:53PM +0200, Markus Armbruster wrote: > Anthony Liguori writes: > > > On 05/24/2012 06:43 AM, Markus Armbruster wrote: > >> To create objects via QMP. > >> > >> Test case: > >> > >> $ upstream-qemu --enable-kvm -S -m 384 -vnc :0 -monitor stdio -chardev > >> socket,id

Re: [Qemu-devel] [PATCH RFC 2/2] qmp: New command qom-new

2012-05-24 Thread Markus Armbruster
Anthony Liguori writes: > On 05/24/2012 06:43 AM, Markus Armbruster wrote: >> To create objects via QMP. >> >> Test case: >> >> $ upstream-qemu --enable-kvm -S -m 384 -vnc :0 -monitor stdio -chardev >> socket,id=qmp,path=test-qmp,server=on,wait=off -mon mode=control,chardev=qmp >> >> Conversatio

Re: [Qemu-devel] [PATCH RFC 2/2] qmp: New command qom-new

2012-05-24 Thread Anthony Liguori
On 05/24/2012 08:44 AM, Paolo Bonzini wrote: Il 24/05/2012 14:58, Anthony Liguori ha scritto: We should change that to a parent_bus property, parent_bus is a property with the QOM bus series I missed that... BTW do we need an object_property_add_link_readonly? Do we want it to be a read-o

Re: [Qemu-devel] [PATCH RFC 2/2] qmp: New command qom-new

2012-05-24 Thread Anthony Liguori
On 05/24/2012 09:01 AM, Andreas Färber wrote: Am 24.05.2012 15:48, schrieb Igor Mammedov: On 05/24/2012 03:04 PM, Anthony Liguori wrote: I'm not sure how I feel about this. I never intended for a user to be able to create objects that were arbitrary children of other objects. In some ways, I

Re: [Qemu-devel] [PATCH RFC 2/2] qmp: New command qom-new

2012-05-24 Thread Anthony Liguori
On 05/24/2012 08:48 AM, Igor Mammedov wrote: On 05/24/2012 03:04 PM, Anthony Liguori wrote: On 05/24/2012 06:43 AM, Markus Armbruster wrote: To create objects via QMP. Test case: $ upstream-qemu --enable-kvm -S -m 384 -vnc :0 -monitor stdio -chardev socket,id=qmp,path=test-qmp,server=on,wait=

Re: [Qemu-devel] [PATCH RFC 2/2] qmp: New command qom-new

2012-05-24 Thread Andreas Färber
Am 24.05.2012 15:48, schrieb Igor Mammedov: > On 05/24/2012 03:04 PM, Anthony Liguori wrote: >> >> I'm not sure how I feel about this. I never intended for a user to be >> able to create objects that were arbitrary children of other objects. >> >> In some ways, I think this is almost too powerful o

Re: [Qemu-devel] [PATCH RFC 2/2] qmp: New command qom-new

2012-05-24 Thread Igor Mammedov
On 05/24/2012 03:04 PM, Anthony Liguori wrote: On 05/24/2012 06:43 AM, Markus Armbruster wrote: To create objects via QMP. Test case: $ upstream-qemu --enable-kvm -S -m 384 -vnc :0 -monitor stdio -chardev socket,id=qmp,path=test-qmp,server=on,wait=off -mon mode=control,chardev=qmp Conversati

Re: [Qemu-devel] [PATCH RFC 2/2] qmp: New command qom-new

2012-05-24 Thread Paolo Bonzini
Il 24/05/2012 14:58, Anthony Liguori ha scritto: >> >> We should change that to a parent_bus property, > > parent_bus is a property with the QOM bus series I missed that... BTW do we need an object_property_add_link_readonly? Paolo

Re: [Qemu-devel] [PATCH RFC 2/2] qmp: New command qom-new

2012-05-24 Thread Anthony Liguori
On 05/24/2012 06:43 AM, Markus Armbruster wrote: To create objects via QMP. Test case: $ upstream-qemu --enable-kvm -S -m 384 -vnc :0 -monitor stdio -chardev socket,id=qmp,path=test-qmp,server=on,wait=off -mon mode=control,chardev=qmp Conversation on the qmp socket: {"QMP": {"version": {"qemu

Re: [Qemu-devel] [PATCH RFC 2/2] qmp: New command qom-new

2012-05-24 Thread Andreas Färber
Am 24.05.2012 14:58, schrieb Anthony Liguori: > On 05/24/2012 06:51 AM, Paolo Bonzini wrote: >> Il 24/05/2012 13:43, Markus Armbruster ha scritto: >>> Note: qdev objects (subtype of TYPE_DEVICE) created with qom-new lack >>> additional magic performed by qdev_try_create(), and almost certainly >>>

Re: [Qemu-devel] [PATCH RFC 2/2] qmp: New command qom-new

2012-05-24 Thread Anthony Liguori
On 05/24/2012 06:51 AM, Paolo Bonzini wrote: Il 24/05/2012 13:43, Markus Armbruster ha scritto: Note: qdev objects (subtype of TYPE_DEVICE) created with qom-new lack additional magic performed by qdev_try_create(), and almost certainly won't work. True. With the patches on the list, all that

Re: [Qemu-devel] [PATCH RFC 2/2] qmp: New command qom-new

2012-05-24 Thread Paolo Bonzini
Il 24/05/2012 13:43, Markus Armbruster ha scritto: > Note: qdev objects (subtype of TYPE_DEVICE) created with qom-new lack > additional magic performed by qdev_try_create(), and almost certainly > won't work. True. With the patches on the list, all that adev_try_create does is really dev->pa

[Qemu-devel] [PATCH RFC 2/2] qmp: New command qom-new

2012-05-24 Thread Markus Armbruster
To create objects via QMP. Test case: $ upstream-qemu --enable-kvm -S -m 384 -vnc :0 -monitor stdio -chardev socket,id=qmp,path=test-qmp,server=on,wait=off -mon mode=control,chardev=qmp Conversation on the qmp socket: {"QMP": {"version": {"qemu": {"micro": 93, "minor": 0, "major": 1}, "package"