public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH][GIT PULL][v3.5] ftrace: Make all inline tags also include notrace
@ 2012-06-14 22:47 Steven Rostedt
  2012-06-18  8:56 ` Ingo Molnar
  0 siblings, 1 reply; 4+ messages in thread
From: Steven Rostedt @ 2012-06-14 22:47 UTC (permalink / raw)
  To: LKML; +Cc: Ingo Molnar, Andrew Morton, Frederic Weisbecker, Fengguang Wu


Ingo,

Please pull the latest tip/perf/urgent tree, which can be found at:

  git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace.git
tip/perf/urgent

Head SHA1: 0e326ac2529387468a0c7923f573e16399a031ce


Steven Rostedt (1):
      ftrace: Make all inline tags also include notrace

----
 include/linux/compiler-gcc.h |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
---------------------------
commit 0e326ac2529387468a0c7923f573e16399a031ce
Author: Steven Rostedt <rostedt@goodmis.org>
Date:   Thu Jun 14 10:54:28 2012 -0400

    ftrace: Make all inline tags also include notrace
    
    Commit 5963e317b1 ftrace/x86: Do not change stacks in DEBUG when calling lockdep
    prevented lockdep calls from the int3 breakpoint handler from reseting the
    stack if a function that was called was in the process of being converted
    for tracing and had a breakpoint on it. The idea is, before calling
    the lockdep code, do a load_idt() to the special IDT that kept the breakpoint
    stack from reseting. This worked well as a quick fix for this kernel
    release, until a certain config caused a lockup in the function tracer
    start up tests.
    
    Investigating it, I found that the load_idt that was used to prevent
    the int3 from changing stacks was itself being traced!
    
    Even though the config had CONFIG_OPTIMIZE_INLINING disabled, and
    all 'inline' tags were set to always inline, there were still cases that
    it did not inline! This was caused by CONFIG_PARAVIRT_GUEST, where it
    would add a pointer to the native_load_idt() which made that function
    to be traced.
    
    Commit 45959ee7 ftrace: Do not function trace inlined functions
    only touched the 'inline' tags when CONFIG_OPMITIZE_INLINING was enabled.
    PARAVIRT_GUEST shows that this was not enough and we need to also
    mark always_inline with notrace as well.
    
    Reported-by: Fengguang Wu <wfg@linux.intel.com>
    Tested-by: Fengguang Wu <wfg@linux.intel.com>
    Signed-off-by: Steven Rostedt <rostedt@goodmis.org>

diff --git a/include/linux/compiler-gcc.h b/include/linux/compiler-gcc.h
index e5834aa..6a6d7ae 100644
--- a/include/linux/compiler-gcc.h
+++ b/include/linux/compiler-gcc.h
@@ -47,9 +47,9 @@
  */
 #if !defined(CONFIG_ARCH_SUPPORTS_OPTIMIZED_INLINING) || \
     !defined(CONFIG_OPTIMIZE_INLINING) || (__GNUC__ < 4)
-# define inline		inline		__attribute__((always_inline))
-# define __inline__	__inline__	__attribute__((always_inline))
-# define __inline	__inline	__attribute__((always_inline))
+# define inline		inline		__attribute__((always_inline)) notrace
+# define __inline__	__inline__	__attribute__((always_inline)) notrace
+# define __inline	__inline	__attribute__((always_inline)) notrace
 #else
 /* A lot of inline functions can cause havoc with function tracing */
 # define inline		inline		notrace



^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH][GIT PULL][v3.5] ftrace: Make all inline tags also include notrace
  2012-06-14 22:47 [PATCH][GIT PULL][v3.5] ftrace: Make all inline tags also include notrace Steven Rostedt
@ 2012-06-18  8:56 ` Ingo Molnar
  2012-06-18 12:25   ` Steven Rostedt
  0 siblings, 1 reply; 4+ messages in thread
From: Ingo Molnar @ 2012-06-18  8:56 UTC (permalink / raw)
  To: Steven Rostedt
  Cc: LKML, Ingo Molnar, Andrew Morton, Frederic Weisbecker,
	Fengguang Wu


* Steven Rostedt <rostedt@goodmis.org> wrote:

>     ftrace: Make all inline tags also include notrace
>     
>     Commit 5963e317b1 ftrace/x86: Do not change stacks in DEBUG when calling lockdep
>     prevented lockdep calls from the int3 breakpoint handler from reseting the
>     stack if a function that was called was in the process of being converted
>     for tracing and had a breakpoint on it.

That's now how we refer to commits ...

>     Commit 45959ee7 ftrace: Do not function trace inlined functions
>     only touched the 'inline' tags when CONFIG_OPMITIZE_INLINING was enabled.

neither this :-/

We tend to write it like this:

      Commit 45959ee7aa64 ("ftrace: Do not function trace 
      inlined functions") only touched the 'inline' tags when 
      CONFIG_OPMITIZE_INLINING was enabled.

Thanks,

	Ingo

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH][GIT PULL][v3.5] ftrace: Make all inline tags also include notrace
  2012-06-18  8:56 ` Ingo Molnar
