9ae3a8
From 478b5f940bb1898c2bdc8dce560f82da3b55e78f Mon Sep 17 00:00:00 2001
9ae3a8
From: Michael S. Tsirkin <mst@redhat.com>
9ae3a8
Date: Wed, 12 Mar 2014 07:00:11 +0100
9ae3a8
Subject: [PATCH 09/16] loader: rename in_ram/has_mr
9ae3a8
9ae3a8
Message-id: <1394390868-24135-1-git-send-email-mst@redhat.com>
9ae3a8
Patchwork-id: 58053
9ae3a8
O-Subject: [PATCH qemu-kvm RHEL7.0 v3 1/2] loader: rename in_ram/has_mr
9ae3a8
Bugzilla: 1064018
9ae3a8
RH-Acked-by: Paolo Bonzini <pbonzini@redhat.com>
9ae3a8
RH-Acked-by: Marcel Apfelbaum <marcel.a@redhat.com>
9ae3a8
RH-Acked-by: Gerd Hoffmann <kraxel@redhat.com>
9ae3a8
9ae3a8
we put copy of ROMs in MR for migration.
9ae3a8
but the name rom_in_ram makes one think we
9ae3a8
load it in guest RAM.
9ae3a8
Rename has_mr to make intent clearer.
9ae3a8
9ae3a8
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
9ae3a8
9ae3a8
Upstream: posted
9ae3a8
Brew build: http://brewweb.devel.redhat.com/brew/taskinfo?taskID=7173355
9ae3a8
Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1064018#c6
9ae3a8
Tested: by developer
9ae3a8
---
9ae3a8
 include/hw/loader.h | 2 +-
9ae3a8
 hw/core/loader.c    | 6 +++---
9ae3a8
 hw/i386/pc_piix.c   | 2 +-
9ae3a8
 3 files changed, 5 insertions(+), 5 deletions(-)
9ae3a8
9ae3a8
Signed-off-by: Miroslav Rezanina <mrezanin@redhat.com>
9ae3a8
---
9ae3a8
 hw/core/loader.c    |    6 +++---
9ae3a8
 hw/i386/pc_piix.c   |    2 +-
9ae3a8
 include/hw/loader.h |    2 +-
9ae3a8
 3 files changed, 5 insertions(+), 5 deletions(-)
9ae3a8
9ae3a8
diff --git a/hw/core/loader.c b/hw/core/loader.c
9ae3a8
index 4e72e01..c363aef 100644
9ae3a8
--- a/hw/core/loader.c
9ae3a8
+++ b/hw/core/loader.c
9ae3a8
@@ -54,7 +54,7 @@
9ae3a8
 
9ae3a8
 #include <zlib.h>
9ae3a8
 
9ae3a8
-bool rom_file_in_ram = true;
9ae3a8
+bool rom_file_has_mr = true;
9ae3a8
 
9ae3a8
 static int roms_loaded;
9ae3a8
 
9ae3a8
@@ -642,7 +642,7 @@ int rom_add_file(const char *file, const char *fw_dir,
9ae3a8
                  basename);
9ae3a8
         snprintf(devpath, sizeof(devpath), "/rom@%s", fw_file_name);
9ae3a8
 
9ae3a8
-        if (rom_file_in_ram) {
9ae3a8
+        if (rom_file_has_mr) {
9ae3a8
             data = rom_set_mr(rom, devpath);
9ae3a8
         } else {
9ae3a8
             data = rom->data;
9ae3a8
@@ -686,7 +686,7 @@ void *rom_add_blob(const char *name, const void *blob, size_t len,
9ae3a8
 
9ae3a8
         snprintf(devpath, sizeof(devpath), "/rom@%s", fw_file_name);
9ae3a8
 
9ae3a8
-        if (rom_file_in_ram) {
9ae3a8
+        if (rom_file_has_mr) {
9ae3a8
             data = rom_set_mr(rom, devpath);
9ae3a8
         } else {
9ae3a8
             data = rom->data;
9ae3a8
diff --git a/hw/i386/pc_piix.c b/hw/i386/pc_piix.c
9ae3a8
index 6773fff..be68098 100644
9ae3a8
--- a/hw/i386/pc_piix.c
9ae3a8
+++ b/hw/i386/pc_piix.c
9ae3a8
@@ -948,7 +948,7 @@ static void pc_compat_rhel650(QEMUMachineInitArgs *args)
9ae3a8
 
9ae3a8
     disable_kvm_pv_unhalt();
9ae3a8
 
9ae3a8
-    rom_file_in_ram = false; 
9ae3a8
+    rom_file_has_mr = false; 
9ae3a8
     has_acpi_build = false;
9ae3a8
     gigabyte_align = false;
9ae3a8
 }
9ae3a8
diff --git a/include/hw/loader.h b/include/hw/loader.h
9ae3a8
index 50a017b..7ceccce 100644
9ae3a8
--- a/include/hw/loader.h
9ae3a8
+++ b/include/hw/loader.h
9ae3a8
@@ -23,7 +23,7 @@ void pstrcpy_targphys(const char *name,
9ae3a8
                       hwaddr dest, int buf_size,
9ae3a8
                       const char *source);
9ae3a8
 
9ae3a8
-extern bool rom_file_in_ram;
9ae3a8
+extern bool rom_file_has_mr;
9ae3a8
 
9ae3a8
 int rom_add_file(const char *file, const char *fw_dir,
9ae3a8
                  hwaddr addr, int32_t bootindex);
9ae3a8
-- 
9ae3a8
1.7.1
9ae3a8