target/hppa: Set PC on vCPU reset

On reset:

  "The CPU begins fetching instructions from address 0xf0000004.
   This address is in PDC space."

Switch vCPUs to 32-bit mode (PSW_W bit is not set) and start
execution at address 0xf0000004.

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-6-philmd@linaro.org>
This commit is contained in:
Helge Deller 2024-12-30 12:47:52 +01:00 committed by Philippe Mathieu-Daudé
parent 3d66ec208c
commit 46f7be06c8

View File

@ -205,6 +205,7 @@ static void hppa_cpu_reset_hold(Object *obj, ResetType type)
} }
cs->exception_index = -1; cs->exception_index = -1;
cs->halted = 0; cs->halted = 0;
cpu_set_pc(cs, 0xf0000004);
memset(env, 0, offsetof(CPUHPPAState, end_reset_fields)); memset(env, 0, offsetof(CPUHPPAState, end_reset_fields));