Merge "fix(cm): remove ENABLE_FEAT_MTE usage" into integration
diff --git a/include/lib/el3_runtime/context_el2.h b/include/lib/el3_runtime/context_el2.h
index 4ad9634..04f6587 100644
--- a/include/lib/el3_runtime/context_el2.h
+++ b/include/lib/el3_runtime/context_el2.h
@@ -49,9 +49,9 @@
 	uint64_t vttbr_el2;
 } el2_common_regs_t;
 
-typedef struct el2_mte_regs {
+typedef struct el2_mte2_regs {
 	uint64_t tfsr_el2;
-} el2_mte_regs_t;
+} el2_mte2_regs_t;
 
 typedef struct el2_fgt_regs {
 	uint64_t hdfgrtr_el2;
@@ -118,8 +118,8 @@
 
 	el2_common_regs_t common;
 
-#if ENABLE_FEAT_MTE
-	el2_mte_regs_t mte;
+#if ENABLE_FEAT_MTE2
+	el2_mte2_regs_t mte2;
 #endif
 
 #if ENABLE_FEAT_FGT
@@ -185,14 +185,14 @@
 #define write_el2_ctx_common(ctx, reg, val)	((((ctx)->common).reg)	\
 							= (uint64_t) (val))
 
-#if ENABLE_FEAT_MTE
-#define read_el2_ctx_mte(ctx, reg)		(((ctx)->mte).reg)
-#define write_el2_ctx_mte(ctx, reg, val)	((((ctx)->mte).reg)	\
+#if ENABLE_FEAT_MTE2
+#define read_el2_ctx_mte2(ctx, reg)		(((ctx)->mte2).reg)
+#define write_el2_ctx_mte2(ctx, reg, val)	((((ctx)->mte2).reg)	\
 							= (uint64_t) (val))
 #else
-#define read_el2_ctx_mte(ctx, reg)		ULL(0)
-#define write_el2_ctx_mte(ctx, reg, val)
-#endif /* ENABLE_FEAT_MTE */
+#define read_el2_ctx_mte2(ctx, reg)		ULL(0)
+#define write_el2_ctx_mte2(ctx, reg, val)
+#endif /* ENABLE_FEAT_MTE2 */
 
 #if ENABLE_FEAT_FGT
 #define read_el2_ctx_fgt(ctx, reg)		(((ctx)->fgt).reg)
diff --git a/lib/el3_runtime/aarch64/context_mgmt.c b/lib/el3_runtime/aarch64/context_mgmt.c
index 39f3947..6929ff9 100644
--- a/lib/el3_runtime/aarch64/context_mgmt.c
+++ b/lib/el3_runtime/aarch64/context_mgmt.c
@@ -1278,7 +1278,7 @@
 	el2_sysregs_context_save_gic(el2_sysregs_ctx);
 
 	if (is_feat_mte2_supported()) {
-		write_el2_ctx_mte(el2_sysregs_ctx, tfsr_el2, read_tfsr_el2());
+		write_el2_ctx_mte2(el2_sysregs_ctx, tfsr_el2, read_tfsr_el2());
 	}
 
 #if CTX_INCLUDE_MPAM_REGS
@@ -1364,7 +1364,7 @@
 	el2_sysregs_context_restore_gic(el2_sysregs_ctx);
 
 	if (is_feat_mte2_supported()) {
-		write_tfsr_el2(read_el2_ctx_mte(el2_sysregs_ctx, tfsr_el2));
+		write_tfsr_el2(read_el2_ctx_mte2(el2_sysregs_ctx, tfsr_el2));
 	}
 
 #if CTX_INCLUDE_MPAM_REGS