summaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2020-11-04 19:57:14 +0300
committerBin Meng <bmeng.cn@gmail.com>2020-11-05 09:58:45 +0300
commit1779b8a96a32706dc8e2e71187889b38d9822443 (patch)
tree0662d88429c8d72b0d993fe37dc5aee259d47745 /include/linux
parent43a218b65366e225297a20442b49d07129765f73 (diff)
downloadu-boot-1779b8a96a32706dc8e2e71187889b38d9822443.tar.xz
Add an assembly guard around linux/bitops.h
This file can be included by any header but it includes C code. Guard it to avoid errors when compiling ASL, etc. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/bitops.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/linux/bitops.h b/include/linux/bitops.h
index 6b509dce58..16f28993f5 100644
--- a/include/linux/bitops.h
+++ b/include/linux/bitops.h
@@ -1,7 +1,7 @@
#ifndef _LINUX_BITOPS_H
#define _LINUX_BITOPS_H
-#ifndef USE_HOSTCC
+#if !defined(USE_HOSTCC) && !defined(__ASSEMBLY__)
#include <asm/types.h>
#include <asm-generic/bitsperlong.h>
@@ -218,6 +218,6 @@ static inline void generic_clear_bit(int nr, volatile unsigned long *addr)
*p &= ~mask;
}
-#endif /* !USE_HOSTCC */
+#endif /* !USE_HOSTCC && !__ASSEMBLY__ */
#endif