]> www.infradead.org Git - users/dwmw2/qemu.git/commit
target/hppa: Convert hppa_cpu_init() to ResetHold handler
authorHelge Deller <deller@gmx.de>
Mon, 30 Dec 2024 11:46:47 +0000 (12:46 +0100)
committerPhilippe Mathieu-Daudé <philmd@linaro.org>
Mon, 13 Jan 2025 16:16:04 +0000 (17:16 +0100)
commitf4f4173188249d33a3ec4a0c910c168c9181ac9d
tree0cf2e7c28e5789a6fc8d1e1b7241258e667e12d1
parente4a407d2b41de8a35e2a1ecc0b9f22178ce71577
target/hppa: Convert hppa_cpu_init() to ResetHold handler

hppa_cpu_initfn() is called once when a HPPA CPU instance is
initialized, but it sets fields which should be set each time
a CPU resets. Rename it as a reset handler, having it matching
the ResettablePhases::hold() signature, and register it as
ResettableClass handler.

Since on reset the CPU registers and TLB entries are expected
to be zero, add a memset() call clearing CPUHPPAState up to
the &end_reset_fields marker.

Signed-off-by: Helge Deller <deller@gmx.de>
Co-developed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-Id: <20241231190620.24442-3-philmd@linaro.org>
target/hppa/cpu.c
target/hppa/cpu.h