1
0
Fork 0

asm-generic: add unlikely to default BUG_ON(x)

Add unlikely to default BUG_ON(x) in !CONFIG_BUG. It makes
the define consistent with BUG_ON(x) in CONFIG_BUG.

Signed-off-by: Denis Efremov <efremov@linux.com>
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: <linux-arch@vger.kernel.org>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
alistair/sunxi64-5.4-dsi
Denis Efremov 2019-08-29 00:09:34 +03:00 committed by Arnd Bergmann
parent 602828c1aa
commit 9b87647c66
1 changed files with 1 additions and 1 deletions

View File

@ -185,7 +185,7 @@ void __warn(const char *file, int line, void *caller, unsigned taint,
#endif
#ifndef HAVE_ARCH_BUG_ON
#define BUG_ON(condition) do { if (condition) BUG(); } while (0)
#define BUG_ON(condition) do { if (unlikely(condition)) BUG(); } while (0)
#endif
#ifndef HAVE_ARCH_WARN_ON