diff --git a/ArmPkg/Drivers/ArmGic/GicV3/AArch64/ArmGicV3.S b/ArmPkg/Drivers/ArmGic/GicV3/AArch64/ArmGicV3.S index c30ae76d94..f1c227f2c4 100644 --- a/ArmPkg/Drivers/ArmGic/GicV3/AArch64/ArmGicV3.S +++ b/ArmPkg/Drivers/ArmGic/GicV3/AArch64/ArmGicV3.S @@ -13,6 +13,14 @@ #include +#if !defined(__clang__) + +// +// Clang versions before v3.6 do not support the GNU extension that allows +// system registers outside of the IMPLEMENTATION DEFINED range to be specified +// using the generic notation below. However, clang knows these registers by +// their architectural names, so it has no need for these aliases anyway. +// #define ICC_SRE_EL1 S3_0_C12_C12_5 #define ICC_SRE_EL2 S3_4_C12_C9_5 #define ICC_SRE_EL3 S3_6_C12_C12_5 @@ -22,6 +30,8 @@ #define ICC_PMR_EL1 S3_0_C4_C6_0 #define ICC_BPR1_EL1 S3_0_C12_C12_3 +#endif + .text .align 2