Re: [RFC PATCH v2 1/8] arm64: Implement stack trace termination record

2021-03-23 Thread Madhavan T. Venkataraman
On 3/23/21 5:24 AM, Mark Rutland wrote: > On Fri, Mar 19, 2021 at 05:03:09PM -0500, Madhavan T. Venkataraman wrote: >> I solved this by using existing functions logically instead of inventing a >> dummy function. I initialize pt_regs->stackframe[1] to an existing function >> so that the stack

Re: [RFC PATCH v2 1/8] arm64: Implement stack trace termination record

2021-03-23 Thread Mark Rutland
On Fri, Mar 19, 2021 at 05:03:09PM -0500, Madhavan T. Venkataraman wrote: > I solved this by using existing functions logically instead of inventing a > dummy function. I initialize pt_regs->stackframe[1] to an existing function > so that the stack trace will not show a 0x0 entry as well as the

Re: [RFC PATCH v2 1/8] arm64: Implement stack trace termination record

2021-03-19 Thread Madhavan T. Venkataraman
On 3/19/21 1:19 PM, Madhavan T. Venkataraman wrote: > > > On 3/19/21 9:29 AM, Madhavan T. Venkataraman wrote: >> >> >> On 3/19/21 7:30 AM, Mark Brown wrote: >>> On Thu, Mar 18, 2021 at 03:26:13PM -0500, Madhavan T. Venkataraman wrote: On 3/18/21 10:09 AM, Mark Brown wrote: >>> > If

Re: [RFC PATCH v2 1/8] arm64: Implement stack trace termination record

2021-03-19 Thread Madhavan T. Venkataraman
On 3/19/21 9:29 AM, Madhavan T. Venkataraman wrote: > > > On 3/19/21 7:30 AM, Mark Brown wrote: >> On Thu, Mar 18, 2021 at 03:26:13PM -0500, Madhavan T. Venkataraman wrote: >>> On 3/18/21 10:09 AM, Mark Brown wrote: >> If we are going to add the extra record there would probably be less

Re: [RFC PATCH v2 1/8] arm64: Implement stack trace termination record

2021-03-19 Thread Madhavan T. Venkataraman
On 3/19/21 7:30 AM, Mark Brown wrote: > On Thu, Mar 18, 2021 at 03:26:13PM -0500, Madhavan T. Venkataraman wrote: >> On 3/18/21 10:09 AM, Mark Brown wrote: > >>> If we are going to add the extra record there would probably be less >>> potential for confusion if we pointed it at some sensibly

Re: [RFC PATCH v2 1/8] arm64: Implement stack trace termination record

2021-03-19 Thread Mark Brown
On Thu, Mar 18, 2021 at 03:26:13PM -0500, Madhavan T. Venkataraman wrote: > On 3/18/21 10:09 AM, Mark Brown wrote: > > If we are going to add the extra record there would probably be less > > potential for confusion if we pointed it at some sensibly named dummy > > function so anything or anyone

Re: [RFC PATCH v2 1/8] arm64: Implement stack trace termination record

2021-03-18 Thread Madhavan T. Venkataraman
On 3/18/21 10:09 AM, Mark Brown wrote: > On Mon, Mar 15, 2021 at 11:57:53AM -0500, madve...@linux.microsoft.com wrote: > >> In summary, task pt_regs->stackframe is where a successful stack trace ends. > >> .if \el == 0 >> - mov x29, xzr >> + stp xzr, xzr, [sp,

Re: [RFC PATCH v2 1/8] arm64: Implement stack trace termination record

2021-03-18 Thread Mark Brown
On Mon, Mar 15, 2021 at 11:57:53AM -0500, madve...@linux.microsoft.com wrote: > In summary, task pt_regs->stackframe is where a successful stack trace ends. > .if \el == 0 > - mov x29, xzr > + stp xzr, xzr, [sp, #S_STACKFRAME] > .else > stp x29,

[RFC PATCH v2 1/8] arm64: Implement stack trace termination record

2021-03-15 Thread madvenka
From: "Madhavan T. Venkataraman" The unwinder needs to be able to reliably tell when it has reached the end of a stack trace. One way to do this is to have the last stack frame at a fixed offset from the base of the task stack. When the unwinder reaches that offset, it knows it is done. Kernel