summaryrefslogtreecommitdiffstats
path: root/kernel/lockdep_internals.h
diff options
context:
space:
mode:
authorMing Lei <tom.leiming@gmail.com>2009-07-16 15:44:29 +0200
committerPeter Zijlstra <a.p.zijlstra@chello.nl>2009-07-24 10:49:54 +0200
commit24208ca76707581a097c01a73fd63781e73d3404 (patch)
tree46d2e44f11dd0b3dda782d6e4467c700f6d03149 /kernel/lockdep_internals.h
parentd7aaba140a09b7a2295aec061629c880f088de3d (diff)
downloadop-kernel-dev-24208ca76707581a097c01a73fd63781e73d3404.zip
op-kernel-dev-24208ca76707581a097c01a73fd63781e73d3404.tar.gz
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 c2f6594..b115aaa 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)
return child->parent;
}
-static inline unsigned long get_lock_depth(struct lock_list *child)
+static inline int get_lock_depth(struct lock_list *child)
{
- unsigned long depth = 0;
+ int depth = 0;
struct lock_list *parent;
while ((parent = get_lock_parent(child))) {
OpenPOWER on IntegriCloud