cf7f61d13f
Convert the s390 CPU to the Resettable interface. This is slightly more involved than the other CPU types were (see commits 9130cade5fc22..d66e64dd006df) because S390 has its own set of different kinds of reset with different behaviours that it needs to trigger. We handle this by adding these reset types to the Resettable ResetType enum. Now instead of having an underlying implementation of reset that is s390-specific and which might be called either directly or via the DeviceClass::reset method, we can implement only the Resettable hold phase method, and have the places that need to trigger an s390-specific reset type do so by calling resettable_reset(). The other option would have been to smuggle in the s390 reset type via, for instance, a field in the CPU state that we set in s390_do_cpu_initial_reset() etc and then examined in the reset method, but doing it this way seems cleaner. The motivation for this change is that this is the last caller of the legacy device_class_set_parent_reset() function, and removing that will let us clean up some glue code that we added for the transition to three-phase reset. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Nina Schoetterl-Glausch <nsg@linux.ibm.com> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Acked-by: Thomas Huth <thuth@redhat.com> Message-id: 20240830145812.1967042-4-peter.maydell@linaro.org |
||
---|---|---|
.. | ||
kvm | ||
tcg | ||
arch_dump.c | ||
cpu_features_def.h | ||
cpu_features_def.h.inc | ||
cpu_features.c | ||
cpu_features.h | ||
cpu_models_sysemu.c | ||
cpu_models_user.c | ||
cpu_models.c | ||
cpu_models.h | ||
cpu-dump.c | ||
cpu-param.h | ||
cpu-qom.h | ||
cpu-sysemu.c | ||
cpu.c | ||
cpu.h | ||
diag.c | ||
gdbstub.c | ||
gen-features.c | ||
helper.c | ||
helper.h | ||
interrupt.c | ||
ioinst.c | ||
Kconfig | ||
machine.c | ||
meson.build | ||
mmu_helper.c | ||
s390x-internal.h | ||
sigp.c | ||
trace-events | ||
trace.h |