The S390CcwMachineClass::max_threads field was only used by the s390-ccw-virtio-7.1 machine, which got removed. Remove it as now unused, simplifying the s390_init_cpus() method.
Signed-off-by: Philippe Mathieu-Daudé <[email protected]> --- include/hw/s390x/s390-virtio-ccw.h | 3 --- hw/s390x/s390-virtio-ccw.c | 7 ++----- 2 files changed, 2 insertions(+), 8 deletions(-) diff --git a/include/hw/s390x/s390-virtio-ccw.h b/include/hw/s390x/s390-virtio-ccw.h index 526078a4e2b..db804db33c3 100644 --- a/include/hw/s390x/s390-virtio-ccw.h +++ b/include/hw/s390x/s390-virtio-ccw.h @@ -49,11 +49,8 @@ static inline uint64_t s390_get_memory_limit(S390CcwMachineState *s390ms) void s390_handle_ptf(S390CPU *cpu, uint8_t r1, uintptr_t ra); struct S390CcwMachineClass { - /*< private >*/ MachineClass parent_class; - /*< public >*/ - int max_threads; bool use_cpi; }; diff --git a/hw/s390x/s390-virtio-ccw.c b/hw/s390x/s390-virtio-ccw.c index cf09b5c46e6..390d427dc41 100644 --- a/hw/s390x/s390-virtio-ccw.c +++ b/hw/s390x/s390-virtio-ccw.c @@ -75,12 +75,10 @@ out: static void s390_init_cpus(MachineState *machine) { MachineClass *mc = MACHINE_GET_CLASS(machine); - S390CcwMachineClass *s390mc = S390_CCW_MACHINE_CLASS(mc); int i; - if (machine->smp.threads > s390mc->max_threads) { - error_report("S390 does not support more than %d threads.", - s390mc->max_threads); + if (machine->smp.threads > 1) { + error_report("S390 does not support more than 1 thread."); exit(1); } @@ -779,7 +777,6 @@ static void ccw_machine_class_init(ObjectClass *oc, const void *data) S390CcwMachineClass *s390mc = S390_CCW_MACHINE_CLASS(mc); DumpSKeysInterface *dsi = DUMP_SKEYS_INTERFACE_CLASS(oc); - s390mc->max_threads = 1; s390mc->use_cpi = true; mc->reset = s390_machine_reset; mc->block_default_type = IF_VIRTIO; -- 2.51.0
