diff mbox series

[RFC,v2,23/48] lmb: use the BIT macro for lmb flags

Message ID 20240704073544.670249-24-sughosh.ganu@linaro.org
State New
Headers show
Series Make U-Boot memory reservations coherent | expand

Commit Message

Sughosh Ganu July 4, 2024, 7:35 a.m. UTC
Use the BIT macro for assigning values to the LMB flags instead of
assigning random values to them.

Signed-off-by: Sughosh Ganu <sughosh.ganu@linaro.org>
---
Changes since V1: New patch based on review comment from Heinrich

 include/lmb.h | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)
diff mbox series

Patch

diff --git a/include/lmb.h b/include/lmb.h
index 02891a14be..cc4cf9f3c8 100644
--- a/include/lmb.h
+++ b/include/lmb.h
@@ -5,6 +5,7 @@ 
 
 #include <asm/types.h>
 #include <asm/u-boot.h>
+#include <linux/bitops.h>
 
 /*
  * Logical memory blocks.
@@ -18,9 +19,9 @@ 
  * @LMB_NOMAP: don't add to mmu configuration
  */
 enum lmb_flags {
-	LMB_NONE		= 0x0,
-	LMB_NOMAP		= 0x4,
-	LMB_NOOVERWRITE		= 0x8,
+	LMB_NONE		= BIT(0),
+	LMB_NOMAP		= BIT(1),
+	LMB_NOOVERWRITE		= BIT(2),
 };
 
 /**