@samitouri / QOSamiQemu / commits / 65152c2942

hw/arm/smmuv3-common: Fix incorrect reserved mask for SMMU CR0 register

The current definition of the SMMU_CR0_RESERVED mask is incorrect. It mistakenly treats bit 10 (DPT_WALK_EN) as a reserved bit while treating bit 9 (RES0) as an implemented bit. According to the SMMU architecture specification, the layout for CR0 is: | 31:11| RES0 | | 10 | DPT_WALK_EN | | 9 | RES0 | | 8:6 | VMW | | 5 | RES0 | | 4 | ATSCHK | | 3 | CMDQEN | | 2 | EVENTQEN | | 1 | PRIQEN | | 0 | SMMUEN | Signed-off-by: Tao Tang <tangtao1634@phytium.com.cn> Reviewed-by: Eric Auger <eric.auger@redhat.com> Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org> Reviewed-by: Mostafa Saleh <smostafa@google.com> Message-id: 20260304142344.3341444-2-tangtao1634@phytium.com.cn Fixes: fae4be38b35 ("hw/arm/smmuv3: Implement MMIO write operations") Link: https://lists.gnu.org/archive/html/qemu-arm/2025-06/msg00088.html Signed-off-by: Peter Maydell <peter.maydell@linaro.org>

Tao Tang committed Mar 4, 2026 at 22:23 UTC 65152c2942c388c0ea0ae9e13aaa91a35710855f
1 file changed +1 -1
include/hw/arm/smmuv3-common.h
+1 -1
@@ -355,7 +355,7 @@ REG32(CR0, 0x20)
355 FIELD(CR0, EVENTQEN, 2, 1)
356 FIELD(CR0, CMDQEN, 3, 1)
357
358 -#define SMMU_CR0_RESERVED 0xFFFFFC20
358 +#define SMMU_CR0_RESERVED 0xFFFFFA20
359
360 REG32(CR0ACK, 0x24)
361 REG32(CR1, 0x28)