Commit bd8fbdee authored by Rui Sousa's avatar Rui Sousa Committed by Ingo Molnar

lockdep: fix compilation when CONFIG_TRACE_IRQFLAGS_SUPPORT is not set

This patch fixes compilation if CONFIG_TRACE_IRQFLAGS_SUPPORT is ever
disabled (which is currently not allowed by Kconfig). Alternatively
we could just remove the option altogether and the associated code
paths. Since the compilation error has been in the tree for at
least two years and no one noticed it, I guess we don't really have
the need for CONFIG_TRACE_IRQFLAGS_SUPPORT=n.

Boot tested on x86 UP.
Signed-off-by: default avatarRui Sousa <rui.p.m.sousa@gmail.com>
Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
parent d210baf5
...@@ -52,10 +52,10 @@ ...@@ -52,10 +52,10 @@
# define start_critical_timings() do { } while (0) # define start_critical_timings() do { } while (0)
#endif #endif
#ifdef CONFIG_TRACE_IRQFLAGS_SUPPORT
#include <asm/irqflags.h> #include <asm/irqflags.h>
#ifdef CONFIG_TRACE_IRQFLAGS_SUPPORT
#define local_irq_enable() \ #define local_irq_enable() \
do { trace_hardirqs_on(); raw_local_irq_enable(); } while (0) do { trace_hardirqs_on(); raw_local_irq_enable(); } while (0)
#define local_irq_disable() \ #define local_irq_disable() \
...@@ -84,21 +84,20 @@ ...@@ -84,21 +84,20 @@
* The local_irq_*() APIs are equal to the raw_local_irq*() * The local_irq_*() APIs are equal to the raw_local_irq*()
* if !TRACE_IRQFLAGS. * if !TRACE_IRQFLAGS.
*/ */
# define raw_local_irq_disable() local_irq_disable() #define local_irq_disable() raw_local_irq_disable()
# define raw_local_irq_enable() local_irq_enable() #define local_irq_enable() raw_local_irq_enable()
# define raw_local_irq_save(flags) \ #define local_irq_save(flags) \
do { \ do { \
typecheck(unsigned long, flags); \ typecheck(unsigned long, flags); \
local_irq_save(flags); \ raw_local_irq_save(flags); \
} while (0) } while (0)
# define raw_local_irq_restore(flags) \ # define local_irq_restore(flags) \
do { \ do { \
typecheck(unsigned long, flags); \ typecheck(unsigned long, flags); \
local_irq_restore(flags); \ raw_local_irq_restore(flags); \
} while (0) } while (0)
#endif /* CONFIG_TRACE_IRQFLAGS_SUPPORT */ #endif /* CONFIG_TRACE_IRQFLAGS_SUPPORT */
#ifdef CONFIG_TRACE_IRQFLAGS_SUPPORT
#define safe_halt() \ #define safe_halt() \
do { \ do { \
trace_hardirqs_on(); \ trace_hardirqs_on(); \
...@@ -124,6 +123,5 @@ ...@@ -124,6 +123,5 @@
typecheck(unsigned long, flags); \ typecheck(unsigned long, flags); \
raw_irqs_disabled_flags(flags); \ raw_irqs_disabled_flags(flags); \
}) })
#endif /* CONFIG_X86 */
#endif #endif
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment