|
|
7711c0 |
From 1170f872af13f294082e33e172e3c6e3a8995895 Mon Sep 17 00:00:00 2001
|
|
|
7711c0 |
From: Markus Armbruster <armbru@redhat.com>
|
|
|
7711c0 |
Date: Fri, 17 May 2019 06:51:02 +0200
|
|
|
7711c0 |
Subject: [PATCH 35/53] hw/mips/malta: Remove fl_sectors variable
|
|
|
7711c0 |
MIME-Version: 1.0
|
|
|
7711c0 |
Content-Type: text/plain; charset=UTF-8
|
|
|
7711c0 |
Content-Transfer-Encoding: 8bit
|
|
|
7711c0 |
|
|
|
7711c0 |
RH-Author: Markus Armbruster <armbru@redhat.com>
|
|
|
7711c0 |
Message-id: <20190517065120.12028-14-armbru@redhat.com>
|
|
|
7711c0 |
Patchwork-id: 87996
|
|
|
7711c0 |
O-Subject: [RHEL-7.7 qemu-kvm-rhev PATCH v3 13/31] hw/mips/malta: Remove fl_sectors variable
|
|
|
7711c0 |
Bugzilla: 1624009
|
|
|
7711c0 |
RH-Acked-by: Philippe Mathieu-Daudé <philmd@redhat.com>
|
|
|
7711c0 |
RH-Acked-by: Thomas Huth <thuth@redhat.com>
|
|
|
7711c0 |
RH-Acked-by: Miroslav Rezanina <mrezanin@redhat.com>
|
|
|
7711c0 |
|
|
|
7711c0 |
From: Philippe Mathieu-Daudé <philmd@redhat.com>
|
|
|
7711c0 |
|
|
|
7711c0 |
Variable fl_sectors is used just once. Since
|
|
|
7711c0 |
fl_sectors = bios_size >> 16 and bios_size = FLASH_SIZE there,
|
|
|
7711c0 |
we can simply use FLASH_SIZE >> 16, and eliminate variable.
|
|
|
7711c0 |
|
|
|
7711c0 |
Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
|
|
|
7711c0 |
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
|
|
|
7711c0 |
Signed-off-by: Markus Armbruster <armbru@redhat.com>
|
|
|
7711c0 |
Message-Id: <20190308094610.21210-12-armbru@redhat.com>
|
|
|
7711c0 |
(cherry picked from commit 5207c595eb8910eee3d329214e65d64e348985d1)
|
|
|
7711c0 |
Signed-off-by: Miroslav Rezanina <mrezanin@redhat.com>
|
|
|
7711c0 |
---
|
|
|
7711c0 |
hw/mips/mips_malta.c | 3 +--
|
|
|
7711c0 |
1 file changed, 1 insertion(+), 2 deletions(-)
|
|
|
7711c0 |
|
|
|
7711c0 |
diff --git a/hw/mips/mips_malta.c b/hw/mips/mips_malta.c
|
|
|
7711c0 |
index 7f19bdc..0566d18 100644
|
|
|
7711c0 |
--- a/hw/mips/mips_malta.c
|
|
|
7711c0 |
+++ b/hw/mips/mips_malta.c
|
|
|
7711c0 |
@@ -1003,7 +1003,6 @@ void mips_malta_init(MachineState *machine)
|
|
|
7711c0 |
DriveInfo *dinfo;
|
|
|
7711c0 |
DriveInfo *hd[MAX_IDE_BUS * MAX_IDE_DEVS];
|
|
|
7711c0 |
int fl_idx = 0;
|
|
|
7711c0 |
- int fl_sectors = bios_size >> 16;
|
|
|
7711c0 |
int be;
|
|
|
7711c0 |
|
|
|
7711c0 |
DeviceState *dev = qdev_create(NULL, TYPE_MIPS_MALTA);
|
|
|
7711c0 |
@@ -1067,7 +1066,7 @@ void mips_malta_init(MachineState *machine)
|
|
|
7711c0 |
fl = pflash_cfi01_register(FLASH_ADDRESS, NULL, "mips_malta.bios",
|
|
|
7711c0 |
BIOS_SIZE,
|
|
|
7711c0 |
dinfo ? blk_by_legacy_dinfo(dinfo) : NULL,
|
|
|
7711c0 |
- 65536, fl_sectors,
|
|
|
7711c0 |
+ 65536, FLASH_SIZE >> 16,
|
|
|
7711c0 |
4, 0x0000, 0x0000, 0x0000, 0x0000, be);
|
|
|
7711c0 |
bios = pflash_cfi01_get_memory(fl);
|
|
|
7711c0 |
fl_idx++;
|
|
|
7711c0 |
--
|
|
|
7711c0 |
1.8.3.1
|
|
|
7711c0 |
|