]> xenbits.xensource.com Git - people/pauldu/qemu.git/commitdiff
target/arm: Fix in_debug path in S1_ptw_translate
authorRichard Henderson <richard.henderson@linaro.org>
Sat, 14 Jan 2023 05:46:05 +0000 (19:46 -1000)
committerPeter Maydell <peter.maydell@linaro.org>
Mon, 23 Jan 2023 13:32:38 +0000 (13:32 +0000)
During the conversion, the test against get_phys_addr_lpae got inverted,
meaning that successful translations went to the 'failed' label.

Cc: qemu-stable@nongnu.org
Fixes: f3639a64f60 ("target/arm: Use softmmu tlbs for page table walking")
Resolves: https://gitlab.com/qemu-project/qemu/-/issues/1417
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-id: 20230114054605.2977022-1-richard.henderson@linaro.org
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
target/arm/ptw.c

index 4bda0590c7ca46458312a816ba673230eb39fe7e..57f3615a66dcb611e77d45491622251f25d80c9b 100644 (file)
@@ -238,8 +238,8 @@ static bool S1_ptw_translate(CPUARMState *env, S1Translate *ptw,
             };
             GetPhysAddrResult s2 = { };
 
-            if (!get_phys_addr_lpae(env, &s2ptw, addr, MMU_DATA_LOAD,
-                                    false, &s2, fi)) {
+            if (get_phys_addr_lpae(env, &s2ptw, addr, MMU_DATA_LOAD,
+                                   false, &s2, fi)) {
                 goto fail;
             }
             ptw->out_phys = s2.f.phys_addr;