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>
This commit is contained in:
@@ -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))) {
|
||||
|
Reference in New Issue
Block a user