git: bdaa120b3000 - main - arm64: Fix MAIR_ATTR_MASK
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Tue, 13 Jan 2026 17:00:55 UTC
The branch main has been updated by andrew:
URL: https://cgit.FreeBSD.org/src/commit/?id=bdaa120b30006d7ef841a966414795416ce93eea
commit bdaa120b30006d7ef841a966414795416ce93eea
Author: Harry Moulton <harry.moulton@arm.com>
AuthorDate: 2026-01-07 14:20:19 +0000
Commit: Andrew Turner <andrew@FreeBSD.org>
CommitDate: 2026-01-13 15:28:04 +0000
arm64: Fix MAIR_ATTR_MASK
Use the correct value when calculating the mask.
(commit message by andrew@)
Sponsored by: Arm Ltd
---
sys/arm64/include/armreg.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h
index 28dec3a40b26..138a1eff51ac 100644
--- a/sys/arm64/include/armreg.h
+++ b/sys/arm64/include/armreg.h
@@ -1982,7 +1982,7 @@
#define MAIR_EL1_CRn 10
#define MAIR_EL1_CRm 2
#define MAIR_EL1_op2 0
-#define MAIR_ATTR_MASK(idx) (UL(0xff) << ((n)* 8))
+#define MAIR_ATTR_MASK(idx) (UL(0xff) << ((idx) * 8))
#define MAIR_ATTR(attr, idx) ((attr) << ((idx) * 8))
#define MAIR_DEVICE_nGnRnE UL(0x00)
#define MAIR_DEVICE_nGnRE UL(0x04)