[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 01/86] numa: remove not needed check
From: |
Igor Mammedov |
Subject: |
[PATCH 01/86] numa: remove not needed check |
Date: |
Tue, 31 Dec 2019 14:02:45 +0100 |
Currently parse_numa_node() is always called from already numa
enabled context.
Drop unnecessary check if numa is supported.
Signed-off-by: Igor Mammedov <address@hidden>
Reviewed-by: Eduardo Habkost <address@hidden>
---
hw/core/numa.c | 7 +------
1 file changed, 1 insertion(+), 6 deletions(-)
diff --git a/hw/core/numa.c b/hw/core/numa.c
index e3332a9..19f082d 100644
--- a/hw/core/numa.c
+++ b/hw/core/numa.c
@@ -83,10 +83,6 @@ static void parse_numa_node(MachineState *ms,
NumaNodeOptions *node,
return;
}
- if (!mc->cpu_index_to_instance_props || !mc->get_default_cpu_node_id) {
- error_setg(errp, "NUMA is not supported by this machine-type");
- return;
- }
for (cpus = node->cpus; cpus; cpus = cpus->next) {
CpuInstanceProperties props;
if (cpus->value >= max_cpus) {
@@ -178,9 +174,8 @@ void parse_numa_distance(MachineState *ms, NumaDistOptions
*dist, Error **errp)
void set_numa_options(MachineState *ms, NumaOptions *object, Error **errp)
{
Error *err = NULL;
- MachineClass *mc = MACHINE_GET_CLASS(ms);
- if (!mc->numa_mem_supported) {
+ if (!ms->numa_state) {
error_setg(errp, "NUMA is not supported by this machine-type");
goto end;
}
--
2.7.4
- [PATCH 00/86] refactor main RAM allocation to use hostmem backend, Igor Mammedov, 2019/12/31
- [PATCH 02/86] numa: properly check if numa is supported, Igor Mammedov, 2019/12/31
- [PATCH 03/86] numa: remove deprecated -mem-path fallback to anonymous RAM, Igor Mammedov, 2019/12/31
- [PATCH 04/86] machine: introduce ram-memdev property, Igor Mammedov, 2019/12/31
- [PATCH 01/86] numa: remove not needed check,
Igor Mammedov <=
- [PATCH 05/86] machine: alias -mem-path and -mem-prealloc into memory-foo backend, Igor Mammedov, 2019/12/31
- [PATCH 06/86] machine: introduce convenience MachineState::ram, Igor Mammedov, 2019/12/31
- [PATCH 07/86] initialize MachineState::ram in NUMA case, Igor Mammedov, 2019/12/31
- [PATCH 11/86] hw:aspeed: drop warning and bogus ram_size fixup, Igor Mammedov, 2019/12/31
- [PATCH 08/86] alpha:dp264: use memdev for RAM, Igor Mammedov, 2019/12/31
- [PATCH 09/86] arm:aspeed: convert valid RAM sizes to data, Igor Mammedov, 2019/12/31
- [PATCH 10/86] arm:aspeed: actually check RAM size, Igor Mammedov, 2019/12/31
- [PATCH 12/86] arm:aspeed: use memdev for RAM, Igor Mammedov, 2019/12/31
- [PATCH 15/86] arm:digic_boards: use memdev for RAM, Igor Mammedov, 2019/12/31