diff options
Diffstat (limited to 'arch/sparc/kernel/perf_event.c')
-rw-r--r-- | arch/sparc/kernel/perf_event.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/arch/sparc/kernel/perf_event.c b/arch/sparc/kernel/perf_event.c index 47c871394ccb..6de7c684c29f 100644 --- a/arch/sparc/kernel/perf_event.c +++ b/arch/sparc/kernel/perf_event.c | |||
@@ -1767,9 +1767,11 @@ void perf_callchain_kernel(struct perf_callchain_entry_ctx *entry, | |||
1767 | perf_callchain_store(entry, pc); | 1767 | perf_callchain_store(entry, pc); |
1768 | #ifdef CONFIG_FUNCTION_GRAPH_TRACER | 1768 | #ifdef CONFIG_FUNCTION_GRAPH_TRACER |
1769 | if ((pc + 8UL) == (unsigned long) &return_to_handler) { | 1769 | if ((pc + 8UL) == (unsigned long) &return_to_handler) { |
1770 | int index = current->curr_ret_stack; | 1770 | struct ftrace_ret_stack *ret_stack; |
1771 | if (current->ret_stack && index >= graph) { | 1771 | ret_stack = ftrace_graph_get_ret_stack(current, |
1772 | pc = current->ret_stack[index - graph].ret; | 1772 | graph); |
1773 | if (ret_stack) { | ||
1774 | pc = ret_stack->ret; | ||
1773 | perf_callchain_store(entry, pc); | 1775 | perf_callchain_store(entry, pc); |
1774 | graph++; | 1776 | graph++; |
1775 | } | 1777 | } |