@ 2012-06-18 12:25   ` Steven Rostedt
  2012-06-18 14:00     ` Ingo Molnar
  0 siblings, 1 reply; 4+ messages in thread
From: Steven Rostedt @ 2012-06-18 12:25 UTC (permalink / raw)
  To: Ingo Molnar
  Cc: LKML, Ingo Molnar, Andrew Morton, Frederic Weisbecker,
	Fengguang Wu

On Mon, 2012-06-18 at 10:56 +0200, Ingo Molnar wrote:
> * Steven Rostedt <rostedt@goodmis.org> wrote:
> 
> >     ftrace: Make all inline tags also include notrace
> >     
> >     Commit 5963e317b1 ftrace/x86: Do not change stacks in DEBUG when calling lockdep
> >     prevented lockdep calls from the int3 breakpoint handler from reseting the
> >     stack if a function that was called was in the process of being converted
> >     for tracing and had a breakpoint on it.
> 
> That's now how we refer to commits ...
> 
> >     Commit 45959ee7 ftrace: Do not function trace inlined functions
> >     only touched the 'inline' tags when CONFIG_OPMITIZE_INLINING was enabled.
> 
> neither this :-/
> 
> We tend to write it like this:
> 
>       Commit 45959ee7aa64 ("ftrace: Do not function trace 
>       inlined functions") only touched the 'inline' tags when 
>       CONFIG_OPMITIZE_INLINING was enabled.

This looks like something that should be added to SubmittingPatches.

Want me to rebase with a new changelog?

-- Steve



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH][GIT PULL][v3.5] ftrace: Make all inline tags also include notrace
  2012-06-18 12:25   ` Steven Rostedt
@ 2012-06-18 14:00     ` Ingo Molnar
  0 siblings, 0 replies; 4+ messages in thread
From: Ingo Molnar @ 2012-06-18 14:00 UTC (permalink / raw)
  To: Steven Rostedt
  Cc: LKML, Ingo Molnar, Andrew Morton, Frederic Weisbecker,
	Fengguang Wu


* Steven Rostedt <rostedt@goodmis.org> wrote:

> On Mon, 2012-06-18 at 10:56 +0200, Ingo Molnar wrote:
> > * Steven Rostedt <rostedt@goodmis.org> wrote:
> > 
> > >     ftrace: Make all inline tags also include notrace
> > >     
> > >     Commit 5963e317b1 ftrace/x86: Do not change stacks in DEBUG when calling lockdep
> > >     prevented lockdep calls from the int3 breakpoint handler from reseting the
> > >     stack if a function that was called was in the process of being converted
> > >     for tracing and had a breakpoint on it.
> > 
> > That's now how we refer to commits ...
> > 
> > >     Commit 45959ee7 ftrace: Do not function trace inlined functions
> > >     only touched the 'inline' tags when CONFIG_OPMITIZE_INLINING was enabled.
> > 
> > neither this :-/
> > 
> > We tend to write it like this:
> > 
> >       Commit 45959ee7aa64 ("ftrace: Do not function trace 
> >       inlined functions") only touched the 'inline' tags when 
> >       CONFIG_OPMITIZE_INLINING was enabled.
> 
> This looks like something that should be added to SubmittingPatches.
> 
> Want me to rebase with a new changelog?

Yeah, please do - the changelogs were rather hard to read as it 
was not clear where a commit title ends and where the original 
sentence continues.

Thanks,

	Ingo

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2012-06-18 14:01 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-06-14 22:47 [PATCH][GIT PULL][v3.5] ftrace: Make all inline tags also include notrace Steven Rostedt
2012-06-18  8:56 ` Ingo Molnar
2012-06-18 12:25   ` Steven Rostedt
2012-06-18 14:00     ` Ingo Molnar

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox