aboutsummaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2014-03-03 13:48:48 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2014-03-03 13:48:48 -0500
commit148b59c60cd4a2745d8f727c2579cffe4a88afd8 (patch)
treeca8f53b1718b3e76cf4b6b5bf759c8e49028d762 /tools
parent7abd42eab3d0a7fcdc01a19c987ef61e7fe451a4 (diff)
parent9b158f53a8da5394cb48310da9fda80b34c72bbc (diff)
Merge branch 'core-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull liblockdep fixes from Ingo Molnar: "A handful of build fixes for liblockdep" * 'core-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: tools/liblockdep: Use realpath for srctree and objtree tools/liblockdep: Add a stub for new rcu_is_watching tools/liblockdep: Mark runtests.sh as executable tools/liblockdep: Add include directory to allow tests to compile tools/liblockdep: Fix include of asm/hash.h tools/liblockdep: Fix initialization code path
Diffstat (limited to 'tools')
-rw-r--r--tools/lib/lockdep/Makefile6
-rw-r--r--tools/lib/lockdep/preload.c2
-rwxr-xr-x[-rw-r--r--]tools/lib/lockdep/run_tests.sh0
-rw-r--r--tools/lib/lockdep/uinclude/asm/hash.h6
-rw-r--r--tools/lib/lockdep/uinclude/linux/rcu.h5
5 files changed, 15 insertions, 4 deletions
diff --git a/tools/lib/lockdep/Makefile b/tools/lib/lockdep/Makefile
index da8b7aa3d351..07b0b7542511 100644
--- a/tools/lib/lockdep/Makefile
+++ b/tools/lib/lockdep/Makefile
@@ -87,8 +87,8 @@ endif # BUILD_SRC
87# We process the rest of the Makefile if this is the final invocation of make 87# We process the rest of the Makefile if this is the final invocation of make
88ifeq ($(skip-makefile),) 88ifeq ($(skip-makefile),)
89 89
90srctree := $(if $(BUILD_SRC),$(BUILD_SRC),$(CURDIR)) 90srctree := $(realpath $(if $(BUILD_SRC),$(BUILD_SRC),$(CURDIR)))
91objtree := $(CURDIR) 91objtree := $(realpath $(CURDIR))
92src := $(srctree) 92src := $(srctree)
93obj := $(objtree) 93obj := $(objtree)
94 94
@@ -112,7 +112,7 @@ export Q VERBOSE
112 112
113LIBLOCKDEP_VERSION = $(LL_VERSION).$(LL_PATCHLEVEL).$(LL_EXTRAVERSION) 113LIBLOCKDEP_VERSION = $(LL_VERSION).$(LL_PATCHLEVEL).$(LL_EXTRAVERSION)
114 114
115INCLUDES = -I. -I/usr/local/include -I./uinclude $(CONFIG_INCLUDES) 115INCLUDES = -I. -I/usr/local/include -I./uinclude -I./include $(CONFIG_INCLUDES)
116 116
117# Set compile option CFLAGS if not set elsewhere 117# Set compile option CFLAGS if not set elsewhere
118CFLAGS ?= -g -DCONFIG_LOCKDEP -DCONFIG_STACKTRACE -DCONFIG_PROVE_LOCKING -DBITS_PER_LONG=__WORDSIZE -DLIBLOCKDEP_VERSION='"$(LIBLOCKDEP_VERSION)"' -rdynamic -O0 -g 118CFLAGS ?= -g -DCONFIG_LOCKDEP -DCONFIG_STACKTRACE -DCONFIG_PROVE_LOCKING -DBITS_PER_LONG=__WORDSIZE -DLIBLOCKDEP_VERSION='"$(LIBLOCKDEP_VERSION)"' -rdynamic -O0 -g
diff --git a/tools/lib/lockdep/preload.c b/tools/lib/lockdep/preload.c
index f8465a811aa5..23bd69cb5ade 100644
--- a/tools/lib/lockdep/preload.c
+++ b/tools/lib/lockdep/preload.c
@@ -418,7 +418,7 @@ int pthread_rwlock_unlock(pthread_rwlock_t *rwlock)
418 418
419__attribute__((constructor)) static void init_preload(void) 419__attribute__((constructor)) static void init_preload(void)
420{ 420{
421 if (__init_state != done) 421 if (__init_state == done)
422 return; 422 return;
423 423
424#ifndef __GLIBC__ 424#ifndef __GLIBC__
diff --git a/tools/lib/lockdep/run_tests.sh b/tools/lib/lockdep/run_tests.sh
index 5334ad9d39b7..5334ad9d39b7 100644..100755
--- a/tools/lib/lockdep/run_tests.sh
+++ b/tools/lib/lockdep/run_tests.sh
diff --git a/tools/lib/lockdep/uinclude/asm/hash.h b/tools/lib/lockdep/uinclude/asm/hash.h
new file mode 100644
index 000000000000..d82b170bb216
--- /dev/null
+++ b/tools/lib/lockdep/uinclude/asm/hash.h
@@ -0,0 +1,6 @@
1#ifndef __ASM_GENERIC_HASH_H
2#define __ASM_GENERIC_HASH_H
3
4/* Stub */
5
6#endif /* __ASM_GENERIC_HASH_H */
diff --git a/tools/lib/lockdep/uinclude/linux/rcu.h b/tools/lib/lockdep/uinclude/linux/rcu.h
index 4c99fcb5da27..042ee8e463c9 100644
--- a/tools/lib/lockdep/uinclude/linux/rcu.h
+++ b/tools/lib/lockdep/uinclude/linux/rcu.h
@@ -13,4 +13,9 @@ static inline int rcu_is_cpu_idle(void)
13 return 1; 13 return 1;
14} 14}
15 15
16static inline bool rcu_is_watching(void)
17{
18 return false;
19}
20
16#endif 21#endif