Re: [Qemu-devel] [PATCH 6/6] qmp: add balloon-get-memory-stats event

2012-02-09 Thread Adam Litke
.gf3fb0.dirty -- Adam Litke a...@us.ibm.com IBM Linux Technology Center

Re: [Qemu-devel] [RFC 0/5]: QMP: add balloon-get-memory-stats command

2012-01-19 Thread Adam Litke
values). In my old code, we kept a boolean flag in the ballon device to record if stats have been requested and only if that was set would we raise the event. Without this, the guest can spam the host with an unlimited number of bogus events. Tested-by: Adam Litke a...@us.ibm.com -- Adam Litke

Re: [Qemu-devel] [PATCH] build: Cleanup qga make output

2011-12-13 Thread Adam Litke
On Tue, Dec 13, 2011 at 10:23:18AM -0200, Luiz Capitulino wrote: On Mon, 12 Dec 2011 17:38:36 -0600 Michael Roth mdr...@linux.vnet.ibm.com wrote: On 12/12/2011 05:03 PM, Anthony Liguori wrote: On 12/07/2011 10:33 AM, Adam Litke wrote: Currently the make variable qapi-dir refers

Re: [Qemu-devel] [libvirt] virDomainBlockJobAbort and block_job_cancel

2011-12-08 Thread Adam Litke
On Wed, Dec 07, 2011 at 04:01:58PM -0700, Eric Blake wrote: On 12/07/2011 03:35 PM, Adam Litke wrote: Stefan's qemu tree has a block_job_cancel command that always acts asynchronously. In order to provide the synchronous behavior in libvirt (when flags is 0), I need to wait

[Qemu-devel] [PATCH] build: Cleanup qga make output

2011-12-07 Thread Adam Litke
Signed-off-by: Adam Litke a...@us.ibm.com --- Makefile |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/Makefile b/Makefile index 301c75e..7c93739 100644 --- a/Makefile +++ b/Makefile @@ -168,7 +168,7 @@ check-qjson: check-qjson.o $(qobject-obj-y) $(tools-obj-y) test

Re: [Qemu-devel] [libvirt] virDomainBlockJobAbort and block_job_cancel

2011-12-07 Thread Adam Litke
given that it basically has broken semantics as far as qemu is concerned. If this is all too nasty, we could probably just change the behavior of blockJobAbort and make it always synchronous with a 'cancelled' event. Thoughts? -- Adam Litke a...@us.ibm.com IBM Linux Technology Center

Re: [Qemu-devel] wiki summary

2011-11-18 Thread Adam Litke
. -- Adam Litke a...@us.ibm.com IBM Linux Technology Center

Re: [Qemu-devel] converging around a single guest agent

2011-11-17 Thread Adam Litke
calls in future versions of the API. What are your thoughts on this approach? -- Adam Litke a...@us.ibm.com IBM Linux Technology Center ___ Arch mailing list a...@ovirt.org http://lists.ovirt.org/mailman/listinfo/arch -- Adam

Re: [Qemu-devel] converging around a single guest agent

2011-11-16 Thread Adam Litke
calls in future versions of the API. What are your thoughts on this approach? -- Adam Litke a...@us.ibm.com IBM Linux Technology Center

Re: [Qemu-devel] [PATCH 0/4] Image Streaming API

2011-08-30 Thread Adam Litke
On Tue, Aug 30, 2011 at 10:28:09AM +0100, Stefan Hajnoczi wrote: On Tue, Aug 30, 2011 at 4:19 AM, Zhi Yong Wu zwu.ker...@gmail.com wrote: On Tue, Aug 23, 2011 at 8:58 PM, Stefan Hajnoczi stefa...@linux.vnet.ibm.com wrote: These patches put in place the image streaming QMP/HMP commands and

Re: [Qemu-devel] [PATCH 4/4] qmp: add query-block-jobs

2011-08-23 Thread Adam Litke
On Tue, 2011-08-23 at 13:58 +0100, Stefan Hajnoczi wrote: diff --git a/blockdev.c b/blockdev.c index 036b7eb..e9098f6 100644 --- a/blockdev.c +++ b/blockdev.c @@ -835,3 +835,13 @@ int do_block_job_cancel(Monitor *mon, const QDict *params, QObject **ret_data)

Re: [Qemu-devel] [PATCH 1/4] qmp: add block_stream command

2011-08-23 Thread Adam Litke
Under libvirt, I get the following error when trying to start a block stream: qerror: bad call in function 'do_block_stream': qerror: - error format '{ 'class': 'NotSupported', 'data': {} }' not found qerror: call at blockdev.c:808 2011-08-23 11:30:09.974: shutting down Is this patch missing a

Re: [Qemu-devel] [libvirt] [PATCH] qemu: Get memory balloon info correctly for text monitor

2011-08-15 Thread Adam Litke
On 08/15/2011 11:50 AM, Daniel P. Berrange wrote: On Mon, Aug 15, 2011 at 11:27:43AM -0500, Adam Litke wrote: On 08/15/2011 08:23 AM, Osier Yang wrote: 于 2011年08月15日 21:58, Osier Yang 写道: * src/qemu/qemu_monitor_text.c: BALLOON_PREFIX was defined as balloon: actual=, which cause actual

