[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[RFC PATCH 4/5] x86/HVM: protect mm_type_tbl format from clang-format



The array mm_type_tbl initialization is formatted in a way that
clang-format can't keep, so disable clang-format on that array
initialization.

Signed-off-by: Luca Fancellu <luca.fancellu@xxxxxxx>
---
 xen/arch/x86/hvm/mtrr.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/xen/arch/x86/hvm/mtrr.c b/xen/arch/x86/hvm/mtrr.c
index 29f3fb160776..f32ce3162ae2 100644
--- a/xen/arch/x86/hvm/mtrr.c
+++ b/xen/arch/x86/hvm/mtrr.c
@@ -18,6 +18,7 @@
 /* Get page attribute fields (PAn) from PAT MSR. */
 #define pat_cr_2_paf(pat_cr,n)  ((((uint64_t)pat_cr) >> ((n)<<3)) & 0xff)
 
+/* clang-format off */
 /* Effective mm type lookup table, according to MTRR and PAT. */
 static const uint8_t mm_type_tbl[MTRR_NUM_TYPES][X86_NUM_MT] = {
 #define RS MEMORY_NUM_TYPES
@@ -43,6 +44,7 @@ static const uint8_t mm_type_tbl[MTRR_NUM_TYPES][X86_NUM_MT] 
= {
 #undef WB
 #undef RS
 };
+/* clang-format on */
 
 /*
  * Reverse lookup table, to find a pat type according to MTRR and effective
-- 
2.34.1




 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.