]> xenbits.xensource.com Git - people/pauldu/qemu.git/commitdiff
target/arm: Fix physical address resolution for MTE
authorRichard Henderson <richard.henderson@linaro.org>
Sat, 14 Jan 2023 03:12:13 +0000 (17:12 -1000)
committerPeter Maydell <peter.maydell@linaro.org>
Mon, 23 Jan 2023 13:32:38 +0000 (13:32 +0000)
Conversion to probe_access_full missed applying the page offset.

Fixes: b8967ddf ("target/arm: Use probe_access_full for MTE")
Resolves: https://gitlab.com/qemu-project/qemu/-/issues/1416
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-id: 20230114031213.2970349-1-richard.henderson@linaro.org
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
target/arm/mte_helper.c

index 86b37548386fbaebd836a6057b424169fb8ec93c..98bcf59c225544e10388d5ecb526a1d82915b7a2 100644 (file)
@@ -142,7 +142,7 @@ static uint8_t *allocation_tag_mem(CPUARMState *env, int ptr_mmu_idx,
      * Remember these values across the second lookup below,
      * which may invalidate this pointer via tlb resize.
      */
-    ptr_paddr = full->phys_addr;
+    ptr_paddr = full->phys_addr | (ptr & ~TARGET_PAGE_MASK);
     attrs = full->attrs;
     full = NULL;