]> git.ipfire.org Git - thirdparty/qemu.git/commitdiff
hw/xtensa/xtfpga: Have xtfpga_init() only initialize MMU
authorPhilippe Mathieu-Daudé <philmd@linaro.org>
Tue, 26 Aug 2025 14:16:30 +0000 (16:16 +0200)
committerPhilippe Mathieu-Daudé <philmd@linaro.org>
Mon, 13 Oct 2025 19:00:09 +0000 (21:00 +0200)
cpu_reset() should not be used with an unrealized CPU.
Here we simply want to initialize the MMU, not the CPU,
so just call reset_mmu().

Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Max Filippov <jcmvbkbc@gmail.com>
Message-Id: <20250925013513.67780-1-philmd@linaro.org>

hw/xtensa/xtfpga.c

index 6efffae466b8d66721cf39ee37e60dd2bfc0aadb..55de1a7a073c1b858d15931711d8a5d188717a11 100644 (file)
@@ -268,7 +268,7 @@ static void xtfpga_init(const XtfpgaBoardDesc *board, MachineState *machine)
         /* Need MMU initialized prior to ELF loading,
          * so that ELF gets loaded into virtual addresses
          */
-        cpu_reset(CPU(cpu));
+        reset_mmu(cenv);
     }
     if (smp_cpus > 1) {
         extints = xtensa_mx_pic_get_extints(mx_pic);