Patchwork [12/25] Monitor: Move qmp_query_kvm() up in monitor.c

login
register
mail settings
Submitter Luiz Capitulino
Date Dec. 6, 2010, 6:23 p.m.
Message ID <1291659852-23028-13-git-send-email-lcapitulino@redhat.com>
Download mbox | patch
Permalink /patch/74457/
State New
Headers show

Comments

Luiz Capitulino - Dec. 6, 2010, 6:23 p.m.
So that next commit can change do_info_kvm_print() to call it.

Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
---
 monitor.c |   20 ++++++++++----------
 1 files changed, 10 insertions(+), 10 deletions(-)

Patch

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;