summaryrefslogtreecommitdiff
path: root/include/asm-generic
diff options
context:
space:
mode:
authorIngo Molnar <mingo@elte.hu>2009-07-03 13:29:58 (GMT)
committerScott Wood <scottwood@freescale.com>2015-02-13 22:20:17 (GMT)
commit2fc6c066722a33a9e554426208edd9f4fb2e5b8e (patch)
tree4aaa717f245c8d5de9c1885f8c64a8a30d728316 /include/asm-generic
parent1c1d9c0ed5911d2e32ef5322d833a58ab53c13ae (diff)
downloadlinux-fsl-qoriq-2fc6c066722a33a9e554426208edd9f4fb2e5b8e.tar.xz
bug: BUG_ON/WARN_ON variants dependend on RT/!RT
Signed-off-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'include/asm-generic')
-rw-r--r--include/asm-generic/bug.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/include/asm-generic/bug.h b/include/asm-generic/bug.h
index 7d10f96..aee7fd2 100644
--- a/include/asm-generic/bug.h
+++ b/include/asm-generic/bug.h
@@ -202,6 +202,20 @@ extern void warn_slowpath_null(const char *file, const int line);
# define WARN_ON_SMP(x) ({0;})
#endif
+#ifdef CONFIG_PREEMPT_RT_BASE
+# define BUG_ON_RT(c) BUG_ON(c)
+# define BUG_ON_NONRT(c) do { } while (0)
+# define WARN_ON_RT(condition) WARN_ON(condition)
+# define WARN_ON_NONRT(condition) do { } while (0)
+# define WARN_ON_ONCE_NONRT(condition) do { } while (0)
+#else
+# define BUG_ON_RT(c) do { } while (0)
+# define BUG_ON_NONRT(c) BUG_ON(c)
+# define WARN_ON_RT(condition) do { } while (0)
+# define WARN_ON_NONRT(condition) WARN_ON(condition)
+# define WARN_ON_ONCE_NONRT(condition) WARN_ON_ONCE(condition)
+#endif
+
#endif /* __ASSEMBLY__ */
#endif