thebeanogamer / rpms / qemu-kvm

Forked from rpms/qemu-kvm 5 months ago
Clone
Blob Blame History Raw
From 1b91244eac9251bf754626c91f7455a437f33714 Mon Sep 17 00:00:00 2001
Message-Id: <1b91244eac9251bf754626c91f7455a437f33714.1383564115.git.minovotn@redhat.com>
In-Reply-To: <5575e0aec51f40ebec46e98ec085cda053283aba.1383564115.git.minovotn@redhat.com>
References: <5575e0aec51f40ebec46e98ec085cda053283aba.1383564115.git.minovotn@redhat.com>
From: Markus Armbruster <armbru@redhat.com>
Date: Fri, 27 Sep 2013 13:31:14 +0200
Subject: [PATCH 04/14] vl: Rename *boot_devices to *boot_order, for
 consistency

RH-Author: Markus Armbruster <armbru@redhat.com>
Message-id: <1380288680-26645-5-git-send-email-armbru@redhat.com>
Patchwork-id: 54558
O-Subject: [PATCH 7.0 qemu-kvm 04/10] vl: Rename *boot_devices to *boot_order, for consistency
Bugzilla: 997817
RH-Acked-by: Paolo Bonzini <pbonzini@redhat.com>
RH-Acked-by: Laszlo Ersek <lersek@redhat.com>
RH-Acked-by: Luiz Capitulino <lcapitulino@redhat.com>

From: Markus Armbruster <armbru@redhat.com>

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>
Message-id: 1371208516-7857-5-git-send-email-armbru@redhat.com
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
(cherry picked from commit 083b79c9fea0e3842f0b2b57ff0d20ab5f57084a)
---
 include/hw/hw.h |  4 ++--
 vl.c            | 16 ++++++++--------
 2 files changed, 10 insertions(+), 10 deletions(-)

Signed-off-by: Michal Novotny <minovotn@redhat.com>
---
 include/hw/hw.h |  4 ++--
 vl.c            | 16 ++++++++--------
 2 files changed, 10 insertions(+), 10 deletions(-)

diff --git a/include/hw/hw.h b/include/hw/hw.h
index 1fb9afa..cc9f847 100644
--- a/include/hw/hw.h
+++ b/include/hw/hw.h
@@ -44,9 +44,9 @@ void qemu_unregister_reset(QEMUResetHandler *func, void *opaque);
 
 /* handler to set the boot_device order for a specific type of QEMUMachine */
 /* return 0 if success */
-typedef int QEMUBootSetHandler(void *opaque, const char *boot_devices);
+typedef int QEMUBootSetHandler(void *opaque, const char *boot_order);
 void qemu_register_boot_set(QEMUBootSetHandler *func, void *opaque);
-int qemu_boot_set(const char *boot_devices);
+int qemu_boot_set(const char *boot_order);
 
 #ifdef NEED_CPU_H
 #if TARGET_LONG_BITS == 64
diff --git a/vl.c b/vl.c
index 1c3236c..b8a8cc6 100644
--- a/vl.c
+++ b/vl.c
@@ -1106,12 +1106,12 @@ void qemu_register_boot_set(QEMUBootSetHandler *func, void *opaque)
     boot_set_opaque = opaque;
 }
 
-int qemu_boot_set(const char *boot_devices)
+int qemu_boot_set(const char *boot_order)
 {
     if (!boot_set_handler) {
         return -EINVAL;
     }
-    return boot_set_handler(boot_set_opaque, boot_devices);
+    return boot_set_handler(boot_set_opaque, boot_order);
 }
 
 static void validate_bootdevices(const char *devices)
@@ -1142,9 +1142,9 @@ static void validate_bootdevices(const char *devices)
     }
 }
 
-static void restore_boot_devices(void *opaque)
+static void restore_boot_order(void *opaque)
 {
-    char *standard_boot_devices = opaque;
+    char *normal_boot_order = opaque;
     static int first = 1;
 
     /* Restore boot order and remove ourselves after the first boot */
@@ -1153,10 +1153,10 @@ static void restore_boot_devices(void *opaque)
         return;
     }
 
-    qemu_boot_set(standard_boot_devices);
+    qemu_boot_set(normal_boot_order);
 
-    qemu_unregister_reset(restore_boot_devices, standard_boot_devices);
-    g_free(standard_boot_devices);
+    qemu_unregister_reset(restore_boot_order, normal_boot_order);
+    g_free(normal_boot_order);
 }
 
 void add_boot_device_path(int32_t bootindex, DeviceState *dev,
@@ -4046,7 +4046,7 @@ int main(int argc, char **argv, char **envp)
             validate_bootdevices(once);
             normal_boot_order = g_strdup(boot_order);
             boot_order = once;
-            qemu_register_reset(restore_boot_devices, normal_boot_order);
+            qemu_register_reset(restore_boot_order, normal_boot_order);
         }
 
         boot_menu = qemu_opt_get_bool(opts, "menu", boot_menu);
-- 
1.7.11.7