[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PULL 08/12] machine: rename MemoryHotplugState to DeviceMe
From: |
Eduardo Habkost |
Subject: |
[Qemu-devel] [PULL 08/12] machine: rename MemoryHotplugState to DeviceMemoryState |
Date: |
Mon, 7 May 2018 14:03:11 -0300 |
From: David Hildenbrand <address@hidden>
Rename it to better match the new terminology.
Signed-off-by: David Hildenbrand <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Eduardo Habkost <address@hidden>
---
include/hw/boards.h | 8 ++++----
hw/ppc/spapr_hcall.c | 6 +++---
hw/ppc/spapr_rtas_ddw.c | 5 ++---
3 files changed, 9 insertions(+), 10 deletions(-)
diff --git a/include/hw/boards.h b/include/hw/boards.h
index e27c28b514..ef7457f5dd 100644
--- a/include/hw/boards.h
+++ b/include/hw/boards.h
@@ -214,15 +214,15 @@ struct MachineClass {
};
/**
- * MemoryHotplugState:
+ * DeviceMemoryState:
* @base: address in guest physical address space where the memory
* address space for memory devices starts
* @mr: address space container for memory devices
*/
-typedef struct MemoryHotplugState {
+typedef struct DeviceMemoryState {
hwaddr base;
MemoryRegion mr;
-} MemoryHotplugState;
+} DeviceMemoryState;
/**
* MachineState:
@@ -254,7 +254,7 @@ struct MachineState {
bool enforce_config_section;
bool enable_graphics;
char *memory_encryption;
- MemoryHotplugState *device_memory;
+ DeviceMemoryState *device_memory;
ram_addr_t ram_size;
ram_addr_t maxram_size;
diff --git a/hw/ppc/spapr_hcall.c b/hw/ppc/spapr_hcall.c
index 52b8f40955..022f6d8101 100644
--- a/hw/ppc/spapr_hcall.c
+++ b/hw/ppc/spapr_hcall.c
@@ -67,13 +67,13 @@ static inline bool valid_ptex(PowerPCCPU *cpu, target_ulong
ptex)
static bool is_ram_address(sPAPRMachineState *spapr, hwaddr addr)
{
MachineState *machine = MACHINE(spapr);
- MemoryHotplugState *hpms = machine->device_memory;
+ DeviceMemoryState *dms = machine->device_memory;
if (addr < machine->ram_size) {
return true;
}
- if ((addr >= hpms->base)
- && ((addr - hpms->base) < memory_region_size(&hpms->mr))) {
+ if ((addr >= dms->base)
+ && ((addr - dms->base) < memory_region_size(&dms->mr))) {
return true;
}
diff --git a/hw/ppc/spapr_rtas_ddw.c b/hw/ppc/spapr_rtas_ddw.c
index d3666c1921..329feb148f 100644
--- a/hw/ppc/spapr_rtas_ddw.c
+++ b/hw/ppc/spapr_rtas_ddw.c
@@ -122,9 +122,8 @@ static void rtas_ibm_query_pe_dma_window(PowerPCCPU *cpu,
if (machine->ram_size == machine->maxram_size) {
max_window_size = machine->ram_size;
} else {
- MemoryHotplugState *hpms = machine->device_memory;
-
- max_window_size = hpms->base + memory_region_size(&hpms->mr);
+ max_window_size = machine->device_memory->base +
+ memory_region_size(&machine->device_memory->mr);
}
avail = SPAPR_PCI_DMA_MAX_WINDOWS - spapr_phb_get_active_win_num(sphb);
--
2.14.3
- [Qemu-devel] [PULL 00/12] Machine queue, 2018-05-07, Eduardo Habkost, 2018/05/07
- [Qemu-devel] [PULL 01/12] pc-dimm: factor out MemoryDevice interface, Eduardo Habkost, 2018/05/07
- [Qemu-devel] [PULL 02/12] machine: make MemoryHotplugState accessible via the machine, Eduardo Habkost, 2018/05/07
- [Qemu-devel] [PULL 04/12] pc-dimm: pass in the machine and to the MemoryHotplugState, Eduardo Habkost, 2018/05/07
- [Qemu-devel] [PULL 03/12] pc-dimm: no need to pass the memory region, Eduardo Habkost, 2018/05/07
- [Qemu-devel] [PULL 06/12] pc-dimm: factor out capacity and slot checks into MemoryDevice, Eduardo Habkost, 2018/05/07
- [Qemu-devel] [PULL 05/12] pc-dimm: factor out address search into MemoryDevice code, Eduardo Habkost, 2018/05/07
- [Qemu-devel] [PULL 07/12] pc-dimm: move actual plug/unplug of a memory region to MemoryDevice, Eduardo Habkost, 2018/05/07
- [Qemu-devel] [PULL 08/12] machine: rename MemoryHotplugState to DeviceMemoryState,
Eduardo Habkost <=
- [Qemu-devel] [PULL 09/12] pc: rename "hotplug memory" terminology to "device memory", Eduardo Habkost, 2018/05/07
- [Qemu-devel] [PULL 10/12] spapr: rename "hotplug memory" terminology to "device memory", Eduardo Habkost, 2018/05/07
- [Qemu-devel] [PULL 12/12] scripts/device-crash-test: Removed fixed CAN entries, Eduardo Habkost, 2018/05/07
- [Qemu-devel] [PULL 11/12] vl: allow 'maxmem' without 'slot', Eduardo Habkost, 2018/05/07
- Re: [Qemu-devel] [PULL 00/12] Machine queue, 2018-05-07, Peter Maydell, 2018/05/08