From c7e872e7da5514d014707a407ea562d197cc0136 Mon Sep 17 00:00:00 2001 From: Peter Zijlstra Date: Thu, 11 Oct 2007 22:11:12 +0200 Subject: lockdep: i386: connect the sysexit hook Run the lockdep_sys_exit hook after all other C code on the syscall return path. Signed-off-by: Peter Zijlstra Signed-off-by: Ingo Molnar --- include/asm-x86/irqflags_32.h | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'include/asm-x86/irqflags_32.h') diff --git a/include/asm-x86/irqflags_32.h b/include/asm-x86/irqflags_32.h index eff8585cb741..d058b04e0083 100644 --- a/include/asm-x86/irqflags_32.h +++ b/include/asm-x86/irqflags_32.h @@ -160,4 +160,17 @@ static inline int raw_irqs_disabled(void) # define TRACE_IRQS_OFF #endif +#ifdef CONFIG_DEBUG_LOCK_ALLOC +# define LOCKDEP_SYS_EXIT \ + pushl %eax; \ + pushl %ecx; \ + pushl %edx; \ + call lockdep_sys_exit; \ + popl %edx; \ + popl %ecx; \ + popl %eax; +#else +# define LOCKDEP_SYS_EXIT +#endif + #endif -- cgit v1.2.3-59-g8ed1b