[U-Boot] [PATCH v2 03/11] sh: bitops: add hweight*() macros

Vignesh R vigneshr at ti.com
Fri Dec 21 06:38:28 UTC 2018


Add hweight*() macros required for moving to new SF layer

Signed-off-by: Vignesh R <vigneshr at ti.com>
---
 arch/sh/include/asm/bitops.h | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/arch/sh/include/asm/bitops.h b/arch/sh/include/asm/bitops.h
index 8cb8385d76db..765f28f116bc 100644
--- a/arch/sh/include/asm/bitops.h
+++ b/arch/sh/include/asm/bitops.h
@@ -153,6 +153,10 @@ static inline int ffs (int x)
 }
 #define PLATFORM_FFS
 
+#define hweight32(x) generic_hweight32(x)
+#define hweight16(x) generic_hweight16(x)
+#define hweight8(x) generic_hweight8(x)
+
 #endif /* __KERNEL__ */
 
 #endif /* __ASM_SH_BITOPS_H */
-- 
2.20.1



More information about the U-Boot mailing list