diff mbox

Fix hanging user monitor when using balloon command

Message ID 1266008156.3474.18.camel@aglitke
State New
Headers show

Commit Message

Adam Litke Feb. 12, 2010, 8:55 p.m. UTC
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 call the completion callback before returning.
That call was missing but is added by the patch below.

Signed-off-by: Adam Litke <agl@us.ibm.com>

Comments

Daniel P. Berrangé Feb. 16, 2010, 1:55 p.m. UTC | #1
On Fri, Feb 12, 2010 at 02:55:56PM -0600, 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 call the completion callback before returning.
> That call was missing but is added by the patch below.
> 
> Signed-off-by: Adam Litke <agl@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;
>  }
> 
> -- 

Can we get this patch applied to GIT - without it, QEMU just
hangs under libvirt immediately, since we nearly always issue
a balloon command at start

Daniel
Anthony Liguori Feb. 19, 2010, 9:47 p.m. UTC | #2
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 call the completion callback before returning.
> That call was missing but is added by the patch below.
>
> Signed-off-by: Adam Litke<agl@us.ibm.com>
>    

Applied.  Thanks.

Regards,

Anthony Liguori
> 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;
>   }
>
>
diff mbox

Patch

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;
 }