From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1K4HB1-0001Xh-FD for qemu-devel@nongnu.org; Thu, 05 Jun 2008 11:14:55 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1K4HAz-0001Wv-Jf for qemu-devel@nongnu.org; Thu, 05 Jun 2008 11:14:54 -0400 Received: from [199.232.76.173] (port=53614 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1K4HAz-0001Wn-Dq for qemu-devel@nongnu.org; Thu, 05 Jun 2008 11:14:53 -0400 Received: from an-out-0708.google.com ([209.85.132.243]:35122) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1K4HAy-00070S-VV for qemu-devel@nongnu.org; Thu, 05 Jun 2008 11:14:53 -0400 Received: by an-out-0708.google.com with SMTP id d18so204076and.130 for ; Thu, 05 Jun 2008 08:14:51 -0700 (PDT) Message-ID: <484802DF.70906@codemonkey.ws> Date: Thu, 05 Jun 2008 10:14:39 -0500 From: Anthony Liguori MIME-Version: 1.0 Subject: Re: [Qemu-devel] [PATCH 3/5] Add "info uuid" command to monitor. References: <20080605083536.11678.439.stgit@gleb-debian.qumranet.com.qumranet.com> <20080605083546.11678.84071.stgit@gleb-debian.qumranet.com.qumranet.com> In-Reply-To: <20080605083546.11678.84071.stgit@gleb-debian.qumranet.com.qumranet.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Reviewed-by: Anthony Liguori Regards, Anthony Liguori Gleb Natapov wrote: > Signed-off-by: Gleb Natapov > --- > > monitor.c | 8 ++++++++ > sysemu.h | 1 + > 2 files changed, 9 insertions(+), 0 deletions(-) > > diff --git a/monitor.c b/monitor.c > index e6abcdd..9233625 100644 > --- a/monitor.c > +++ b/monitor.c > @@ -254,6 +254,12 @@ static void do_info_name(void) > term_printf("%s\n", qemu_name); > } > > +static void do_info_uuid(void) > +{ > + if (qemu_uuid_str) > + term_printf("%s\n", qemu_uuid_str); > +} > + > static void do_info_block(void) > { > bdrv_info(); > @@ -1442,6 +1448,8 @@ static term_cmd_t info_cmds[] = { > "", "show the vnc server status"}, > { "name", "", do_info_name, > "", "show the current VM name" }, > + { "uuid", "", do_info_uuid, > + "", "show the current VM UUID" }, > #if defined(TARGET_PPC) > { "cpustats", "", do_info_cpu_stats, > "", "show CPU statistics", }, > diff --git a/sysemu.h b/sysemu.h > index f666f73..474091a 100644 > --- a/sysemu.h > +++ b/sysemu.h > @@ -8,6 +8,7 @@ extern const char *bios_dir; > > extern int vm_running; > extern const char *qemu_name; > +extern const char *qemu_uuid_str; > > typedef struct vm_change_state_entry VMChangeStateEntry; > typedef void VMChangeStateHandler(void *opaque, int running); > > > >