Commit 2edf5e49800846a2b2b6461d99cdae18067c440f

Authored by Dave Young
Committed by Linus Torvalds
1 parent 4f0e056fde

sysctl extern cleanup: lockdep

Extern declarations in sysctl.c should be moved to their own header file,
and then include them in relavant .c files.

Move lockdep extern declarations to linux/lockdep.h

Signed-off-by: Dave Young <hidave.darkstar@gmail.com>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

Showing 2 changed files with 7 additions and 3 deletions Side-by-side Diff

include/linux/lockdep.h
... ... @@ -12,6 +12,10 @@
12 12 struct task_struct;
13 13 struct lockdep_map;
14 14  
  15 +/* for sysctl */
  16 +extern int prove_locking;
  17 +extern int lock_stat;
  18 +
15 19 #ifdef CONFIG_LOCKDEP
16 20  
17 21 #include <linux/linkage.h>
... ... @@ -67,6 +67,9 @@
67 67 #ifdef CONFIG_RT_MUTEXES
68 68 #include <linux/rtmutex.h>
69 69 #endif
  70 +#if defined(CONFIG_PROVE_LOCKING) || defined(CONFIG_LOCK_STAT)
  71 +#include <linux/lockdep.h>
  72 +#endif
70 73 #ifdef CONFIG_CHR_DEV_SG
71 74 #include <scsi/sg.h>
72 75 #endif
... ... @@ -190,9 +193,6 @@
190 193 #ifdef HAVE_ARCH_PICK_MMAP_LAYOUT
191 194 int sysctl_legacy_va_layout;
192 195 #endif
193   -
194   -extern int prove_locking;
195   -extern int lock_stat;
196 196  
197 197 /* The default sysctl tables: */
198 198