[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 28/28] machine: reject -smp dies!=1 for non-PC machines
From: |
Paolo Bonzini |
Subject: |
[PULL 28/28] machine: reject -smp dies!=1 for non-PC machines |
Date: |
Fri, 25 Jun 2021 16:18:22 +0200 |
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Message-Id: <20210617155308.928754-11-pbonzini@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
hw/core/machine.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/hw/core/machine.c b/hw/core/machine.c
index 9ad8341a31..ffc076ae84 100644
--- a/hw/core/machine.c
+++ b/hw/core/machine.c
@@ -746,6 +746,10 @@ static void smp_parse(MachineState *ms, SMPConfiguration
*config, Error **errp)
unsigned cores = config->has_cores ? config->cores : 0;
unsigned threads = config->has_threads ? config->threads : 0;
+ if (config->has_dies && config->dies != 0 && config->dies != 1) {
+ error_setg(errp, "dies not supported by this machine's CPU topology");
+ }
+
/* compute missing values, prefer sockets over cores over threads */
if (cpus == 0 || sockets == 0) {
cores = cores > 0 ? cores : 1;
--
2.31.1
- [PULL 18/28] file-posix: try BLKSECTGET on block devices too, do not round to power of 2, (continued)
- [PULL 18/28] file-posix: try BLKSECTGET on block devices too, do not round to power of 2, Paolo Bonzini, 2021/06/25
- [PULL 19/28] block: feature detection for host block support, Paolo Bonzini, 2021/06/25
- [PULL 21/28] block: try BSD disk size ioctls one after another, Paolo Bonzini, 2021/06/25
- [PULL 20/28] block: check for sys/disk.h, Paolo Bonzini, 2021/06/25
- [PULL 22/28] block: detect DKIOCGETBLOCKCOUNT/SIZE before use, Paolo Bonzini, 2021/06/25
- [PULL 23/28] file-posix: handle EINTR during ioctl, Paolo Bonzini, 2021/06/25
- [PULL 25/28] machine: move common smp_parse code to caller, Paolo Bonzini, 2021/06/25
- [PULL 26/28] machine: add error propagation to mc->smp_parse, Paolo Bonzini, 2021/06/25
- [PULL 24/28] machine: move dies from X86MachineState to CpuTopology, Paolo Bonzini, 2021/06/25
- [PULL 27/28] machine: pass QAPI struct to mc->smp_parse, Paolo Bonzini, 2021/06/25
- [PULL 28/28] machine: reject -smp dies!=1 for non-PC machines,
Paolo Bonzini <=
- Re: [PULL v2 00/28] Misc (including block file-posix) for 2021-06-23, Peter Maydell, 2021/06/29