Re: [Qemu-devel] [PATCH v3 09/21] qapi: add QMP dispatch functions

2011-06-15 Thread Michael Roth
On 06/15/2011 03:12 PM, Luiz Capitulino wrote: On Wed, 15 Jun 2011 14:45:30 -0500 Anthony Liguori wrote: On 06/15/2011 02:33 PM, Luiz Capitulino wrote: On Mon, 13 Jun 2011 21:31:14 -0500 Michael Roth wrote: +{ +const char *command; +QDict *args, *dict; +QmpCommand *cmd; +

Re: [Qemu-devel] [PATCH v3 09/21] qapi: add QMP dispatch functions

2011-06-15 Thread Luiz Capitulino
On Wed, 15 Jun 2011 15:45:20 -0500 Michael Roth wrote: > On 06/15/2011 03:12 PM, Luiz Capitulino wrote: > > On Wed, 15 Jun 2011 14:45:30 -0500 > > Anthony Liguori wrote: > > > >> On 06/15/2011 02:33 PM, Luiz Capitulino wrote: > >>> On Mon, 13 Jun 2011 21:31:14 -0500 > >>> Michael Roth wrote: >

Re: [Qemu-devel] [PATCH v3 09/21] qapi: add QMP dispatch functions

2011-06-15 Thread Luiz Capitulino
On Wed, 15 Jun 2011 14:45:30 -0500 Anthony Liguori wrote: > On 06/15/2011 02:33 PM, Luiz Capitulino wrote: > > On Mon, 13 Jun 2011 21:31:14 -0500 > > Michael Roth wrote: > > > > > >> +{ > >> +const char *command; > >> +QDict *args, *dict; > >> +QmpCommand *cmd; > >> +QObject *ret

Re: [Qemu-devel] [PATCH v3 09/21] qapi: add QMP dispatch functions

2011-06-15 Thread Anthony Liguori
On 06/15/2011 02:33 PM, Luiz Capitulino wrote: On Mon, 13 Jun 2011 21:31:14 -0500 Michael Roth wrote: +{ +const char *command; +QDict *args, *dict; +QmpCommand *cmd; +QObject *ret = NULL; + +if (qobject_type(request) != QTYPE_QDICT) { +error_set(errp, QERR_JSON_PAR

Re: [Qemu-devel] [PATCH v3 09/21] qapi: add QMP dispatch functions

2011-06-15 Thread Luiz Capitulino
On Mon, 13 Jun 2011 21:31:14 -0500 Michael Roth wrote: > Given an object recieved via QMP, this code uses the dispatch table > provided by qmp_registry.c to call the corresponding marshalling/dispatch > function and format return values/errors for delivery to the QMP. > Currently only synchronous

[Qemu-devel] [PATCH v3 09/21] qapi: add QMP dispatch functions

2011-06-13 Thread Michael Roth
Given an object recieved via QMP, this code uses the dispatch table provided by qmp_registry.c to call the corresponding marshalling/dispatch function and format return values/errors for delivery to the QMP. Currently only synchronous QMP functions are supported, but this will also be used for asyn