[SRU][Bionic][Cosmic][PATCH 1/1] powerpc/livepatch: Implement reliable stack tracing for the consistency model

Khaled Elmously khalid.elmously at canonical.com
Thu Jun 7 17:37:50 UTC 2018


On 2018-06-05 11:52:15 , Joseph Salisbury wrote:
> On 06/04/2018 10:11 PM, Michael Ellerman wrote:
> > Joseph Salisbury <joseph.salisbury at canonical.com> writes:
> >> diff --git a/arch/powerpc/kernel/stacktrace.c b/arch/powerpc/kernel/stacktrace.c
> >> index d534ed901538..26a50603177c 100644
> >> --- a/arch/powerpc/kernel/stacktrace.c
> >> +++ b/arch/powerpc/kernel/stacktrace.c
> >> @@ -76,3 +81,115 @@ save_stack_trace_regs(struct pt_regs *regs, struct stack_trace *trace)
> >>  	save_context_stack(trace, regs->gpr[1], current, 0);
> >>  }
> >>  EXPORT_SYMBOL_GPL(save_stack_trace_regs);
> >> +
> >> +#ifdef CONFIG_HAVE_RELIABLE_STACKTRACE
> >> +int
> >> +save_stack_trace_tsk_reliable(struct task_struct *tsk,
> >> +				struct stack_trace *trace)
> >> +{
> > ...
> >> +		/*
> >> +		 * Mark stacktraces with kretprobed functions on them
> >> +		 * as unreliable.
> >> +		 */
> >> +		if (ip == (unsigned long)kretprobe_trampoline)
> >> +			return 1;
> > You may also want:
> >
> > 5e3f0d15ae5f ("powerpc/livepatch: Fix build error with kprobes disabled.")
> >
> > cheers
> 
> Thanks for the feedback, Michael.  Would it be possible for you to post
> this comment to the bug?  That way we can get feedback from the original
> bug reporter and IBM.
> 
> 
> Thanks,
> 
> 
> Joe

Joe, I did not apply this patch as it is not clear to me if a V2 is on the way or if it needs more work. Please advise.

Thanks

Khalid

> 
> 
> 
> -- 
> kernel-team mailing list
> kernel-team at lists.ubuntu.com
> https://lists.ubuntu.com/mailman/listinfo/kernel-team




More information about the kernel-team mailing list