[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v11 08/11] s390x/cpu topology: add topology_capable QEMU capabili
From: |
Pierre Morel |
Subject: |
[PATCH v11 08/11] s390x/cpu topology: add topology_capable QEMU capability |
Date: |
Thu, 3 Nov 2022 18:01:47 +0100 |
S390 CPU topology is only allowed for s390-virtio-ccw-7.2 and
newer S390 machines.
Signed-off-by: Pierre Morel <pmorel@linux.ibm.com>
---
include/hw/s390x/s390-virtio-ccw.h | 1 +
hw/s390x/s390-virtio-ccw.c | 2 ++
2 files changed, 3 insertions(+)
diff --git a/include/hw/s390x/s390-virtio-ccw.h
b/include/hw/s390x/s390-virtio-ccw.h
index 6488279690..89fca3f79f 100644
--- a/include/hw/s390x/s390-virtio-ccw.h
+++ b/include/hw/s390x/s390-virtio-ccw.h
@@ -48,6 +48,7 @@ struct S390CcwMachineClass {
bool css_migration_enabled;
bool hpage_1m_allowed;
int max_threads;
+ bool topology_capable;
};
/* runtime-instrumentation allowed by the machine */
diff --git a/hw/s390x/s390-virtio-ccw.c b/hw/s390x/s390-virtio-ccw.c
index 4de2622f99..f1a9d6e793 100644
--- a/hw/s390x/s390-virtio-ccw.c
+++ b/hw/s390x/s390-virtio-ccw.c
@@ -763,6 +763,7 @@ static void ccw_machine_class_init(ObjectClass *oc, void
*data)
s390mc->css_migration_enabled = true;
s390mc->hpage_1m_allowed = true;
s390mc->max_threads = 1;
+ s390mc->topology_capable = true;
mc->init = ccw_init;
mc->reset = s390_machine_reset;
mc->block_default_type = IF_VIRTIO;
@@ -896,6 +897,7 @@ static void ccw_machine_7_1_class_options(MachineClass *mc)
ccw_machine_7_2_class_options(mc);
compat_props_add(mc->compat_props, hw_compat_7_1, hw_compat_7_1_len);
s390mc->max_threads = S390_MAX_CPUS;
+ s390mc->topology_capable = false;
}
DEFINE_CCW_MACHINE(7_1, "7.1", false);
--
2.31.1
- Re: [PATCH v11 01/11] s390x: Register TYPE_S390_CCW_MACHINE properties as class properties, (continued)
[PATCH v11 09/11] s390x/cpu topology: add topology machine property, Pierre Morel, 2022/11/03
[PATCH v11 08/11] s390x/cpu topology: add topology_capable QEMU capability,
Pierre Morel <=
[PATCH v11 07/11] target/s390x: interception of PTF instruction, Pierre Morel, 2022/11/03
[PATCH v11 05/11] s390x/cpu_topology: resetting the Topology-Change-Report, Pierre Morel, 2022/11/03
[PATCH v11 04/11] s390x/cpu topology: reporting the CPU topology to the guest, Pierre Morel, 2022/11/03