Re: [PATCH 1/2] x86/stacktrace: do not fail when regs on stack for ORC

2018-05-14 Thread Jiri Slaby
On 05/14/2018, 03:42 PM, Josh Poimboeuf wrote: > Oops. How about this one: Yup, we are there. thanks, -- js suse labs

Re: [PATCH 1/2] x86/stacktrace: do not fail when regs on stack for ORC

2018-05-14 Thread Josh Poimboeuf
On Mon, May 14, 2018 at 01:08:40PM +0200, Jiri Slaby wrote: > On 05/11/2018, 05:12 PM, Josh Poimboeuf wrote: > > I assume you're going to carry this as > > part of your patches to enable HAVE_RELIABLE_STACKTRACE? > > Sure. > > > --- a/tools/objtool/orc_dump.c > > +++ b/tools/objtool/orc_dump.c >

Re: [PATCH 1/2] x86/stacktrace: do not fail when regs on stack for ORC

2018-05-14 Thread Jiri Slaby
On 05/11/2018, 05:12 PM, Josh Poimboeuf wrote: > I assume you're going to carry this as > part of your patches to enable HAVE_RELIABLE_STACKTRACE? Sure. > --- a/tools/objtool/orc_dump.c > +++ b/tools/objtool/orc_dump.c > @@ -203,7 +203,8 @@ int orc_dump(const char *_objname) > > p

Re: [PATCH 1/2] x86/stacktrace: do not fail when regs on stack for ORC

2018-05-11 Thread Josh Poimboeuf
On Fri, May 11, 2018 at 09:01:30AM +0200, Jiri Slaby wrote: > On 05/10/2018, 02:49 PM, Josh Poimboeuf wrote: > > On Thu, May 10, 2018 at 02:33:03PM +0200, Jiri Slaby wrote: > >> On 04/19/2018, 03:42 PM, Josh Poimboeuf wrote: > >>> On Mon, Apr 16, 2018 at 05:16:53PM -0500, Josh Poimboeuf wrote: > >>

Re: [PATCH 1/2] x86/stacktrace: do not fail when regs on stack for ORC

2018-05-11 Thread Jiri Slaby
On 05/10/2018, 02:49 PM, Josh Poimboeuf wrote: > On Thu, May 10, 2018 at 02:33:03PM +0200, Jiri Slaby wrote: >> On 04/19/2018, 03:42 PM, Josh Poimboeuf wrote: >>> On Mon, Apr 16, 2018 at 05:16:53PM -0500, Josh Poimboeuf wrote: On Wed, Dec 20, 2017 at 08:07:17PM +0100, Jiri Slaby wrote: > O

Re: [PATCH 1/2] x86/stacktrace: do not fail when regs on stack for ORC

2018-05-10 Thread Josh Poimboeuf
On Thu, May 10, 2018 at 02:33:03PM +0200, Jiri Slaby wrote: > On 04/19/2018, 03:42 PM, Josh Poimboeuf wrote: > > On Mon, Apr 16, 2018 at 05:16:53PM -0500, Josh Poimboeuf wrote: > >> On Wed, Dec 20, 2017 at 08:07:17PM +0100, Jiri Slaby wrote: > >>> On 12/20/2017, 06:45 PM, Josh Poimboeuf wrote: > >>

Re: [PATCH 1/2] x86/stacktrace: do not fail when regs on stack for ORC

2018-05-10 Thread Jiri Slaby
On 04/19/2018, 03:42 PM, Josh Poimboeuf wrote: > On Mon, Apr 16, 2018 at 05:16:53PM -0500, Josh Poimboeuf wrote: >> On Wed, Dec 20, 2017 at 08:07:17PM +0100, Jiri Slaby wrote: >>> On 12/20/2017, 06:45 PM, Josh Poimboeuf wrote: It might not be until 2018 though. But in the meantime you can go

Re: [PATCH 1/2] x86/stacktrace: do not fail when regs on stack for ORC

2018-04-19 Thread Josh Poimboeuf
On Mon, Apr 16, 2018 at 05:16:53PM -0500, Josh Poimboeuf wrote: > On Wed, Dec 20, 2017 at 08:07:17PM +0100, Jiri Slaby wrote: > > On 12/20/2017, 06:45 PM, Josh Poimboeuf wrote: > > > It might not be until 2018 though. But in the meantime you can go ahead > > > and update your patches accordingly a