Re: [Qemu-devel] live block copy/stream/snapshot discussion

2011-07-12 Thread Adam Litke
. These operations can easily take many minutes (even hours) and such a long-running operation needs to report progress. I think the current information returned by 'query-block-stream' is appropriate for this purpose and should definitely be maintained. -- Adam Litke IBM Linux Technology Center

[Qemu-devel] Re: [RFC][PATCH v7 04/16] virtagent: bi-directional RPC handling logic

2011-03-07 Thread Adam Litke
On Mon, 2011-03-07 at 14:10 -0600, Michael Roth wrote: This implements the state machine/logic used to manage send/receive/execute phases of RPCs we send or receive. It does so using a set of abstract methods we implement with the application and transport level code which will follow.

[Qemu-devel] Re: [RFC][PATCH v7 06/16] virtagent: transport definitions

2011-03-07 Thread Adam Litke
On Mon, 2011-03-07 at 14:10 -0600, Michael Roth wrote: +#define VA_LINE_LEN_MAX 1024 +static void va_rpc_parse_hdr(VAHTState *s) +{ +int i, line_pos = 0; +bool first_line = true; +char line_buf[VA_LINE_LEN_MAX]; + +TRACE(called); + +for (i = 0; i VA_HDR_LEN_MAX; ++i)

[Qemu-devel] Re: [PATCH 1/2] Add virtagent file system freeze/thaw

2011-02-01 Thread Adam Litke
On Tue, 2011-02-01 at 11:58 +0100, jes.soren...@redhat.com wrote: +/* + * va_fsfreeze(): Walk list of mounted file systems in the guest, and + * freeze the ones which are real local file systems. + * rpc return values: Number of file systems frozen, -1 on error. + */ +static xmlrpc_value

Re: spice vdagent protocol, was Re: [Qemu-devel] KVM call minutes for Jan 11

2011-01-13 Thread Adam Litke
On Tue, 2011-01-11 at 20:33 +0200, Alon Levy wrote: Spice guest agent: - virt agent, matahari, spice agent...what is in spice agent? - spice char device - mouse, copy 'n paste, screen resolution change - could be generic (at least input and copy/paste) - send protocol details of

Re: spice vdagent protocol, was Re: [Qemu-devel] KVM call minutes for Jan 11

2011-01-13 Thread Adam Litke
On Thu, 2011-01-13 at 21:18 +0200, Alon Levy wrote: On Thu, Jan 13, 2011 at 09:01:34AM -0600, Adam Litke wrote: On Tue, 2011-01-11 at 20:33 +0200, Alon Levy wrote: Spice guest agent: - virt agent, matahari, spice agent...what is in spice agent? - spice char device - mouse

Re: [Qemu-devel] [Qestion] What status of memory stats feature

2010-12-15 Thread Adam Litke
On Wed, 2010-12-15 at 15:39 -0200, Luiz Capitulino wrote: On Wed, 15 Dec 2010 16:20:05 +0900 Ken'ichi Ohmichi oomi...@mxs.nes.nec.co.jp wrote: Hi, I tried to get the memory stats by using virDomainMemoryStats() of libvirt, but it could not do it because of the following patch:

[Qemu-devel] Re: [RFC][PATCH v5 07/21] virtagent: add va.getfile RPC

2010-12-09 Thread Adam Litke
On Wed, 2010-12-08 at 20:19 +0100, Jes Sorensen wrote: On 12/07/10 17:00, Adam Litke wrote: Hi Jes, you raise some good points and pitfalls with the current getfile approach. I've been thinking about an alternative and am wondering what you (and others) think... First off, I think we

[Qemu-devel] Re: [RFC][PATCH v5 07/21] virtagent: add va.getfile RPC

2010-12-07 Thread Adam Litke
Hi Jes, you raise some good points and pitfalls with the current getfile approach. I've been thinking about an alternative and am wondering what you (and others) think... First off, I think we should switch to a copyfile() API that allows us to avoid presenting the file contents to the user.

[Qemu-devel] Re: [RFC][PATCH v5 03/21] virtagent: common code for managing client/server rpc jobs

