From: Ingo Molnar on x86_64 this also needs the patch below - NULL means 'current'. Signed-off-by: Andrew Morton --- kernel/lockdep.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff -puN kernel/lockdep.c~lockdep-show-held-locks-when-showing-a-stackdump-fix kernel/lockdep.c --- a/kernel/lockdep.c~lockdep-show-held-locks-when-showing-a-stackdump-fix +++ a/kernel/lockdep.c @@ -420,7 +420,11 @@ static void print_lock(struct held_lock static void lockdep_print_held_locks(struct task_struct *curr) { - int i, depth = curr->lockdep_depth; + int i, depth; + + if (!curr) + curr = current; + depth = curr->lockdep_depth; if (!depth) { printk("no locks held by %s/%d.\n", curr->comm, curr->pid); _