From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:60970) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SfnnO-0001ZU-M3 for qemu-devel@nongnu.org; Sat, 16 Jun 2012 03:51:48 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SfnnM-0004tF-No for qemu-devel@nongnu.org; Sat, 16 Jun 2012 03:51:46 -0400 Received: from mx1.redhat.com ([209.132.183.28]:42582) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SfnnM-0004t1-Fc for qemu-devel@nongnu.org; Sat, 16 Jun 2012 03:51:44 -0400 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id q5G7pgBf025384 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Sat, 16 Jun 2012 03:51:42 -0400 Message-ID: <4FDC3B07.5090603@redhat.com> Date: Sat, 16 Jun 2012 09:51:35 +0200 From: Michal Privoznik MIME-Version: 1.0 References: <4FDB6E04.9000201@redhat.com> In-Reply-To: <4FDB6E04.9000201@redhat.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [libvirt] [PATCH 2/2] qemu_agent: Wait for events instead of agent response List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Eric Blake Cc: libvir-list@redhat.com, qemu-devel@nongnu.org On 15.06.2012 19:16, Eric Blake wrote: > On 06/15/2012 10:10 AM, Michal Privoznik wrote: >> With latest changes to qemu-ga success on some commands is not reported >> anymore, e.g. guest-shutdown or guest-suspend-*. However, errors are >> still being reported. Therefore, we need to find different source of >> indication if operation was successful. Events. >> --- >> src/qemu/qemu_agent.c | 49 ++++++++++++++++++++++++++++++++++++++++++---- >> src/qemu/qemu_agent.h | 9 ++++++++ >> src/qemu/qemu_process.c | 7 ++++++ >> 3 files changed, 60 insertions(+), 5 deletions(-) >> > >> @@ -1238,6 +1257,24 @@ error: >> return NULL; >> } >> >> +void qemuAgentNotifyEvent(qemuAgentPtr mon, >> + qemuAgentEvent event) >> +{ >> + VIR_DEBUG("mon=%p event=%d", mon, event); >> + if (mon->await_event == event) { >> + VIR_DEBUG("Wakening up a tragedian"); > > s/Wakening/Waking/ > > ACK. > > Fixed and pushed. Thanks. Michal