Thread (11 messages) 11 messages, 6 authors, 2012-01-17
STALE5276d

[PATCH] mips: remove custom BUILD_BUG()

From: Eric Dumazet <hidden>
Date: 2012-01-17 05:52:59
Also in: lkml
Subsystem: mips, the rest · Maintainers: Thomas Bogendoerfer, Linus Torvalds

Commit 1399ff86f2a2b (kernel.h: add BUILD_BUG() macro) broke mips build

In file included from /opt/src/linux/arch/mips/include/asm/io.h:16:0,
                 from /opt/src/linux/arch/mips/include/asm/page.h:54,
                 from include/linux/serial.h:16,
                 from include/linux/serial_core.h:23,
                 from include/linux/serial_8250.h:14,
                 from arch/mips/mti-malta/malta-platform.c:25:
include/linux/kernel.h:717:0: error: "BUILD_BUG" redefined [-Werror]
/opt/src/linux/arch/mips/include/asm/page.h:43:0: note: this is the
location of the previous definition
cc1: all warnings being treated as errors

Remove the conflicting mips macro.

Signed-off-by: Eric Dumazet <redacted>
CC: Ralf Baechle <redacted>
---
 arch/mips/include/asm/page.h |    3 ---
 1 file changed, 3 deletions(-)
diff --git a/arch/mips/include/asm/page.h b/arch/mips/include/asm/page.h
index d417909..da9bd7d 100644
--- a/arch/mips/include/asm/page.h
+++ b/arch/mips/include/asm/page.h
@@ -39,9 +39,6 @@
 #define HPAGE_MASK	(~(HPAGE_SIZE - 1))
 #define HUGETLB_PAGE_ORDER	(HPAGE_SHIFT - PAGE_SHIFT)
 #else /* !CONFIG_HUGETLB_PAGE */
-# ifndef BUILD_BUG
-#  define BUILD_BUG() do { extern void __build_bug(void); __build_bug(); } while (0)
-# endif
 #define HPAGE_SHIFT	({BUILD_BUG(); 0; })
 #define HPAGE_SIZE	({BUILD_BUG(); 0; })
 #define HPAGE_MASK	({BUILD_BUG(); 0; })
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help