aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/lockdep_internals.h
diff options
context:
space:
mode:
authorMing Lei <tom.leiming@gmail.com>2009-07-16 09:44:29 -0400
committerPeter Zijlstra <a.p.zijlstra@chello.nl>2009-07-24 04:49:54 -0400
commit24208ca76707581a097c01a73fd63781e73d3404 (patch)
tree46d2e44f11dd0b3dda782d6e4467c700f6d03149 /kernel/lockdep_internals.h
parentd7aaba140a09b7a2295aec061629c880f088de3d (diff)
lockdep: Introduce print_shortest_lock_dependencies
Since the shortest lock dependencies' path may be obtained by BFS, we print the shortest one by print_shortest_lock_dependencies(). Signed-off-by: Ming Lei <tom.leiming@gmail.com> Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl> LKML-Reference: <1246201486-7308-7-git-send-email-tom.leiming@gmail.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel/lockdep_internals.h')
-rw-r--r--kernel/lockdep_internals.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/kernel/lockdep_internals.h b/kernel/lockdep_internals.h
index c2f6594966f3..b115aaa0bf35 100644
--- a/kernel/lockdep_internals.h
+++ b/kernel/lockdep_internals.h
@@ -219,9 +219,9 @@ static inline struct lock_list *get_lock_parent(struct lock_list *child)
219 return child->parent; 219 return child->parent;
220} 220}
221 221
222static inline unsigned long get_lock_depth(struct lock_list *child) 222static inline int get_lock_depth(struct lock_list *child)
223{ 223{
224 unsigned long depth = 0; 224 int depth = 0;
225 struct lock_list *parent; 225 struct lock_list *parent;
226 226
227 while ((parent = get_lock_parent(child))) { 227 while ((parent = get_lock_parent(child))) {