[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PULL 21/29] numa: remove no longer need numa_post_machine_
From: |
Eduardo Habkost |
Subject: |
[Qemu-devel] [PULL 21/29] numa: remove no longer need numa_post_machine_init() |
Date: |
Thu, 11 May 2017 16:18:35 -0300 |
From: Igor Mammedov <address@hidden>
CPUState::numa_node is still in use but now it's set by
board when it creates CPU objects. So there isn't any
need to set it again after all CPU's are created,
since it's been already set.
Signed-off-by: Igor Mammedov <address@hidden>
Reviewed-by: David Gibson <address@hidden>
Reviewed-by: Andrew Jones <address@hidden>
Message-Id: <address@hidden>
Signed-off-by: Eduardo Habkost <address@hidden>
---
include/sysemu/numa.h | 6 ------
numa.c | 15 ---------------
vl.c | 2 --
3 files changed, 23 deletions(-)
diff --git a/include/sysemu/numa.h b/include/sysemu/numa.h
index 027830cf7e..8cb3ebc233 100644
--- a/include/sysemu/numa.h
+++ b/include/sysemu/numa.h
@@ -27,7 +27,6 @@ struct node_info {
extern NodeInfo numa_info[MAX_NODES];
void parse_numa_opts(MachineState *ms);
-void numa_post_machine_init(void);
void query_numa_node_mem(uint64_t node_mem[]);
extern QemuOptsList qemu_numa_opts;
void numa_set_mem_node_id(ram_addr_t addr, uint64_t size, uint32_t node);
@@ -37,9 +36,4 @@ void numa_legacy_auto_assign_ram(MachineClass *mc, NodeInfo
*nodes,
int nb_nodes, ram_addr_t size);
void numa_default_auto_assign_ram(MachineClass *mc, NodeInfo *nodes,
int nb_nodes, ram_addr_t size);
-
-
-/* on success returns node index in numa_info,
- * on failure returns nb_numa_nodes */
-int numa_get_node_for_cpu(int idx);
#endif
diff --git a/numa.c b/numa.c
index f16a6a8ade..dc739eadfa 100644
--- a/numa.c
+++ b/numa.c
@@ -572,21 +572,6 @@ void parse_numa_opts(MachineState *ms)
}
}
-void numa_post_machine_init(void)
-{
- CPUState *cpu;
- int i;
-
- CPU_FOREACH(cpu) {
- for (i = 0; i < nb_numa_nodes; i++) {
- assert(cpu->cpu_index < max_cpus);
- if (test_bit(cpu->cpu_index, numa_info[i].node_cpu)) {
- cpu->numa_node = i;
- }
- }
- }
-}
-
static void allocate_system_memory_nonnuma(MemoryRegion *mr, Object *owner,
const char *name,
uint64_t ram_size)
diff --git a/vl.c b/vl.c
index c4705b3335..5cd0c17ba0 100644
--- a/vl.c
+++ b/vl.c
@@ -4592,8 +4592,6 @@ int main(int argc, char **argv, char **envp)
cpu_synchronize_all_post_init();
- numa_post_machine_init();
-
rom_reset_order_override();
/*
--
2.11.0.259.g40922b1
- [Qemu-devel] [PULL 10/29] spapr: add node-id property to sPAPR core, (continued)
- [Qemu-devel] [PULL 10/29] spapr: add node-id property to sPAPR core, Eduardo Habkost, 2017/05/11
- [Qemu-devel] [PULL 12/29] virt-arm: add node-id property to CPU, Eduardo Habkost, 2017/05/11
- [Qemu-devel] [PULL 13/29] numa: add check that board supports cpu_index to node mapping, Eduardo Habkost, 2017/05/11
- [Qemu-devel] [PULL 14/29] numa: mirror cpu to node mapping in MachineState::possible_cpus, Eduardo Habkost, 2017/05/11
- [Qemu-devel] [PULL 15/29] numa: do default mapping based on possible_cpus instead of node_cpu bitmaps, Eduardo Habkost, 2017/05/11
- [Qemu-devel] [PULL 16/29] pc: get numa node mapping from possible_cpus instead of numa_get_node_for_cpu(), Eduardo Habkost, 2017/05/11
- [Qemu-devel] [PULL 17/29] spapr: get numa node mapping from possible_cpus instead of numa_get_node_for_cpu(), Eduardo Habkost, 2017/05/11
- [Qemu-devel] [PULL 18/29] virt-arm: get numa node mapping from possible_cpus instead of numa_get_node_for_cpu(), Eduardo Habkost, 2017/05/11
- [Qemu-devel] [PULL 19/29] QMP: include CpuInstanceProperties into query_cpus output output, Eduardo Habkost, 2017/05/11
- [Qemu-devel] [PULL 20/29] tests: numa: add case for QMP command query-cpus, Eduardo Habkost, 2017/05/11
- [Qemu-devel] [PULL 21/29] numa: remove no longer need numa_post_machine_init(),
Eduardo Habkost <=
- [Qemu-devel] [PULL 22/29] machine: call machine init from wrapper, Eduardo Habkost, 2017/05/11
- [Qemu-devel] [PULL 23/29] numa: use possible_cpus for not mapped CPUs check, Eduardo Habkost, 2017/05/11
- [Qemu-devel] [PULL 24/29] numa: remove node_cpu bitmaps as they are no longer used, Eduardo Habkost, 2017/05/11
- [Qemu-devel] [PULL 25/29] numa: add '-numa cpu, ...' option for property based node mapping, Eduardo Habkost, 2017/05/11
- [Qemu-devel] [PULL 26/29] tests: check -numa node, cpu=props_list usecase, Eduardo Habkost, 2017/05/11
- [Qemu-devel] [PULL 27/29] migration/i386: Remove old non-softfloat 64bit FP support, Eduardo Habkost, 2017/05/11
- [Qemu-devel] [PULL 28/29] vmstatification: i386 FPReg, Eduardo Habkost, 2017/05/11
- [Qemu-devel] [PULL 29/29] migration/i386: Remove support for pre-0.12 formats, Eduardo Habkost, 2017/05/11