aboutsummaryrefslogtreecommitdiffstats
path: root/meta-arm/recipes-bsp/trusted-firmware-a/files
diff options
context:
space:
mode:
authorBrett Warren <brett.warren@arm.com>2020-12-15 10:16:04 +0000
committerJon Mason <jon.mason@arm.com>2020-12-15 09:04:51 -0500
commitda32f5c1c88a390df3d77a33f925e7dff1b2e6d4 (patch)
tree309853a103b337fc82eb2c56e0bb74bb164ef3cb /meta-arm/recipes-bsp/trusted-firmware-a/files
parent293d1e0e8d23a78a0fd74030fe6a7713f4b46276 (diff)
downloadmeta-arm-da32f5c1c88a390df3d77a33f925e7dff1b2e6d4.tar.gz
meta-arm-da32f5c1c88a390df3d77a33f925e7dff1b2e6d4.tar.bz2
meta-arm-da32f5c1c88a390df3d77a33f925e7dff1b2e6d4.zip
arm/trusted-firmware-a: -Wtautological triggers removed
When compiling under clang, certain lines triggered -Wtautological errors. Cosmetic modifications were made via patches to mitigate this. Change-Id: I3d17dd5102267e03a8b7d157e66e0788b542bdd8 Signed-off-by: Brett Warren <brett.warren@arm.com> Signed-off-by: Jon Mason <jon.mason@arm.com>
Diffstat (limited to 'meta-arm/recipes-bsp/trusted-firmware-a/files')
-rw-r--r--meta-arm/recipes-bsp/trusted-firmware-a/files/0002-pmf.h-made-PMF_STOTE_ENABLE-pass-Wtautological.patch31
-rw-r--r--meta-arm/recipes-bsp/trusted-firmware-a/files/0003-xlat-tables-v2-remove-tautological-assert.patch31
2 files changed, 62 insertions, 0 deletions
diff --git a/meta-arm/recipes-bsp/trusted-firmware-a/files/0002-pmf.h-made-PMF_STOTE_ENABLE-pass-Wtautological.patch b/meta-arm/recipes-bsp/trusted-firmware-a/files/0002-pmf.h-made-PMF_STOTE_ENABLE-pass-Wtautological.patch
new file mode 100644
index 0000000..42e0f5b
--- /dev/null
+++ b/meta-arm/recipes-bsp/trusted-firmware-a/files/0002-pmf.h-made-PMF_STOTE_ENABLE-pass-Wtautological.patch
@@ -0,0 +1,31 @@
+From c9209fa0f474d41bc5ecf2b988ab404123038c1b Mon Sep 17 00:00:00 2001
+From: Brett Warren <brett.warren@arm.com>
+Date: Tue, 3 Nov 2020 13:34:26 +0000
+Subject: [PATCH] pmf.h: made PMF_STOTE_ENABLE pass -Wtautological
+
+When compiling with clang, PMF_STORE_ENABLE triggers
+-Wtautological-constant-compare. To mitigate, the definition
+is modified cosmetically to not trigger this error.
+
+Upstream-Status: Pending
+Signed-off-by: Brett Warren <brett.warren@arm.com>
+---
+ include/lib/pmf/pmf.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/include/lib/pmf/pmf.h b/include/lib/pmf/pmf.h
+index df7c9ff31..baa2dfd60 100644
+--- a/include/lib/pmf/pmf.h
++++ b/include/lib/pmf/pmf.h
+@@ -25,7 +25,7 @@
+ /*
+ * Flags passed to PMF_REGISTER_SERVICE
+ */
+-#define PMF_STORE_ENABLE (1 << 0)
++#define PMF_STORE_ENABLE 1
+ #define PMF_DUMP_ENABLE (1 << 1)
+
+ /*
+--
+2.17.1
+
diff --git a/meta-arm/recipes-bsp/trusted-firmware-a/files/0003-xlat-tables-v2-remove-tautological-assert.patch b/meta-arm/recipes-bsp/trusted-firmware-a/files/0003-xlat-tables-v2-remove-tautological-assert.patch
new file mode 100644
index 0000000..c24b1cf
--- /dev/null
+++ b/meta-arm/recipes-bsp/trusted-firmware-a/files/0003-xlat-tables-v2-remove-tautological-assert.patch
@@ -0,0 +1,31 @@
+From a0b72074ee4cfdf0ff3b807b01a962898761def4 Mon Sep 17 00:00:00 2001
+From: Brett Warren <brett.warren@arm.com>
+Date: Fri, 27 Nov 2020 10:29:48 +0000
+Subject: [PATCH] xlat_tables_v2: remove tautological assert
+
+When compiling with clang for aarch32, an assert triggered
+-Wtautological error. This assertion is removed, as
+this means there is no way for it to resolve as false anyway.
+
+Upstream-Status: Pending
+Signed-off-by: Brett Warren <brett.warren@arm.com>
+---
+ lib/xlat_tables_v2/aarch32/xlat_tables_arch.c | 2 --
+ 1 file changed, 2 deletions(-)
+
+diff --git a/lib/xlat_tables_v2/aarch32/xlat_tables_arch.c b/lib/xlat_tables_v2/aarch32/xlat_tables_arch.c
+index b69c6702b..52a75b37a 100644
+--- a/lib/xlat_tables_v2/aarch32/xlat_tables_arch.c
++++ b/lib/xlat_tables_v2/aarch32/xlat_tables_arch.c
+@@ -203,8 +203,6 @@ void setup_mmu_cfg(uint64_t *params, unsigned int flags,
+
+ assert(virtual_addr_space_size >=
+ xlat_get_min_virt_addr_space_size());
+- assert(virtual_addr_space_size <=
+- MAX_VIRT_ADDR_SPACE_SIZE);
+ assert(IS_POWER_OF_TWO(virtual_addr_space_size));
+
+ /*
+--
+2.17.1
+