2010-12-06 Thread Adam Litke
On Fri, 2010-12-03 at 12:03 -0600, Michael Roth wrote: +/* create new client job and then put it on the queue. this can be + * called externally from virtagent. Since there can only be one virtagent + * instance we access state via an object-scoped global rather than pass + * it around. + *

[Qemu-devel] Re: [RFC][PATCH v5 03/21] virtagent: common code for managing client/server rpc jobs

2010-12-06 Thread Adam Litke
On Fri, 2010-12-03 at 12:03 -0600, Michael Roth wrote: +/* create new client job and then put it on the queue. this can be + * called externally from virtagent. Since there can only be one virtagent + * instance we access state via an object-scoped global rather than pass + * it around. + *

[Qemu-devel] Re: [RFC][PATCH v5 07/21] virtagent: add va.getfile RPC

2010-12-06 Thread Adam Litke
On Fri, 2010-12-03 at 12:03 -0600, Michael Roth wrote: Add RPC to retrieve a guest file. This interface is intended for smaller reads like peeking at logs and /proc and such. Signed-off-by: Michael Roth mdr...@linux.vnet.ibm.com --- virtagent-server.c | 59

[Qemu-devel] Re: [RFC][PATCH v5 08/21] virtagent: add agent_viewfile qmp/hmp command

2010-12-06 Thread Adam Litke
On Fri, 2010-12-03 at 12:03 -0600, Michael Roth wrote: Utilize the getfile RPC to provide a means to view text files in the guest. Getfile can handle binary files as well but we don't advertise that here due to the special handling requiring to store it and provide it back to the user (base64

[Qemu-devel] Re: [RFC][PATCH v5 04/21] virtagent: transport definitions and job callbacks

2010-12-06 Thread Adam Litke
On Fri, 2010-12-03 at 12:03 -0600, Michael Roth wrote: +static void va_http_send_handler(void *opaque) +{ +VAHTState *s = va_state-send_state; +enum va_http_status http_status; +int fd = va_state-fd; +int ret; + +TRACE(called, fd: %d, fd); + +switch (s-state) {

[Qemu-devel] Re: [RFC][PATCH v5 09/21] virtagent: add va.getdmesg RPC

2010-12-06 Thread Adam Litke
On Fri, 2010-12-03 at 12:03 -0600, Michael Roth wrote: +/* va_getdmesg(): return dmesg output + * rpc return values: + * - dmesg output as a string + */ +static xmlrpc_value *va_getdmesg(xmlrpc_env *env, + xmlrpc_value *param, +

[Qemu-devel] Re: [RFC][PATCH v5 19/21] virtagent: add virtagent guest daemon

2010-12-06 Thread Adam Litke
On Fri, 2010-12-03 at 12:03 -0600, Michael Roth wrote: +static void usage(const char *cmd) +{ +printf( +Usage: %s -c channel_opts\n +QEMU virtagent guest agent\n +\n + -c, --channel channel options of the form:\n +method:addr:port[:channel_id]\n + -v,

[Qemu-devel] Re: [RFC][RESEND][PATCH v1 02/15] virtproxy: qemu-vp, standalone daemon skeleton

2010-11-05 Thread Adam Litke
On Thu, 2010-11-04 at 08:57 -0500, Michael Roth wrote: This resembles vl.c's main_loop_wait() but I can see why you might want your own. There is opportunity for sharing the select logic and ioh callbacks but I think that could be addressed later. Yup these are all basically

[Qemu-devel] Re: [RFC][RESEND][PATCH v1 13/15] virtproxy: add read handler for proxied connections

2010-11-03 Thread Adam Litke
On Wed, 2010-11-03 at 10:28 -0500, Michael Roth wrote: reads data from client/server connections as they become readable, then sends the data over the channel Signed-off-by: Michael Roth mdr...@linux.vnet.ibm.com --- virtproxy.c | 80

[Qemu-devel] Re: [RFC][RESEND][PATCH v1 11/15] virtproxy: add vp_handle_packet()

2010-11-03 Thread Adam Litke
Description please. On Wed, 2010-11-03 at 10:28 -0500, Michael Roth wrote: Signed-off-by: Michael Roth mdr...@linux.vnet.ibm.com --- virtproxy.c | 23 +++ 1 files changed, 23 insertions(+), 0 deletions(-) diff --git a/virtproxy.c b/virtproxy.c index 4f56aba..5ec4e77

[Qemu-devel] Re: [RFC][RESEND][PATCH v1 09/15] virtproxy: add handler for data packets

2010-11-03 Thread Adam Litke
On Wed, 2010-11-03 at 10:28 -0500, Michael Roth wrote: Process VPPackets coming in from channel and send them to the appropriate server/client connections. Signed-off-by: Michael Roth mdr...@linux.vnet.ibm.com --- virtproxy.c | 42 ++ 1 files

[Qemu-devel] Re: [RFC][RESEND][PATCH v1 12/15] virtproxy: interfaces to set/remove VPIForwards

2010-11-03 Thread Adam Litke
Description please. On Wed, 2010-11-03 at 10:28 -0500, Michael Roth wrote: Signed-off-by: Michael Roth mdr...@linux.vnet.ibm.com --- virtproxy.c | 59 +++ virtproxy.h |2 ++ 2 files changed, 61 insertions(+), 0 deletions(-)

[Qemu-devel] Re: [RFC][RESEND][PATCH v1 04/15] virtproxy: list look-up functions conns/oforwards/iforwards

2010-11-03 Thread Adam Litke
You should describe your changes a little bit more on the top here. Looks good otherwise. On Wed, 2010-11-03 at 10:27 -0500, Michael Roth wrote: Signed-off-by: Michael Roth mdr...@linux.vnet.ibm.com --- virtproxy.c | 44 1 files changed, 44

[Qemu-devel] Re: [RFC][RESEND][PATCH v1 00/15] virtproxy: host/guest communication layer

2010-11-03 Thread Adam Litke
You've got a lot of objects interacting with one another in virtproxy. I think it would help other reviewers if you could describe the relationships between the entities such as: VPDriver, VPConn, VPChannel, VPIForward, VPOForward, etc. This patch series is really wiring a lot of things together.

[Qemu-devel] Re: [RFC][RESEND][PATCH v1 03/15] virtproxy: add debug functions for virtproxy core

2010-11-03 Thread Adam Litke
Alas, this code exists in several other places too... I guess you can't be responsible for cleaning up all of qemu :) On Wed, 2010-11-03 at 10:27 -0500, Michael Roth wrote: Signed-off-by: Michael Roth mdr...@linux.vnet.ibm.com --- virtproxy.c | 17 + 1 files changed, 17

[Qemu-devel] Re: [RFC][RESEND][PATCH v1 06/15] virtproxy: add read handler for communication channel

2010-11-03 Thread Adam Litke
On Wed, 2010-11-03 at 10:28 -0500, Michael Roth wrote: Handle data coming in over the channel as VPPackets: Process control messages and forward data from remote client/server connections to the appropriate server/client FD on our end. Signed-off-by: Michael Roth mdr...@linux.vnet.ibm.com

[Qemu-devel] Re: [RFC][RESEND][PATCH v1 02/15] virtproxy: qemu-vp, standalone daemon skeleton

2010-11-03 Thread Adam Litke
On Wed, 2010-11-03 at 10:27 -0500, Michael Roth wrote: +/* mirror qemu I/O-related code for standalone daemon */ +typedef struct IOHandlerRecord { +int fd; +IOCanReadHandler *fd_read_poll; +IOHandler *fd_read; +IOHandler *fd_write; +int deleted; +void *opaque; +

[Qemu-devel] Re: [RFC][RESEND][PATCH v1 01/15] virtproxy: base data structures and constants

2010-11-03 Thread Adam Litke
On Wed, 2010-11-03 at 10:27 -0500, Michael Roth wrote: +static QemuOptsList vp_socket_opts = { +.name = vp_socket_opts, +.head = QTAILQ_HEAD_INITIALIZER(vp_socket_opts.head), +.desc = { +{ +.name = path, +.type = QEMU_OPT_STRING, +},{ +

[Qemu-devel] Re: [RFC][RESEND][PATCH v1 07/15] virtproxy: add vp_new() VPDriver constructor

2010-11-03 Thread Adam Litke
Be more descriptive here please. On Wed, 2010-11-03 at 10:28 -0500, Michael Roth wrote: Signed-off-by: Michael Roth mdr...@linux.vnet.ibm.com --- virtproxy.c | 23 +++ virtproxy.h |3 +++ 2 files changed, 26 insertions(+), 0 deletions(-) diff --git a/virtproxy.c

[Qemu-devel] Re: [RFC][RESEND][PATCH v1 05/15] virtproxy: add accept handler for communication channel

2010-11-03 Thread Adam Litke
On Wed, 2010-11-03 at 10:28 -0500, Michael Roth wrote: This accept()'s connections to the socket we told virt-proxy to listen for the channel connection on and sets the appropriate read handler for the resulting FD. Signed-off-by: Michael Roth mdr...@linux.vnet.ibm.com --- virtproxy.c |

[Qemu-devel] Re: [RFC][RESEND][PATCH v1 09/15] virtproxy: add handler for data packets

2010-11-03 Thread Adam Litke
On Wed, 2010-11-03 at 10:28 -0500, Michael Roth wrote: Process VPPackets coming in from channel and send them to the appropriate server/client connections. Signed-off-by: Michael Roth mdr...@linux.vnet.ibm.com --- virtproxy.c | 42 ++ 1 files

Re: [Qemu-devel] [PATCH] Disable virtio-balloon memory stats interface

2010-09-14 Thread Adam Litke
On Tue, 2010-09-14 at 12:46 -0300, Luiz Capitulino wrote: On Tue, 14 Sep 2010 12:42:00 -0300 Eduardo Habkost ehabk...@redhat.com wrote: I keep my suggestion: if all we need is to change the way info balloon behaves, then we can simply change the info balloon behavior, intead of changing

Re: [Qemu-devel] [PATCH] Disable virtio-balloon memory stats interface

2010-09-14 Thread Adam Litke
Ok, I can see how this will work better for the migration case. Acked-by: Adam Litke a...@us.ibm.com On Tue, 2010-09-14 at 11:09 -0300, Eduardo Habkost wrote: This field is guest-visible, won't this cause problems on migration? Isn't it better to disable it on the info balloon side, so

[Qemu-devel] [PATCH] [For 0.13] Disable virtio-balloon memory stats interface

2010-09-08 Thread Adam Litke
-off-by: Adam Litke a...@us.ibm.com --- hw/virtio-balloon.c | 12 +++- 1 files changed, 11 insertions(+), 1 deletions(-) diff --git a/hw/virtio-balloon.c b/hw/virtio-balloon.c index 9fe3886..269bc22 100644 --- a/hw/virtio-balloon.c +++ b/hw/virtio-balloon.c @@ -190,7 +190,17 @@ static

[Qemu-devel] [PATCH] Disable virtio-balloon memory stats interface

2010-08-30 Thread Adam Litke
to handle lost or delayed responses. To fix this regression, the virtio balloon memory stats feature is being disabled in qemu-0.13. Signed-off-by: Adam Litke a...@us.ibm.com diff --git a/hw/virtio-balloon.c b/hw/virtio-balloon.c index 9fe3886..2d80382 100644 --- a/hw/virtio-balloon.c +++ b/hw

[Qemu-devel] [PATCH] balloon: Fix overflow when reporting actual memory size

2010-03-25 Thread Adam Litke
: actual=1024 Signed-off-by: Adam Litke a...@us.ibm.com --- hw/virtio-balloon.c |3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/hw/virtio-balloon.c b/hw/virtio-balloon.c index 086d9d1..6eedab1 100644 --- a/hw/virtio-balloon.c +++ b/hw/virtio-balloon.c @@ -78,7 +78,8

Re: [Qemu-devel] Ideas wiki for GSoC 2010

2010-03-12 Thread Adam Litke
Hi Luiz. Around the time when I introduced the new Asynchronous monitor command API we had talked about converting all commands to use this new API so that we can cut down on duplicate code paths and confusing code. I would like to propose this as a GSoC project idea. Do you think it should

Re: [Qemu-devel] Ideas wiki for GSoC 2010

2010-03-12 Thread Adam Litke
On Fri, 2010-03-12 at 12:22 -0300, Luiz Capitulino wrote: On Fri, 12 Mar 2010 09:11:31 -0600 Adam Litke a...@us.ibm.com wrote: Hi Luiz. Around the time when I introduced the new Asynchronous monitor command API we had talked about converting all commands to use this new API so that we

[Qemu-devel] Re: virtio: Add memory statistics reporting to the balloon driver (V8)

2010-03-09 Thread Adam Litke
On Tue, 2010-03-09 at 11:22 -0300, Luiz Capitulino wrote: On Tue, 09 Mar 2010 14:51:31 +0100 Juan Quintela quint...@redhat.com wrote: Any recompilation/etc would break migration. I have tried to understand what happened with monitor async commands, and my head exploded in indirections.

[Qemu-devel] [PATCH] balloon: Do not save VM state wrt asynchronous virtio operations

2010-03-09 Thread Adam Litke
the user monitor. Signed-off-by: Adam Litke a...@us.ibm.com diff --git a/hw/virtio-balloon.c b/hw/virtio-balloon.c index 086d9d1..6d12024 100644 --- a/hw/virtio-balloon.c +++ b/hw/virtio-balloon.c @@ -261,10 +261,6 @@ static void virtio_balloon_save(QEMUFile *f, void *opaque

Re: [Qemu-devel] [PATCH] Fix hanging user monitor when using balloon command

2010-02-26 Thread Adam Litke
On Fri, 2010-02-26 at 17:26 -0300, Luiz Capitulino wrote: This patch fixes both. One question, though: @@ -2332,6 +2331,7 @@ static int do_balloon(Monitor *mon, const QDict *params, return -1; } +cb(opaque, NULL); return 0; } Can't (or shouldn't)

Re: [Qemu-devel] [PATCH] Fix hanging user monitor when using balloon command

2010-02-22 Thread Adam Litke
On Fri, 2010-02-19 at 15:47 -0600, Anthony Liguori wrote: On 02/12/2010 02:55 PM, Adam Litke wrote: Arghh... Adding missing S-O-B Hi Anthony. I wonder if there was a problem when importing my async command handler patchset. Since the 'balloon' command completes immediately, it must

[Qemu-devel] [PATCH] Fix hanging user monitor when using balloon command

2010-02-12 Thread Adam Litke
Hi Anthony. I wonder if there was a problem when importing my async command handler patchset. Since the 'balloon' command completes immediately, it must call the completion callback before returning. That call was missing but is added by the patch below. diff --git a/monitor.c b/monitor.c index

[Qemu-devel] [PATCH] Fix hanging user monitor when using balloon command

2010-02-12 Thread Adam Litke
-off-by: Adam Litke a...@us.ibm.com diff --git a/monitor.c b/monitor.c index ae125b8..f94794d 100644 --- a/monitor.c +++ b/monitor.c @@ -2258,6 +2258,7 @@ static int do_balloon(Monitor *mon, const QDict *params, return -1; } +cb(opaque, NULL); return 0; } -- Thanks, Adam

[Qemu-devel] virtio: Add memory statistics reporting to the balloon driver (V8)

2010-01-26 Thread Adam Litke
and communicate them directly to the hypervisor. Signed-off-by: Adam Litke a...@us.ibm.com To: Anthony Liguori aligu...@us.ibm.com Cc: Avi Kivity a...@redhat.com Cc: Luiz Capitulino lcapitul...@redhat.com Cc: qemu-devel@nongnu.org diff --git a/balloon.h b/balloon.h index 60b4a5d..c3a1ad3 100644

[Qemu-devel] Re: [RFC] New API for asynchronous monitor commands

2010-01-25 Thread Adam Litke
On Mon, 2010-01-25 at 11:08 -0200, Luiz Capitulino wrote: @@ -85,11 +91,19 @@ typedef struct mon_cmd_t { union { void (*info)(Monitor *mon); void (*info_new)(Monitor *mon, QObject **ret_data); +int (*info_async)(Monitor *mon, QMPCompletion *cb, void

[Qemu-devel] [PATCH] New API for asynchronous monitor commands (V2)

2010-01-25 Thread Adam Litke
monitor.c once all commands are ported. Thanks to Anthony for helping me out with the initial design. Signed-off-by: Adam Litke a...@us.ibm.com To: Anthony Liguori anth...@codemonkey.ws cc: Luiz Capitulino lcapitul...@redhat.com Cc: Avi Kivity a...@redhat.com Cc: qemu-devel@nongnu.org diff --git

[Qemu-devel] [RFC] New API for asynchronous monitor commands

2010-01-22 Thread Adam Litke
for helping me out with the initial design. Signed-off-by: Adam Litke a...@us.ibm.com To: Anthony Liguori anth...@codemonkey.ws cc: Luiz Capitulino lcapitul...@redhat.com Cc: qemu-devel@nongnu.org diff --git a/monitor.c b/monitor.c index cadf422..c0d0fa9 100644 --- a/monitor.c +++ b/monitor.c @@ -76,6

[Qemu-devel] Re: [PATCH] QMP: Fix asynchronous events delivery

2010-01-20 Thread Adam Litke
event if the 'mon' is a QMP Monitor. The aforementioned commit was an early version, if it was applied to stable (it should) this one has to be applied there too. Signed-off-by: Luiz Capitulino lcapitul...@redhat.com Acked-by: Adam Litke a...@us.ibm.com -- Thanks, Adam

[Qemu-devel] Re: virtio: Add memory statistics reporting to the balloon driver (V7)

2010-01-18 Thread Adam Litke
On Mon, 2010-01-18 at 12:12 -0200, Luiz Capitulino wrote: On Fri, 15 Jan 2010 13:54:29 -0600 Adam Litke a...@us.ibm.com wrote: This version improves support for multiple monitors and has been ported up to HEAD as of 01/14. Overall review on the Monitor related changes seems ok

[Qemu-devel] Re: [PATCH] QMP: Save default control monitor for emitting async events

2010-01-15 Thread Adam Litke
On Fri, 2010-01-15 at 11:38 -0200, Luiz Capitulino wrote: On Thu, 14 Jan 2010 15:20:10 -0600 Adam Litke a...@us.ibm.com wrote: When using a control/QMP monitor in tandem with a regular monitor, asynchronous messages can get lost depending on the order of the QEMU program arguments

[Qemu-devel] [PATCH] QMP: Emit asynchronous events on all QMP monitors

2010-01-15 Thread Adam Litke
,default), the message will be directed to the user monitor (not the QMP monitor). Additionally, only one QMP session is currently able to receive async messages. To avoid this confusion, scan through the list of monitors and emit the message on each QMP monitor. Signed-off-by: Adam Litke

[Qemu-devel] Re: [PATCH][RESPIN] QMP: Emit asynchronous events on all QMP monitors

2010-01-15 Thread Adam Litke
,default), the message will be directed to the user monitor (not the QMP monitor). Additionally, only one QMP session is currently able to receive async messages. To avoid this confusion, scan through the list of monitors and emit the message on each QMP monitor. Signed-off-by: Adam Litke

[Qemu-devel] virtio: Add memory statistics reporting to the balloon driver (V7)

2010-01-15 Thread Adam Litke
with the host. A simpler approach is to collect memory statistics in the virtio balloon driver and communicate them directly to the hypervisor. Signed-off-by: Adam Litke a...@us.ibm.com To: Anthony Liguori aligu...@us.ibm.com Cc: Avi Kivity a...@redhat.com Cc: Luiz Capitulino lcapitul

[Qemu-devel] [PATCH] QMP: Save default control monitor for emitting async events

2010-01-14 Thread Adam Litke
,default), the message will be directed to the user monitor (not the QMP monitor). One solution is to save the default QMP session in another monitor pointer (ala cur_mon) and always direct asynchronous events to that monitor... Signed-off-by: Adam Litke a...@us.ibm.com diff --git a/monitor.c b

[Qemu-devel] Re: virtio: Add memory statistics reporting to the balloon driver (V6)

2010-01-13 Thread Adam Litke
On Wed, 2010-01-13 at 16:04 -0200, Luiz Capitulino wrote: I've tried to apply this patch to play with it, but turns out it conflicts with recent changes in hw/virtio-balloon. Ahh, I will continue my never-ending quest to stay current :) Some comments on the QMP side of the patch follows.

[Qemu-devel] virtio: Add memory statistics reporting to the balloon driver (V6)

2010-01-11 Thread Adam Litke
them directly to the hypervisor. Signed-off-by: Adam Litke a...@us.ibm.com To: Anthony Liguori aligu...@us.ibm.com Cc: Avi Kivity a...@redhat.com Cc: Luiz Capitulino lcapitul...@redhat.com Cc: Jamie Lokier ja...@shareable.org Cc: qemu-devel@nongnu.org diff --git a/balloon.h b/balloon.h index 60b4a5d

[Qemu-devel] Re: [RFD] virtio: Add memory statistics reporting to the balloon driver

2010-01-07 Thread Adam Litke
Thanks for the ideas and feedback. I will play around with #4 and see if I can hack up a prototype. On Thu, 2010-01-07 at 09:22 -0600, Anthony Liguori wrote: On 01/07/2010 09:18 AM, Avi Kivity wrote: On 01/07/2010 05:12 PM, Anthony Liguori wrote: 3) Make qemu request balloon stats

Re: [Qemu-devel] Re: [RFD] virtio: Add memory statistics reporting to the balloon driver

2010-01-07 Thread Adam Litke
On Thu, 2010-01-07 at 15:49 +, Daniel P. Berrange wrote: On Thu, Jan 07, 2010 at 09:12:10AM -0600, Anthony Liguori wrote: On 01/05/2010 11:08 AM, Adam Litke wrote: This patch has been discussed (and ACKed) in the past, but has not yet been committed due to the congestion surrounding

Re: [Qemu-devel] Planning for 0.13

2010-01-06 Thread Adam Litke
On Tue, 2010-01-05 at 06:43 -0600, Anthony Liguori wrote: Hi, I hope everyone had a happy new year! Now that we've finished the 0.12 release and most of us have had a nice break, I think it's time to start planning for the next release. 0.12 felt a bit rushed to me. I'd like to take a

[Qemu-devel] [RFD] virtio: Add memory statistics reporting to the balloon driver

2010-01-05 Thread Adam Litke
This patch has been discussed (and ACKed) in the past, but has not yet been committed due to the congestion surrounding the 0.12 release and other conflicting changes. I would like to rekindle the discussion so that I can make the necessary changes to get this merged. This patch is ported to

[Qemu-devel] [PATCH][For stable-0.12] virtio: Add memory statistics reporting to the balloon driver (V5)

2009-12-09 Thread Adam Litke
driver and communicate them directly to the hypervisor. This patch implements the qemu side of the communication channel. I will post the kernel driver modifications in-reply to this message. Signed-off-by: Adam Litke a...@us.ibm.com Cc: Anthony Liguori aligu...@us.ibm.com Cc: Avi Kivity

[Qemu-devel] [FOR 0.12] [PATCH] Updated: virtio: Add memory statistics reporting to the balloon driver (V5)

2009-12-03 Thread Adam Litke
and communicate them directly to the hypervisor. This patch implements the qemu side of the communication channel. I will post the kernel driver modifications in-reply to this message. Signed-off-by: Adam Litke a...@us.ibm.com Cc: Anthony Liguori aligu...@us.ibm.com Cc: Avi Kivity a...@redhat.com Cc: Rusty

[Qemu-devel] virtio: Add memory statistics reporting to the balloon driver (V5)

2009-12-01 Thread Adam Litke
the qemu side of the communication channel. I will post the kernel driver modifications in-reply to this message. Signed-off-by: Adam Litke a...@us.ibm.com Cc: Anthony Liguori aligu...@us.ibm.com Cc: Avi Kivity a...@redhat.com Cc: Rusty Russell ru...@rustcorp.com.au Cc: qemu-devel@nongnu.org diff

[Qemu-devel] virtio: Report new guest memory statistics pertinent to memory ballooning (V4)

2009-11-19 Thread Adam Litke
to the hypervisor. This patch implements the qemu side of the communication channel. I will post the kernel driver modifications in-reply to this message. Signed-off-by: Adam Litke a...@us.ibm.com Cc: Anthony Liguori aligu...@us.ibm.com Cc: Avi Kivity a...@redhat.com Cc: qemu-devel@nongnu.org diff

[Qemu-devel] virtio: Add memory statistics reporting to the balloon driver (V3)

2009-11-19 Thread Adam Litke
balloon driver. Signed-off-by: Adam Litke a...@us.ibm.com Cc: Rusty Russell ru...@rustcorp.com.au Cc: Anthony Liguori anth...@codemonkey.ws Cc: virtualizat...@lists.linux-foundation.org Cc: linux-ker...@vger.kernel.org diff --git a/drivers/virtio/virtio_balloon.c b/drivers/virtio/virtio_balloon.c

[Qemu-devel] Re: virtio: Report new guest memory statistics pertinent to memory ballooning (V4)

2009-11-19 Thread Adam Litke
On Thu, 2009-11-19 at 17:19 +0200, Avi Kivity wrote: On 11/19/2009 05:06 PM, Adam Litke wrote: Avi and Anthony, If you agree that I've addressed all outstanding issues, please consider this patch for inclusion. Thanks. I'd like to see this (and all other virtio-ABI-modifying

[Qemu-devel] Re: virtio: Add memory statistics reporting to the balloon driver (V3)

2009-11-19 Thread Adam Litke
On Thu, 2009-11-19 at 17:22 +0200, Avi Kivity wrote: On 11/19/2009 05:19 PM, Adam Litke wrote: Rusty and Anthony, If I've addressed all outstanding issues, please consider this patch for inclusion. Thanks. +struct virtio_balloon_stat +{ + __le16 tag; + __le64 val

[Qemu-devel] Re: virtio: Add memory statistics reporting to the balloon driver (V3)

2009-11-19 Thread Adam Litke
On Thu, 2009-11-19 at 18:13 +0200, Avi Kivity wrote: On 11/19/2009 05:58 PM, Adam Litke wrote: On Thu, 2009-11-19 at 17:22 +0200, Avi Kivity wrote: On 11/19/2009 05:19 PM, Adam Litke wrote: Rusty and Anthony, If I've addressed all outstanding issues, please consider

[Qemu-devel] virtio: Report new guest memory statistics pertinent to memory ballooning (V3)

2009-11-17 Thread Adam Litke
-by: Adam Litke a...@us.ibm.com Cc: Anthony Liguori aligu...@us.ibm.com Cc: Avi Kivity a...@redhat.com Cc: qemu-devel@nongnu.org diff --git a/balloon.h b/balloon.h index 60b4a5d..def4c56 100644 --- a/balloon.h +++ b/balloon.h @@ -16,12 +16,12 @@ #include cpu-defs.h -typedef ram_addr_t

[Qemu-devel] virtio: Add memory statistics reporting to the balloon driver (V2)

2009-11-17 Thread Adam Litke
to the hypervisor. This patch enables the guest-side support by adding stats collection and reporting to the virtio balloon driver. Signed-off-by: Adam Litke a...@us.ibm.com Cc: Rusty Russell ru...@rustcorp.com.au Cc: Anthony Liguori anth...@codemonkey.ws Cc: virtualizat...@lists.linux-foundation.org Cc: linux

[Qemu-devel] Re: virtio: Add memory statistics reporting to the balloon driver

2009-11-11 Thread Adam Litke
On Wed, 2009-11-11 at 13:13 +1030, Rusty Russell wrote: It's not laziness, it's consistency. How is actual different than free memory or any other stat? Because it's a COLLECTION of stats. For example, swap in should be swap out. Now, the current Linux implementation of

[Qemu-devel] [RFC] virtio: Report new guest memory statistics pertinent to memory ballooning (V2)

2009-11-09 Thread Adam Litke
. This patch implements the qemu side of the communication channel. I will post the kernel driver modifications in-reply to this message. Signed-off-by: Adam Litke a...@us.ibm.com Cc: Anthony Liguori aligu...@us.ibm.com Cc: Avi Kivity a...@redhat.com diff --git a/balloon.h b/balloon.h index 60b4a5d

[Qemu-devel] virtio: Add memory statistics reporting to the balloon driver

2009-11-09 Thread Adam Litke
? Signed-off-by: Adam Litke a...@us.ibm.com Cc: Rusty Russell ru...@rustcorp.com.au Cc: Anthony Liguori anth...@codemonkey.ws Cc: Avi Kivity a...@redhat.com Cc: virtualizat...@lists.linux-foundation.org Cc: linux-ker...@vger.kernel.org diff --git a/drivers/virtio/virtio_balloon.c b/drivers/virtio

Re: [Qemu-devel] [RFC] virtio: Report new guest memory statistics pertinent to memory ballooning (V2)

2009-11-09 Thread Adam Litke
On Mon, 2009-11-09 at 19:00 +, Jamie Lokier wrote: Adam Litke wrote: +s-stats.pswapin = has_feature(dev, VIRTIO_BALLOON_F_RPT_SWAP_OUT) ? + dev-stats.pswapin : -1; (etc.) Why not simply have the guest fill in the unused fields with -1

Re: [Qemu-devel] [RFC] virtio: Report new guest memory statistics pertinent to memory ballooning (V2)

2009-11-09 Thread Adam Litke
On Mon, 2009-11-09 at 19:01 +, Jamie Lokier wrote: These days, would it make more sense to emit a QJSON object? In this case the JSON object is quite human readable too. I'm not very particular on the output format since it's main consumer is likely another program. Is XML output via the

[Qemu-devel] [RFC] virtio: Report new guest memory statistics pertinent to memory ballooning

2009-11-05 Thread Adam Litke
balloon: pgmajfault=0 balloon: pgminfault=247914 balloon: memfree=987032 KB balloon: memtot=1020812 KB Is this agreeable? Thank you for your comments... Signed-off-by: Adam Litke a...@us.ibm.com diff --git a/balloon.h b/balloon.h index 60b4a5d

[Qemu-devel] virtio: Add memory statistics reporting to the balloon driver

2009-11-05 Thread Adam Litke
and communicate them to the host via the device config space. This patch enables the guest-side support by adding stats collection and reporting to the virtio balloon driver. Signed-off-by: Adam Litke a...@us.ibm.com diff --git a/drivers/virtio/virtio.c b/drivers/virtio/virtio.c