Received: from [140.186.70.92] (port=39173 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PPg4j-00067G-2u for qemu-devel@nongnu.org; Mon, 06 Dec 2010 13:46:14 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PPg4i-0002uw-4H for qemu-devel@nongnu.org; Mon, 06 Dec 2010 13:46:12 -0500 Received: from mx1.redhat.com ([209.132.183.28]:63815) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PPg4h-0002up-RP for qemu-devel@nongnu.org; Mon, 06 Dec 2010 13:46:12 -0500 From: Luiz Capitulino Date: Mon, 6 Dec 2010 16:23:59 -0200 Message-Id: <1291659852-23028-13-git-send-email-lcapitulino@redhat.com> In-Reply-To: <1291659852-23028-1-git-send-email-lcapitulino@redhat.com> References: <1291659852-23028-1-git-send-email-lcapitulino@redhat.com> Subject: [Qemu-devel] [PATCH 12/25] Monitor: Move qmp_query_kvm() up in monitor.c List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: aliguori@us.ibm.com, armbru@redhat.com So that next commit can change do_info_kvm_print() to call it. Signed-off-by: Luiz Capitulino --- monitor.c | 20 ++++++++++---------- 1 files changed, 10 insertions(+), 10 deletions(-) diff --git a/monitor.c b/monitor.c index 1fbe78b..e8f0562 100644 --- a/monitor.c +++ b/monitor.c @@ -1994,6 +1994,16 @@ static void tlb_info(Monitor *mon) #endif +static void qmp_query_kvm(Monitor *mon, QObject **ret_data) +{ +#ifdef CONFIG_KVM + *ret_data = qobject_from_jsonf("{ 'enabled': %i, 'present': true }", + kvm_enabled()); +#else + *ret_data = qobject_from_jsonf("{ 'enabled': false, 'present': false }"); +#endif +} + static void do_info_kvm_print(Monitor *mon, const QObject *data) { QDict *qdict; @@ -2009,16 +2019,6 @@ static void do_info_kvm_print(Monitor *mon, const QObject *data) } } -static void qmp_query_kvm(Monitor *mon, QObject **ret_data) -{ -#ifdef CONFIG_KVM - *ret_data = qobject_from_jsonf("{ 'enabled': %i, 'present': true }", - kvm_enabled()); -#else - *ret_data = qobject_from_jsonf("{ 'enabled': false, 'present': false }"); -#endif -} - static void do_info_numa(Monitor *mon) { int i; -- 1.7.3.3.398.g0b0cd