From: Martin Schwidefsky Date: Thu, 25 Dec 2008 12:39:17 +0000 (+0100) Subject: [S390] remove warnings with functions ending in BUG X-Git-Tag: v2.6.29-rc1~584^2~38 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=2d6cd2a5908adecd06c8cee2a73814463ed71493;p=linux-2.6-omap-h63xx.git [S390] remove warnings with functions ending in BUG Functions which end in a BUG() statement and skip the return statement cause compile warnings on s390, e.g.: mm/bootmem.c: In function 'mark_bootmem': mm/bootmem.c:321: warning: control reaches end of non-void function To avoid the warning add an endless loop to the BUG() macro. Signed-off-by: Martin Schwidefsky Signed-off-by: Martin Schwidefsky --- diff --git a/arch/s390/include/asm/bug.h b/arch/s390/include/asm/bug.h index 384e3621e34..7efd0abe888 100644 --- a/arch/s390/include/asm/bug.h +++ b/arch/s390/include/asm/bug.h @@ -47,7 +47,10 @@ #endif /* CONFIG_DEBUG_BUGVERBOSE */ -#define BUG() __EMIT_BUG(0) +#define BUG() do { \ + __EMIT_BUG(0); \ + for (;;); \ +} while (0) #define WARN_ON(x) ({ \ int __ret_warn_on = !!(x); \