qemu-s390x
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v11 08/11] s390x/cpu topology: add topology_capable QEMU capa


From: Cédric Le Goater
Subject: Re: [PATCH v11 08/11] s390x/cpu topology: add topology_capable QEMU capability
Date: Tue, 15 Nov 2022 14:27:00 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.4.1

On 11/3/22 18:01, Pierre Morel wrote:
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>

Reviewed-by: Cédric Le Goater <clg@kaod.org>

Thanks,

C.

---
  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);




reply via email to

[Prev in Thread] Current Thread [Next in Thread]