Re: [PATCH 1/2] x86/stacktrace: do not fail when regs on stack for ORC

2018-04-16 Thread Josh Poimboeuf
On Wed, Dec 20, 2017 at 08:07:17PM +0100, Jiri Slaby wrote: > On 12/20/2017, 06:45 PM, Josh Poimboeuf wrote: > > It might not be until 2018 though. But in the meantime you can go ahead > > and update your patches accordingly and then we can combine them for > > testing next year. > > I already di

Re: [PATCH 1/2] x86/stacktrace: do not fail when regs on stack for ORC

2017-12-20 Thread Jiri Slaby
On 12/20/2017, 06:45 PM, Josh Poimboeuf wrote: > It might not be until 2018 though. But in the meantime you can go ahead > and update your patches accordingly and then we can combine them for > testing next year. I already did ;). So when you have that ready, I will send it on top right after. t

Re: [PATCH 1/2] x86/stacktrace: do not fail when regs on stack for ORC

2017-12-20 Thread Josh Poimboeuf
On Sun, Dec 17, 2017 at 09:37:49PM -0600, Josh Poimboeuf wrote: > > > > So making it: > > if (!(task->flags & (PF_KTHREAD | PF_IDLE))) > > return -EINVAL; > > > > works, but is not reliable now. So I believe, we cannot live without > > unwind->error to differentiate betwee

Re: [PATCH 1/2] x86/stacktrace: do not fail when regs on stack for ORC

2017-12-17 Thread Jiri Slaby
On 12/18/2017, 04:37 AM, Josh Poimboeuf wrote: > On Thu, Dec 14, 2017 at 10:58:35PM +0100, Jiri Slaby wrote: >>> return -EINVAL; >> >> Kthreads and idle tasks hit this error as they have no user regs on the >> stack obviously :). > > Doh, sorry, I forgot about that. FWIW and to be complete, a

Re: [PATCH 1/2] x86/stacktrace: do not fail when regs on stack for ORC

2017-12-17 Thread Josh Poimboeuf
On Thu, Dec 14, 2017 at 10:58:35PM +0100, Jiri Slaby wrote: > On 11/30/2017, 08:57 PM, Josh Poimboeuf wrote: > > So with those changes in mind, how about something like this (plus > > comments)? > > > > for (unwind_start(&state, task, NULL, NULL); !unwind_done(&state); > > unwind_next

Re: [PATCH 1/2] x86/stacktrace: do not fail when regs on stack for ORC

2017-12-14 Thread Jiri Slaby
On 11/30/2017, 08:57 PM, Josh Poimboeuf wrote: > So with those changes in mind, how about something like this (plus > comments)? > > for (unwind_start(&state, task, NULL, NULL); !unwind_done(&state); >unwind_next_frame(&state)) { > > regs = unwind_get_entry_regs(&s

Re: [PATCH 1/2] x86/stacktrace: do not fail when regs on stack for ORC

2017-11-30 Thread Jiri Slaby
On 11/30/2017, 08:59 PM, Josh Poimboeuf wrote: > On Thu, Nov 30, 2017 at 01:57:10PM -0600, Josh Poimboeuf wrote: >> On Thu, Nov 30, 2017 at 09:03:24AM +0100, Jiri Slaby wrote: >>> save_stack_trace_reliable now returns "non reliable" when there are >>> kernel pt_regs on stack. This means an interrup

Re: [PATCH 1/2] x86/stacktrace: do not fail when regs on stack for ORC

2017-11-30 Thread Josh Poimboeuf
On Thu, Nov 30, 2017 at 01:57:10PM -0600, Josh Poimboeuf wrote: > On Thu, Nov 30, 2017 at 09:03:24AM +0100, Jiri Slaby wrote: > > save_stack_trace_reliable now returns "non reliable" when there are > > kernel pt_regs on stack. This means an interrupt or exception happened. > > Somewhere down the ro

Re: [PATCH 1/2] x86/stacktrace: do not fail when regs on stack for ORC

2017-11-30 Thread Josh Poimboeuf
On Thu, Nov 30, 2017 at 09:03:24AM +0100, Jiri Slaby wrote: > save_stack_trace_reliable now returns "non reliable" when there are > kernel pt_regs on stack. This means an interrupt or exception happened. > Somewhere down the route. It is a problem for frame pointer unwinder, > because the frame mig