aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm64/kernel/stacktrace.c')
-rw-r--r--arch/arm64/kernel/stacktrace.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/arch/arm64/kernel/stacktrace.c b/arch/arm64/kernel/stacktrace.c
index cfd46c227c8c..a99eff9afc1f 100644
--- a/arch/arm64/kernel/stacktrace.c
+++ b/arch/arm64/kernel/stacktrace.c
@@ -43,6 +43,9 @@ int notrace unwind_frame(struct task_struct *tsk, struct stackframe *frame)
43 unsigned long fp = frame->fp; 43 unsigned long fp = frame->fp;
44 unsigned long irq_stack_ptr; 44 unsigned long irq_stack_ptr;
45 45
46 if (!tsk)
47 tsk = current;
48
46 /* 49 /*
47 * Switching between stacks is valid when tracing current and in 50 * Switching between stacks is valid when tracing current and in
48 * non-preemptible context. 51 * non-preemptible context.
@@ -67,7 +70,7 @@ int notrace unwind_frame(struct task_struct *tsk, struct stackframe *frame)
67 frame->pc = *(unsigned long *)(fp + 8); 70 frame->pc = *(unsigned long *)(fp + 8);
68 71
69#ifdef CONFIG_FUNCTION_GRAPH_TRACER 72#ifdef CONFIG_FUNCTION_GRAPH_TRACER
70 if (tsk && tsk->ret_stack && 73 if (tsk->ret_stack &&
71 (frame->pc == (unsigned long)return_to_handler)) { 74 (frame->pc == (unsigned long)return_to_handler)) {
72 /* 75 /*
73 * This is a case where function graph tracer has 76 * This is a case where function graph tracer has