All of lore.kernel.org
 help / color / mirror / Atom feed
* [RFA][PATCH 00/27] ftrace: Remove ftrace_start/stop() and friends
@ 2014-06-26 16:52 ` Steven Rostedt
  0 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf

* Request for Acks *

>From the time I created the use of function_trace_stop, I hated it.
There was two reasons to create this, one was to try to lower the
function tracing overhead when debugfs file tracing_enable was set to zero
(note, tracing_enable no longer exists), the other was a way to stop
function tracing when going down into suspend and resume.

Some function was causing suspend and resume to reboot the kernel. In
debugging this I found that an empty callback from mcount would work.
That is, instead of running the tracing code, I would just have the
function trace callback be a nop:

 void function_trace_call(unsigned long ip, unsigned long parent_ip)
 {
 }

This worked. That means the code in mcount wasn't an issue. I started
bisecting the contents of the function_trace_call and found that this
would cause the system to reboot!

 void function_trace_call(unsigned long ip, unsigned long parent_ip)
 {
	smp_processor_id();
 }

That is, just calling smp_processor_id() was enough to trigger a triple
fault on resume of the system.

Today, this big hammer approach of disabling the function tracer is starting
to show its issues. It can't help out in debugging suspend and resume,
and there's other function trace callbacks that should still work.

I also have learned ways to bisect functions that cause bugs in function
tracing. I finally got some time to do so with a box that would reboot
on suspend and resume. This led me down to a single function:

 restore_processor_state()

This made perfect sense, as this function is called from assembly on a
CPU startup. One of the jobs of this function was to set up the GS register.
That register is also the register that is used by smp_processor_id()
to find what CPU the task is running on. With it not set up it will offset
into some random location and fault. As the fault handlers can also be
traced, those will fault too and finally the system will reset due to a
triple fault.

This is all being very specific to x86 of course. For other archs, I don't
have anything to test suspend on. But because the ftrace_stop() was added
because x86 was complaining, I'm removing it because x86 no longer complains.
If your arch exhibits problems with function tracing and suspend and resume
let me know and I can work with you in finding the functions that need to
be treated as notrace.

Anyway, as there is no more reason to set function_trace_stop it is time
to remove it. Unfortunately it's in several archs in assembly. Most of
the assembly looks rather straight forward and I removed them myself. But
I was only able to compile test them (for archs: arm64, metag, and microblaze
I do not have my cross tools set up for them and did not even compile test
it). But I would really love it if people can download their patch and test
it out. You only need the patches that go against your arch and to really
test it, also include the patch titled: 

 ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST

Otherwise your arch patch will call the list op that still does the check.
That is, if you want to test suspend and resume on your arch.

As you may see, there are patches to the ftrace infrastructure that depend
on the arch patches being implemented. I removed the functionality from
the infrastructure, then removed it from the archs, and then finally
removed the existence of the function_trace_stop variable, which would
cause the archs to fail to compile if that were to go first.

If you can test your arch and give me your acked-by, I would appreciate it.
Otherwise, if you need this to go through your tree, I would ask you
to set up a dedicated branch that I can pull from to keep this order intact.

Thanks!

-- Steve

Heiko Carstens (1):
      s390/ftrace: remove check of obsolete variable function_trace_stop

Steven Rostedt (Red Hat) (26):
      x86, power, suspend: Annotate restore_processor_state() with notrace
      PM / Sleep: Remove ftrace_stop/start() from suspend and hibernate
      tracing: Remove ftrace_stop/start() from reading the trace file
      ftrace-graph: Remove dependency of ftrace_stop() from ftrace_graph_stop()
      ftrace/x86: Add call to ftrace_graph_is_dead() in function graph code
      microblaze: ftrace: Add call to ftrace_graph_is_dead() in function graph code
      MIPS: ftrace: Add call to ftrace_graph_is_dead() in function graph code
      parisc: ftrace: Add call to ftrace_graph_is_dead() in function graph code
      powerpc/ftrace: Add call to ftrace_graph_is_dead() in function graph code
      sh: ftrace: Add call to ftrace_graph_is_dead() in function graph code
      ftrace-graph: Remove usage of ftrace_stop() in ftrace_graph_stop()
      ftrace: Remove ftrace_start/stop()
      ftrace: Do no disable function tracing on enabling function tracing
      ftrace: Remove function_trace_stop check from list func
      ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST
      ftrace: x86: Remove check of obsolete variable function_trace_stop
      tile: ftrace: Remove check of obsolete variable function_trace_stop
      sparc64,ftrace: Remove check of obsolete variable function_trace_stop
      sh: ftrace: Remove check of obsolete variable function_trace_stop
      parisc: ftrace: Remove check of obsolete variable function_trace_stop
      MIPS: ftrace: Remove check of obsolete variable function_trace_stop
      microblaze: ftrace: Remove check of obsolete variable function_trace_stop
      metag: ftrace: Remove check of obsolete variable function_trace_stop
      Blackfin: ftrace: Remove check of obsolete variable function_trace_stop
      arm64, ftrace: Remove check of obsolete variable function_trace_stop
      tracing: Remove function_trace_stop and HAVE_FUNCTION_TRACE_MCOUNT_TEST

----
 Documentation/trace/ftrace-design.txt | 26 --------------------------
 arch/arm64/kernel/entry-ftrace.S      |  5 -----
 arch/blackfin/Kconfig                 |  1 -
 arch/blackfin/kernel/ftrace-entry.S   | 18 ------------------
 arch/metag/Kconfig                    |  1 -
 arch/metag/kernel/ftrace_stub.S       | 14 --------------
 arch/microblaze/Kconfig               |  1 -
 arch/microblaze/kernel/ftrace.c       |  3 +++
 arch/microblaze/kernel/mcount.S       |  5 -----
 arch/mips/Kconfig                     |  1 -
 arch/mips/kernel/ftrace.c             |  3 +++
 arch/mips/kernel/mcount.S             |  7 -------
 arch/parisc/Kconfig                   |  1 -
 arch/parisc/kernel/ftrace.c           |  6 +++---
 arch/powerpc/kernel/ftrace.c          |  3 +++
 arch/s390/Kconfig                     |  1 -
 arch/s390/kernel/mcount.S             | 10 +++-------
 arch/s390/kernel/mcount64.S           |  3 ---
 arch/sh/Kconfig                       |  1 -
 arch/sh/kernel/ftrace.c               |  3 +++
 arch/sh/lib/mcount.S                  | 24 ++----------------------
 arch/sparc/Kconfig                    |  1 -
 arch/sparc/lib/mcount.S               | 10 ++--------
 arch/tile/Kconfig                     |  1 -
 arch/tile/kernel/mcount_64.S          | 18 ------------------
 arch/x86/Kconfig                      |  1 -
 arch/x86/kernel/entry_32.S            |  9 ---------
 arch/x86/kernel/ftrace.c              |  3 +++
 arch/x86/kernel/mcount_64.S           | 18 +-----------------
 arch/x86/power/cpu.c                  |  4 ++--
 include/linux/ftrace.h                | 34 ++--------------------------------
 kernel/power/hibernate.c              |  6 ------
 kernel/power/suspend.c                |  2 --
 kernel/trace/Kconfig                  |  5 -----
 kernel/trace/ftrace.c                 | 23 ++---------------------
 kernel/trace/trace.c                  |  2 --
 kernel/trace/trace_functions_graph.c  | 30 ++++++++++++++++++++++++++++++
 37 files changed, 62 insertions(+), 242 deletions(-)

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

* [RFA][PATCH 00/27] ftrace: Remove ftrace_start/stop() and friends
@ 2014-06-26 16:52 ` Steven Rostedt
  0 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf

* Request for Acks *

From the time I created the use of function_trace_stop, I hated it.
There was two reasons to create this, one was to try to lower the
function tracing overhead when debugfs file tracing_enable was set to zero
(note, tracing_enable no longer exists), the other was a way to stop
function tracing when going down into suspend and resume.

Some function was causing suspend and resume to reboot the kernel. In
debugging this I found that an empty callback from mcount would work.
That is, instead of running the tracing code, I would just have the
function trace callback be a nop:

 void function_trace_call(unsigned long ip, unsigned long parent_ip)
 {
 }

This worked. That means the code in mcount wasn't an issue. I started
bisecting the contents of the function_trace_call and found that this
would cause the system to reboot!

 void function_trace_call(unsigned long ip, unsigned long parent_ip)
 {
	smp_processor_id();
 }

That is, just calling smp_processor_id() was enough to trigger a triple
fault on resume of the system.

Today, this big hammer approach of disabling the function tracer is starting
to show its issues. It can't help out in debugging suspend and resume,
and there's other function trace callbacks that should still work.

I also have learned ways to bisect functions that cause bugs in function
tracing. I finally got some time to do so with a box that would reboot
on suspend and resume. This led me down to a single function:

 restore_processor_state()

This made perfect sense, as this function is called from assembly on a
CPU startup. One of the jobs of this function was to set up the GS register.
That register is also the register that is used by smp_processor_id()
to find what CPU the task is running on. With it not set up it will offset
into some random location and fault. As the fault handlers can also be
traced, those will fault too and finally the system will reset due to a
triple fault.

This is all being very specific to x86 of course. For other archs, I don't
have anything to test suspend on. But because the ftrace_stop() was added
because x86 was complaining, I'm removing it because x86 no longer complains.
If your arch exhibits problems with function tracing and suspend and resume
let me know and I can work with you in finding the functions that need to
be treated as notrace.

Anyway, as there is no more reason to set function_trace_stop it is time
to remove it. Unfortunately it's in several archs in assembly. Most of
the assembly looks rather straight forward and I removed them myself. But
I was only able to compile test them (for archs: arm64, metag, and microblaze
I do not have my cross tools set up for them and did not even compile test
it). But I would really love it if people can download their patch and test
it out. You only need the patches that go against your arch and to really
test it, also include the patch titled: 

 ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST

Otherwise your arch patch will call the list op that still does the check.
That is, if you want to test suspend and resume on your arch.

As you may see, there are patches to the ftrace infrastructure that depend
on the arch patches being implemented. I removed the functionality from
the infrastructure, then removed it from the archs, and then finally
removed the existence of the function_trace_stop variable, which would
cause the archs to fail to compile if that were to go first.

If you can test your arch and give me your acked-by, I would appreciate it.
Otherwise, if you need this to go through your tree, I would ask you
to set up a dedicated branch that I can pull from to keep this order intact.

Thanks!

-- Steve

Heiko Carstens (1):
      s390/ftrace: remove check of obsolete variable function_trace_stop

Steven Rostedt (Red Hat) (26):
      x86, power, suspend: Annotate restore_processor_state() with notrace
      PM / Sleep: Remove ftrace_stop/start() from suspend and hibernate
      tracing: Remove ftrace_stop/start() from reading the trace file
      ftrace-graph: Remove dependency of ftrace_stop() from ftrace_graph_stop()
      ftrace/x86: Add call to ftrace_graph_is_dead() in function graph code
      microblaze: ftrace: Add call to ftrace_graph_is_dead() in function graph code
      MIPS: ftrace: Add call to ftrace_graph_is_dead() in function graph code
      parisc: ftrace: Add call to ftrace_graph_is_dead() in function graph code
      powerpc/ftrace: Add call to ftrace_graph_is_dead() in function graph code
      sh: ftrace: Add call to ftrace_graph_is_dead() in function graph code
      ftrace-graph: Remove usage of ftrace_stop() in ftrace_graph_stop()
      ftrace: Remove ftrace_start/stop()
      ftrace: Do no disable function tracing on enabling function tracing
      ftrace: Remove function_trace_stop check from list func
      ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST
      ftrace: x86: Remove check of obsolete variable function_trace_stop
      tile: ftrace: Remove check of obsolete variable function_trace_stop
      sparc64,ftrace: Remove check of obsolete variable function_trace_stop
      sh: ftrace: Remove check of obsolete variable function_trace_stop
      parisc: ftrace: Remove check of obsolete variable function_trace_stop
      MIPS: ftrace: Remove check of obsolete variable function_trace_stop
      microblaze: ftrace: Remove check of obsolete variable function_trace_stop
      metag: ftrace: Remove check of obsolete variable function_trace_stop
      Blackfin: ftrace: Remove check of obsolete variable function_trace_stop
      arm64, ftrace: Remove check of obsolete variable function_trace_stop
      tracing: Remove function_trace_stop and HAVE_FUNCTION_TRACE_MCOUNT_TEST

----
 Documentation/trace/ftrace-design.txt | 26 --------------------------
 arch/arm64/kernel/entry-ftrace.S      |  5 -----
 arch/blackfin/Kconfig                 |  1 -
 arch/blackfin/kernel/ftrace-entry.S   | 18 ------------------
 arch/metag/Kconfig                    |  1 -
 arch/metag/kernel/ftrace_stub.S       | 14 --------------
 arch/microblaze/Kconfig               |  1 -
 arch/microblaze/kernel/ftrace.c       |  3 +++
 arch/microblaze/kernel/mcount.S       |  5 -----
 arch/mips/Kconfig                     |  1 -
 arch/mips/kernel/ftrace.c             |  3 +++
 arch/mips/kernel/mcount.S             |  7 -------
 arch/parisc/Kconfig                   |  1 -
 arch/parisc/kernel/ftrace.c           |  6 +++---
 arch/powerpc/kernel/ftrace.c          |  3 +++
 arch/s390/Kconfig                     |  1 -
 arch/s390/kernel/mcount.S             | 10 +++-------
 arch/s390/kernel/mcount64.S           |  3 ---
 arch/sh/Kconfig                       |  1 -
 arch/sh/kernel/ftrace.c               |  3 +++
 arch/sh/lib/mcount.S                  | 24 ++----------------------
 arch/sparc/Kconfig                    |  1 -
 arch/sparc/lib/mcount.S               | 10 ++--------
 arch/tile/Kconfig                     |  1 -
 arch/tile/kernel/mcount_64.S          | 18 ------------------
 arch/x86/Kconfig                      |  1 -
 arch/x86/kernel/entry_32.S            |  9 ---------
 arch/x86/kernel/ftrace.c              |  3 +++
 arch/x86/kernel/mcount_64.S           | 18 +-----------------
 arch/x86/power/cpu.c                  |  4 ++--
 include/linux/ftrace.h                | 34 ++--------------------------------
 kernel/power/hibernate.c              |  6 ------
 kernel/power/suspend.c                |  2 --
 kernel/trace/Kconfig                  |  5 -----
 kernel/trace/ftrace.c                 | 23 ++---------------------
 kernel/trace/trace.c                  |  2 --
 kernel/trace/trace_functions_graph.c  | 30 ++++++++++++++++++++++++++++++
 37 files changed, 62 insertions(+), 242 deletions(-)

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

* [RFA][PATCH 01/27] x86, power, suspend: Annotate restore_processor_state() with notrace
  2014-06-26 16:52 ` Steven Rostedt
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  2014-06-28  0:02   ` Rafael J. Wysocki
  -1 siblings, 1 reply; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf

[-- Attachment #1: 0001-x86-power-suspend-Annotate-restore_processor_state-w.patch --]
[-- Type: text/plain, Size: 2325 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

ftrace_stop() is used to stop function tracing during suspend and resume
which removes a lot of possible debugging opportunities with tracing.
The reason was that some function in the resume path was causing a triple
fault if it were to be traced. The issue I found was that doing something
as simple as calling smp_processor_id() would reboot the box!

When function tracing was first created I didn't have a good way to figure
out what function was having issues, or it looked to be multiple ones. To
fix it, we just created a big hammer approach to the problem which was to
add a flag in the mcount trampoline that could be checked and not call
the traced functions.

Lately I developed better ways to find problem functions and I can bisect
down to see what function is causing the issue. I removed the flag that
stopped tracing and proceeded to find the problem function and it ended
up being restore_processor_state(). This function makes sense as when the
CPU comes back online from a suspend it calls this function to set up
registers, amongst them the GS register, which stores things such as
what CPU the processor is (if you call smp_processor_id() without this
set up properly, it would fault).

By making restore_processor_state() notrace, the system can suspend and
resume without the need of the big hammer tracing to stop.

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 arch/x86/power/cpu.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/x86/power/cpu.c b/arch/x86/power/cpu.c
index 424f4c97a44d..6ec7910f59bf 100644
--- a/arch/x86/power/cpu.c
+++ b/arch/x86/power/cpu.c
@@ -165,7 +165,7 @@ static void fix_processor_context(void)
  *		by __save_processor_state()
  *	@ctxt - structure to load the registers contents from
  */
-static void __restore_processor_state(struct saved_context *ctxt)
+static void notrace __restore_processor_state(struct saved_context *ctxt)
 {
 	if (ctxt->misc_enable_saved)
 		wrmsrl(MSR_IA32_MISC_ENABLE, ctxt->misc_enable);
@@ -239,7 +239,7 @@ static void __restore_processor_state(struct saved_context *ctxt)
 }
 
 /* Needed by apm.c */
-void restore_processor_state(void)
+void notrace restore_processor_state(void)
 {
 	__restore_processor_state(&saved_context);
 }
-- 
2.0.0



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

* [RFA][PATCH 02/27] PM / Sleep: Remove ftrace_stop/start() from suspend and hibernate
  2014-06-26 16:52 ` Steven Rostedt
  (?)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  2014-06-28  0:02   ` Rafael J. Wysocki
  -1 siblings, 1 reply; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf

[-- Attachment #1: 0002-PM-Sleep-Remove-ftrace_stop-start-from-suspend-and-h.patch --]
[-- Type: text/plain, Size: 2767 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

ftrace_stop() and ftrace_start() were added to the suspend and hibernate
process because there was some function within the work flow that caused
the system to reboot if it was traced. This function has recently been
found (restore_processor_state()). Now there's no reason to disable
function tracing while we are going into suspend or hibernate, which means
that being able to trace this will help tremendously in debugging any
issues with suspend or hibernate.

This also means that the ftrace_stop/start() functions can be removed
and simplify the function tracing code a bit.

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 kernel/power/hibernate.c | 6 ------
 kernel/power/suspend.c   | 2 --
 2 files changed, 8 deletions(-)

diff --git a/kernel/power/hibernate.c b/kernel/power/hibernate.c
index 49e0a20fd010..ca7b1906c6c8 100644
--- a/kernel/power/hibernate.c
+++ b/kernel/power/hibernate.c
@@ -365,7 +365,6 @@ int hibernation_snapshot(int platform_mode)
 	}
 
 	suspend_console();
-	ftrace_stop();
 	pm_restrict_gfp_mask();
 
 	error = dpm_suspend(PMSG_FREEZE);
@@ -391,7 +390,6 @@ int hibernation_snapshot(int platform_mode)
 	if (error || !in_suspend)
 		pm_restore_gfp_mask();
 
-	ftrace_start();
 	resume_console();
 	dpm_complete(msg);
 
@@ -494,7 +492,6 @@ int hibernation_restore(int platform_mode)
 
 	pm_prepare_console();
 	suspend_console();
-	ftrace_stop();
 	pm_restrict_gfp_mask();
 	error = dpm_suspend_start(PMSG_QUIESCE);
 	if (!error) {
@@ -502,7 +499,6 @@ int hibernation_restore(int platform_mode)
 		dpm_resume_end(PMSG_RECOVER);
 	}
 	pm_restore_gfp_mask();
-	ftrace_start();
 	resume_console();
 	pm_restore_console();
 	return error;
@@ -529,7 +525,6 @@ int hibernation_platform_enter(void)
 
 	entering_platform_hibernation = true;
 	suspend_console();
-	ftrace_stop();
 	error = dpm_suspend_start(PMSG_HIBERNATE);
 	if (error) {
 		if (hibernation_ops->recover)
@@ -573,7 +568,6 @@ int hibernation_platform_enter(void)
  Resume_devices:
 	entering_platform_hibernation = false;
 	dpm_resume_end(PMSG_RESTORE);
-	ftrace_start();
 	resume_console();
 
  Close:
diff --git a/kernel/power/suspend.c b/kernel/power/suspend.c
index 4dd8822f732a..f6623da034d8 100644
--- a/kernel/power/suspend.c
+++ b/kernel/power/suspend.c
@@ -248,7 +248,6 @@ static int suspend_enter(suspend_state_t state, bool *wakeup)
 		goto Platform_wake;
 	}
 
-	ftrace_stop();
 	error = disable_nonboot_cpus();
 	if (error || suspend_test(TEST_CPUS))
 		goto Enable_cpus;
@@ -275,7 +274,6 @@ static int suspend_enter(suspend_state_t state, bool *wakeup)
 
  Enable_cpus:
 	enable_nonboot_cpus();
-	ftrace_start();
 
  Platform_wake:
 	if (need_suspend_ops(state) && suspend_ops->wake)
-- 
2.0.0



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

* [RFA][PATCH 03/27] tracing: Remove ftrace_stop/start() from reading the trace file
  2014-06-26 16:52 ` Steven Rostedt
                   ` (2 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  -1 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf

[-- Attachment #1: 0003-tracing-Remove-ftrace_stop-start-from-reading-the-tr.patch --]
[-- Type: text/plain, Size: 1000 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

Disabling reading and writing to the trace file should not be able to
disable all function tracing callbacks. There's other users today
(like kprobes and perf). Reading a trace file should not stop those
from happening.

Cc: stable@vger.kernel.org # 3.0+
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 kernel/trace/trace.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c
index eeb233cbac4f..433a50ffc73e 100644
--- a/kernel/trace/trace.c
+++ b/kernel/trace/trace.c
@@ -1372,7 +1372,6 @@ void tracing_start(void)
 
 	arch_spin_unlock(&global_trace.max_lock);
 
-	ftrace_start();
  out:
 	raw_spin_unlock_irqrestore(&global_trace.start_lock, flags);
 }
@@ -1419,7 +1418,6 @@ void tracing_stop(void)
 	struct ring_buffer *buffer;
 	unsigned long flags;
 
-	ftrace_stop();
 	raw_spin_lock_irqsave(&global_trace.start_lock, flags);
 	if (global_trace.stop_count++)
 		goto out;
-- 
2.0.0



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

* [RFA][PATCH 04/27] ftrace-graph: Remove dependency of ftrace_stop() from ftrace_graph_stop()
  2014-06-26 16:52 ` Steven Rostedt
                   ` (3 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  -1 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf, Frederic Weisbecker

[-- Attachment #1: 0004-ftrace-graph-Remove-dependency-of-ftrace_stop-from-f.patch --]
[-- Type: text/plain, Size: 3453 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

ftrace_stop() is going away as it disables parts of function tracing
that affects users that should not be affected. But ftrace_graph_stop()
is built on ftrace_stop(). Here's another example of killing all of
function tracing because something went wrong with function graph
tracing.

Instead of disabling all users of function tracing on function graph
error, disable only function graph tracing.

A new function is created called ftrace_graph_is_dead(). This is called
in strategic paths to prevent function graph from doing more harm and
allowing at least a warning to be printed before the system crashes.

NOTE: ftrace_stop() is still used until all the archs are converted over
to use ftrace_graph_is_dead(). After that, ftrace_stop() will be removed.

Cc: Frederic Weisbecker <fweisbec@gmail.com>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 include/linux/ftrace.h               |  1 +
 kernel/trace/ftrace.c                |  5 -----
 kernel/trace/trace_functions_graph.c | 35 +++++++++++++++++++++++++++++++++++
 3 files changed, 36 insertions(+), 5 deletions(-)

diff --git a/include/linux/ftrace.h b/include/linux/ftrace.h
index 11e18fd58b1a..ec059c343e78 100644
--- a/include/linux/ftrace.h
+++ b/include/linux/ftrace.h
@@ -750,6 +750,7 @@ extern char __irqentry_text_end[];
 extern int register_ftrace_graph(trace_func_graph_ret_t retfunc,
 				trace_func_graph_ent_t entryfunc);
 
+extern bool ftrace_graph_is_dead(void);
 extern void ftrace_graph_stop(void);
 
 /* The current handlers in use */
diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c
index 3a6d44c76af7..823984c20262 100644
--- a/kernel/trace/ftrace.c
+++ b/kernel/trace/ftrace.c
@@ -5439,9 +5439,4 @@ void ftrace_graph_exit_task(struct task_struct *t)
 
 	kfree(ret_stack);
 }
-
-void ftrace_graph_stop(void)
-{
-	ftrace_stop();
-}
 #endif
diff --git a/kernel/trace/trace_functions_graph.c b/kernel/trace/trace_functions_graph.c
index 4de3e57f723c..3604690be70b 100644
--- a/kernel/trace/trace_functions_graph.c
+++ b/kernel/trace/trace_functions_graph.c
@@ -15,6 +15,38 @@
 #include "trace.h"
 #include "trace_output.h"
 
+static bool kill_ftrace_graph;
+
+/**
+ * ftrace_graph_is_dead - returns true if ftrace_graph_stop() was called
+ *
+ * ftrace_graph_stop() is called when a severe error is detected in
+ * the function graph tracing. This function is called by the critical
+ * paths of function graph to keep those paths from doing any more harm.
+ */
+bool ftrace_graph_is_dead(void)
+{
+	return kill_ftrace_graph;
+}
+
+/**
+ * ftrace_graph_stop - set to permanently disable function graph tracincg
+ *
+ * In case of an error int function graph tracing, this is called
+ * to try to keep function graph tracing from causing any more harm.
+ * Usually this is pretty severe and this is called to try to at least
+ * get a warning out to the user.
+ */
+void ftrace_graph_stop(void)
+{
+	kill_ftrace_graph = true;
+	/*
+	 * ftrace_stop() will be removed when all archs are updated to
+	 * use ftrace_graph_is_dead()
+	 */
+	ftrace_stop();
+}
+
 /* When set, irq functions will be ignored */
 static int ftrace_graph_skip_irqs;
 
@@ -92,6 +124,9 @@ ftrace_push_return_trace(unsigned long ret, unsigned long func, int *depth,
 	unsigned long long calltime;
 	int index;
 
+	if (unlikely(ftrace_graph_is_dead()))
+		return -EBUSY;
+
 	if (!current->ret_stack)
 		return -EBUSY;
 
-- 
2.0.0



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

* [RFA][PATCH 05/27] ftrace/x86: Add call to ftrace_graph_is_dead() in function graph code
  2014-06-26 16:52 ` Steven Rostedt
                   ` (4 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  2014-07-15 15:47   ` H. Peter Anvin
  -1 siblings, 1 reply; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf

[-- Attachment #1: 0005-ftrace-x86-Add-call-to-ftrace_graph_is_dead-in-funct.patch --]
[-- Type: text/plain, Size: 1185 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

ftrace_stop() is going away as it disables parts of function tracing
that affects users that should not be affected. But ftrace_graph_stop()
is built on ftrace_stop(). Here's another example of killing all of
function tracing because something went wrong with function graph
tracing.

Instead of disabling all users of function tracing on function graph
error, disable only function graph tracing. To do this, the arch code
must call ftrace_graph_is_dead() before it implements function graph.

Cc: H. Peter Anvin <hpa@zytor.com>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 arch/x86/kernel/ftrace.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/arch/x86/kernel/ftrace.c b/arch/x86/kernel/ftrace.c
index cbc4a91b131e..3386dc9aa333 100644
--- a/arch/x86/kernel/ftrace.c
+++ b/arch/x86/kernel/ftrace.c
@@ -703,6 +703,9 @@ void prepare_ftrace_return(unsigned long *parent, unsigned long self_addr,
 	unsigned long return_hooker = (unsigned long)
 				&return_to_handler;
 
+	if (unlikely(ftrace_graph_is_dead()))
+		return;
+
 	if (unlikely(atomic_read(&current->tracing_graph_pause)))
 		return;
 
-- 
2.0.0



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

* [RFA][PATCH 06/27] microblaze: ftrace: Add call to ftrace_graph_is_dead() in function graph code
  2014-06-26 16:52 ` Steven Rostedt
                   ` (5 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  2014-07-03 16:34   ` Steven Rostedt
  2014-07-09 14:03   ` Steven Rostedt
  -1 siblings, 2 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf, Michal Simek

[-- Attachment #1: 0006-microblaze-ftrace-Add-call-to-ftrace_graph_is_dead-i.patch --]
[-- Type: text/plain, Size: 1219 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

ftrace_stop() is going away as it disables parts of function tracing
that affects users that should not be affected. But ftrace_graph_stop()
is built on ftrace_stop(). Here's another example of killing all of
function tracing because something went wrong with function graph
tracing.

Instead of disabling all users of function tracing on function graph
error, disable only function graph tracing. To do this, the arch code
must call ftrace_graph_is_dead() before it implements function graph.

Cc: Michal Simek <monstr@monstr.eu>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 arch/microblaze/kernel/ftrace.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/arch/microblaze/kernel/ftrace.c b/arch/microblaze/kernel/ftrace.c
index bbcd2533766c..fc7b48a52cd5 100644
--- a/arch/microblaze/kernel/ftrace.c
+++ b/arch/microblaze/kernel/ftrace.c
@@ -27,6 +27,9 @@ void prepare_ftrace_return(unsigned long *parent, unsigned long self_addr)
 	unsigned long return_hooker = (unsigned long)
 				&return_to_handler;
 
+	if (unlikely(ftrace_graph_is_dead()))
+		return;
+
 	if (unlikely(atomic_read(&current->tracing_graph_pause)))
 		return;
 
-- 
2.0.0



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

* [RFA][PATCH 07/27] MIPS: ftrace: Add call to ftrace_graph_is_dead() in function graph code
  2014-06-26 16:52 ` Steven Rostedt
                   ` (6 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  2014-07-02 14:31   ` Steven Rostedt
  2014-07-03 16:36   ` Steven Rostedt
  -1 siblings, 2 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf, Ralf Baechle

[-- Attachment #1: 0007-MIPS-ftrace-Add-call-to-ftrace_graph_is_dead-in-func.patch --]
[-- Type: text/plain, Size: 1175 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

ftrace_stop() is going away as it disables parts of function tracing
that affects users that should not be affected. But ftrace_graph_stop()
is built on ftrace_stop(). Here's another example of killing all of
function tracing because something went wrong with function graph
tracing.

Instead of disabling all users of function tracing on function graph
error, disable only function graph tracing. To do this, the arch code
must call ftrace_graph_is_dead() before it implements function graph.

Cc: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 arch/mips/kernel/ftrace.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/arch/mips/kernel/ftrace.c b/arch/mips/kernel/ftrace.c
index 60e7e5e45af1..8b6538750fe1 100644
--- a/arch/mips/kernel/ftrace.c
+++ b/arch/mips/kernel/ftrace.c
@@ -302,6 +302,9 @@ void prepare_ftrace_return(unsigned long *parent_ra_addr, unsigned long self_ra,
 	    &return_to_handler;
 	int faulted, insns;
 
+	if (unlikely(ftrace_graph_is_dead()))
+		return;
+
 	if (unlikely(atomic_read(&current->tracing_graph_pause)))
 		return;
 
-- 
2.0.0



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

* [RFA][PATCH 08/27] parisc: ftrace: Add call to ftrace_graph_is_dead() in function graph code
  2014-06-26 16:52 ` Steven Rostedt
                   ` (7 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  -1 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf, Helge Deller, Kyle McMartin

[-- Attachment #1: 0008-parisc-ftrace-Add-call-to-ftrace_graph_is_dead-in-fu.patch --]
[-- Type: text/plain, Size: 1226 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

ftrace_stop() is going away as it disables parts of function tracing
that affects users that should not be affected. But ftrace_graph_stop()
is built on ftrace_stop(). Here's another example of killing all of
function tracing because something went wrong with function graph
tracing.

Instead of disabling all users of function tracing on function graph
error, disable only function graph tracing. To do this, the arch code
must call ftrace_graph_is_dead() before it implements function graph.

Cc: Helge Deller <deller@gmx.de>
Cc: Kyle McMartin <kyle@mcmartin.ca>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 arch/parisc/kernel/ftrace.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/arch/parisc/kernel/ftrace.c b/arch/parisc/kernel/ftrace.c
index 5beb97bafbb1..5512ab32c5e0 100644
--- a/arch/parisc/kernel/ftrace.c
+++ b/arch/parisc/kernel/ftrace.c
@@ -112,6 +112,9 @@ void prepare_ftrace_return(unsigned long *parent, unsigned long self_addr)
 	unsigned long long calltime;
 	struct ftrace_graph_ent trace;
 
+	if (unlikely(ftrace_graph_is_dead()))
+		return;
+
 	if (unlikely(atomic_read(&current->tracing_graph_pause)))
 		return;
 
-- 
2.0.0



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

* [RFA][PATCH 09/27] powerpc/ftrace: Add call to ftrace_graph_is_dead() in function graph code
  2014-06-26 16:52 ` Steven Rostedt
                   ` (8 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  2014-07-09 14:04   ` Steven Rostedt
  -1 siblings, 1 reply; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf, Anton Blanchard, Benjamin Herrenschmidt

[-- Attachment #1: 0009-powerpc-ftrace-Add-call-to-ftrace_graph_is_dead-in-f.patch --]
[-- Type: text/plain, Size: 1289 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

ftrace_stop() is going away as it disables parts of function tracing
that affects users that should not be affected. But ftrace_graph_stop()
is built on ftrace_stop(). Here's another example of killing all of
function tracing because something went wrong with function graph
tracing.

Instead of disabling all users of function tracing on function graph
error, disable only function graph tracing. To do this, the arch code
must call ftrace_graph_is_dead() before it implements function graph.

Cc: Anton Blanchard <anton@samba.org>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 arch/powerpc/kernel/ftrace.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/arch/powerpc/kernel/ftrace.c b/arch/powerpc/kernel/ftrace.c
index f202d0731b06..f8c0ce5523a5 100644
--- a/arch/powerpc/kernel/ftrace.c
+++ b/arch/powerpc/kernel/ftrace.c
@@ -527,6 +527,9 @@ void prepare_ftrace_return(unsigned long *parent, unsigned long self_addr)
 	struct ftrace_graph_ent trace;
 	unsigned long return_hooker = (unsigned long)&return_to_handler;
 
+	if (unlikely(ftrace_graph_is_dead()))
+		return;
+
 	if (unlikely(atomic_read(&current->tracing_graph_pause)))
 		return;
 
-- 
2.0.0



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

* [RFA][PATCH 10/27] sh: ftrace: Add call to ftrace_graph_is_dead() in function graph code
  2014-06-26 16:52 ` Steven Rostedt
                   ` (9 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  -1 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf, Paul Mundt

[-- Attachment #1: 0010-sh-ftrace-Add-call-to-ftrace_graph_is_dead-in-functi.patch --]
[-- Type: text/plain, Size: 1209 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

ftrace_stop() is going away as it disables parts of function tracing
that affects users that should not be affected. But ftrace_graph_stop()
is built on ftrace_stop(). Here's another example of killing all of
function tracing because something went wrong with function graph
tracing.

Instead of disabling all users of function tracing on function graph
error, disable only function graph tracing. To do this, the arch code
must call ftrace_graph_is_dead() before it implements function graph.

Cc: Paul Mundt <lethal@linux-sh.org>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 arch/sh/kernel/ftrace.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/arch/sh/kernel/ftrace.c b/arch/sh/kernel/ftrace.c
index 3c74f53db6db..079d70e6d74b 100644
--- a/arch/sh/kernel/ftrace.c
+++ b/arch/sh/kernel/ftrace.c
@@ -344,6 +344,9 @@ void prepare_ftrace_return(unsigned long *parent, unsigned long self_addr)
 	struct ftrace_graph_ent trace;
 	unsigned long return_hooker = (unsigned long)&return_to_handler;
 
+	if (unlikely(ftrace_graph_is_dead()))
+		return;
+
 	if (unlikely(atomic_read(&current->tracing_graph_pause)))
 		return;
 
-- 
2.0.0



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

* [RFA][PATCH 11/27] ftrace-graph: Remove usage of ftrace_stop() in ftrace_graph_stop()
  2014-06-26 16:52 ` Steven Rostedt
                   ` (10 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  -1 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf, Frederic Weisbecker

[-- Attachment #1: 0011-ftrace-graph-Remove-usage-of-ftrace_stop-in-ftrace_g.patch --]
[-- Type: text/plain, Size: 891 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

All archs now use ftrace_graph_is_dead() to stop function graph
tracing. Remove the usage of ftrace_stop() as that is no longer
needed.

Cc: Frederic Weisbecker <fweisbec@gmail.com>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 kernel/trace/trace_functions_graph.c | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/kernel/trace/trace_functions_graph.c b/kernel/trace/trace_functions_graph.c
index 3604690be70b..2c944e6c4a9d 100644
--- a/kernel/trace/trace_functions_graph.c
+++ b/kernel/trace/trace_functions_graph.c
@@ -40,11 +40,6 @@ bool ftrace_graph_is_dead(void)
 void ftrace_graph_stop(void)
 {
 	kill_ftrace_graph = true;
-	/*
-	 * ftrace_stop() will be removed when all archs are updated to
-	 * use ftrace_graph_is_dead()
-	 */
-	ftrace_stop();
 }
 
 /* When set, irq functions will be ignored */
-- 
2.0.0



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

* [RFA][PATCH 12/27] ftrace: Remove ftrace_start/stop()
  2014-06-26 16:52 ` Steven Rostedt
                   ` (11 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  -1 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf

[-- Attachment #1: 0012-ftrace-Remove-ftrace_start-stop.patch --]
[-- Type: text/plain, Size: 1795 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

There are no more kernel users of ftrace_stop() and ftrace_start().
Remove them.

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 include/linux/ftrace.h | 28 ----------------------------
 1 file changed, 28 deletions(-)

diff --git a/include/linux/ftrace.h b/include/linux/ftrace.h
index ec059c343e78..d74a37d53271 100644
--- a/include/linux/ftrace.h
+++ b/include/linux/ftrace.h
@@ -143,32 +143,6 @@ enum ftrace_tracing_type_t {
 /* Current tracing type, default is FTRACE_TYPE_ENTER */
 extern enum ftrace_tracing_type_t ftrace_tracing_type;
 
-/**
- * ftrace_stop - stop function tracer.
- *
- * A quick way to stop the function tracer. Note this an on off switch,
- * it is not something that is recursive like preempt_disable.
- * This does not disable the calling of mcount, it only stops the
- * calling of functions from mcount.
- */
-static inline void ftrace_stop(void)
-{
-	function_trace_stop = 1;
-}
-
-/**
- * ftrace_start - start the function tracer.
- *
- * This function is the inverse of ftrace_stop. This does not enable
- * the function tracing if the function tracer is disabled. This only
- * sets the function tracer flag to continue calling the functions
- * from mcount.
- */
-static inline void ftrace_start(void)
-{
-	function_trace_stop = 0;
-}
-
 /*
  * The ftrace_ops must be a static and should also
  * be read_mostly.  These functions do modify read_mostly variables
@@ -245,8 +219,6 @@ static inline int ftrace_nr_registered_ops(void)
 }
 static inline void clear_ftrace_function(void) { }
 static inline void ftrace_kill(void) { }
-static inline void ftrace_stop(void) { }
-static inline void ftrace_start(void) { }
 #endif /* CONFIG_FUNCTION_TRACER */
 
 #ifdef CONFIG_STACK_TRACER
-- 
2.0.0



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

* [RFA][PATCH 13/27] ftrace: Do no disable function tracing on enabling function tracing
  2014-06-26 16:52 ` Steven Rostedt
                   ` (12 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  -1 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf

[-- Attachment #1: 0013-ftrace-Do-no-disable-function-tracing-on-enabling-fu.patch --]
[-- Type: text/plain, Size: 1123 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

When function tracing is being updated function_trace_stop is set to
keep from tracing the updates. This was fine when function tracing
was done from stop machine. But it is no longer done that way and
this can cause real tracing to be missed.

Remove it.

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 kernel/trace/ftrace.c | 7 -------
 1 file changed, 7 deletions(-)

diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c
index 823984c20262..1e4e9bbb8dfa 100644
--- a/kernel/trace/ftrace.c
+++ b/kernel/trace/ftrace.c
@@ -2260,11 +2260,6 @@ static void ftrace_run_update_code(int command)
 	FTRACE_WARN_ON(ret);
 	if (ret)
 		return;
-	/*
-	 * Do not call function tracer while we update the code.
-	 * We are in stop machine.
-	 */
-	function_trace_stop++;
 
 	/*
 	 * By default we use stop_machine() to modify the code.
@@ -2274,8 +2269,6 @@ static void ftrace_run_update_code(int command)
 	 */
 	arch_ftrace_update_code(command);
 
-	function_trace_stop--;
-
 	ret = ftrace_arch_code_modify_post_process();
 	FTRACE_WARN_ON(ret);
 
-- 
2.0.0



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

* [RFA][PATCH 14/27] ftrace: Remove function_trace_stop check from list func
  2014-06-26 16:52 ` Steven Rostedt
                   ` (13 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  -1 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf

[-- Attachment #1: 0014-ftrace-Remove-function_trace_stop-check-from-list-fu.patch --]
[-- Type: text/plain, Size: 1274 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

function_trace_stop is no longer used to stop function tracing.
Remove the check from __ftrace_ops_list_func().

Also, call FTRACE_WARN_ON() instead of setting function_trace_stop
if a ops has no func to call.

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 kernel/trace/ftrace.c | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)

diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c
index 1e4e9bbb8dfa..34994885bb1d 100644
--- a/kernel/trace/ftrace.c
+++ b/kernel/trace/ftrace.c
@@ -4692,9 +4692,6 @@ __ftrace_ops_list_func(unsigned long ip, unsigned long parent_ip,
 	struct ftrace_ops *op;
 	int bit;
 
-	if (function_trace_stop)
-		return;
-
 	bit = trace_test_and_set_recursion(TRACE_LIST_START, TRACE_LIST_MAX);
 	if (bit < 0)
 		return;
@@ -4706,9 +4703,8 @@ __ftrace_ops_list_func(unsigned long ip, unsigned long parent_ip,
 	preempt_disable_notrace();
 	do_for_each_ftrace_op(op, ftrace_ops_list) {
 		if (ftrace_ops_test(op, ip, regs)) {
-			if (WARN_ON(!op->func)) {
-				function_trace_stop = 1;
-				printk("op=%p %pS\n", op, op);
+			if (FTRACE_WARN_ON(!op->func)) {
+				pr_warn("op=%p %pS\n", op, op);
 				goto out;
 			}
 			op->func(ip, parent_ip, op, regs);
-- 
2.0.0



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

* [RFA][PATCH 15/27] ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST
  2014-06-26 16:52 ` Steven Rostedt
                   ` (14 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  -1 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf

[-- Attachment #1: 0015-ftrace-Remove-check-for-HAVE_FUNCTION_TRACE_MCOUNT_T.patch --]
[-- Type: text/plain, Size: 2421 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

function_trace_stop is no longer used to disable function tracing.
This means that archs are no longer limited if it does not support
checking this variable in the mcount trampoline.

No need to use the list_func for archs that do not support this
obsolete method.

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 Documentation/trace/ftrace-design.txt | 26 --------------------------
 include/linux/ftrace.h                |  3 +--
 2 files changed, 1 insertion(+), 28 deletions(-)

diff --git a/Documentation/trace/ftrace-design.txt b/Documentation/trace/ftrace-design.txt
index 3f669b9e8852..dd5f916b351d 100644
--- a/Documentation/trace/ftrace-design.txt
+++ b/Documentation/trace/ftrace-design.txt
@@ -102,30 +102,6 @@ extern void mcount(void);
 EXPORT_SYMBOL(mcount);
 
 
-HAVE_FUNCTION_TRACE_MCOUNT_TEST
--------------------------------
-
-This is an optional optimization for the normal case when tracing is turned off
-in the system.  If you do not enable this Kconfig option, the common ftrace
-code will take care of doing the checking for you.
-
-To support this feature, you only need to check the function_trace_stop
-variable in the mcount function.  If it is non-zero, there is no tracing to be
-done at all, so you can return.
-
-This additional pseudo code would simply be:
-void mcount(void)
-{
-	/* save any bare state needed in order to do initial checking */
-
-+	if (function_trace_stop)
-+		return;
-
-	extern void (*ftrace_trace_function)(unsigned long, unsigned long);
-	if (ftrace_trace_function != ftrace_stub)
-...
-
-
 HAVE_FUNCTION_GRAPH_TRACER
 --------------------------
 
@@ -328,8 +304,6 @@ void mcount(void)
 
 void ftrace_caller(void)
 {
-	/* implement HAVE_FUNCTION_TRACE_MCOUNT_TEST if you desire */
-
 	/* save all state needed by the ABI (see paragraph above) */
 
 	unsigned long frompc = ...;
diff --git a/include/linux/ftrace.h b/include/linux/ftrace.h
index d74a37d53271..7a21d5358b74 100644
--- a/include/linux/ftrace.h
+++ b/include/linux/ftrace.h
@@ -33,8 +33,7 @@
  * features, then it must call an indirect function that
  * does. Or at least does enough to prevent any unwelcomed side effects.
  */
-#if !defined(CONFIG_HAVE_FUNCTION_TRACE_MCOUNT_TEST) || \
-	!ARCH_SUPPORTS_FTRACE_OPS
+#if !ARCH_SUPPORTS_FTRACE_OPS
 # define FTRACE_FORCE_LIST_FUNC 1
 #else
 # define FTRACE_FORCE_LIST_FUNC 0
-- 
2.0.0



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

* [RFA][PATCH 16/27] ftrace: x86: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` Steven Rostedt
                   ` (15 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  2014-07-15 15:48   ` H. Peter Anvin
  -1 siblings, 1 reply; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf, H. Peter Anvin

[-- Attachment #1: 0016-ftrace-x86-Remove-check-of-obsolete-variable-functio.patch --]
[-- Type: text/plain, Size: 3414 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

Nothing sets function_trace_stop to disable function tracing anymore.
Remove the check for it in the arch code.

Cc: H. Peter Anvin <hpa@linux.intel.com>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 arch/x86/Kconfig            |  1 -
 arch/x86/kernel/entry_32.S  |  9 ---------
 arch/x86/kernel/mcount_64.S | 18 +-----------------
 3 files changed, 1 insertion(+), 27 deletions(-)

diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig
index fcefdda5136d..e9df49244741 100644
--- a/arch/x86/Kconfig
+++ b/arch/x86/Kconfig
@@ -54,7 +54,6 @@ config X86
 	select HAVE_FUNCTION_TRACER
 	select HAVE_FUNCTION_GRAPH_TRACER
 	select HAVE_FUNCTION_GRAPH_FP_TEST
-	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
 	select HAVE_SYSCALL_TRACEPOINTS
 	select SYSCTL_EXCEPTION_TRACE
 	select HAVE_KVM
diff --git a/arch/x86/kernel/entry_32.S b/arch/x86/kernel/entry_32.S
index f0da82b8e634..e352cad614d4 100644
--- a/arch/x86/kernel/entry_32.S
+++ b/arch/x86/kernel/entry_32.S
@@ -1052,9 +1052,6 @@ ENTRY(mcount)
 END(mcount)
 
 ENTRY(ftrace_caller)
-	cmpl $0, function_trace_stop
-	jne  ftrace_stub
-
 	pushl %eax
 	pushl %ecx
 	pushl %edx
@@ -1086,8 +1083,6 @@ END(ftrace_caller)
 
 ENTRY(ftrace_regs_caller)
 	pushf	/* push flags before compare (in cs location) */
-	cmpl $0, function_trace_stop
-	jne ftrace_restore_flags
 
 	/*
 	 * i386 does not save SS and ESP when coming from kernel.
@@ -1146,7 +1141,6 @@ GLOBAL(ftrace_regs_call)
 	popf			/* Pop flags at end (no addl to corrupt flags) */
 	jmp ftrace_ret
 
-ftrace_restore_flags:
 	popf
 	jmp  ftrace_stub
 #else /* ! CONFIG_DYNAMIC_FTRACE */
@@ -1155,9 +1149,6 @@ ENTRY(mcount)
 	cmpl $__PAGE_OFFSET, %esp
 	jb ftrace_stub		/* Paging not enabled yet? */
 
-	cmpl $0, function_trace_stop
-	jne  ftrace_stub
-
 	cmpl $ftrace_stub, ftrace_trace_function
 	jnz trace
 #ifdef CONFIG_FUNCTION_GRAPH_TRACER
diff --git a/arch/x86/kernel/mcount_64.S b/arch/x86/kernel/mcount_64.S
index 6b4e3c3b3d74..c73aecf10d34 100644
--- a/arch/x86/kernel/mcount_64.S
+++ b/arch/x86/kernel/mcount_64.S
@@ -46,10 +46,6 @@ END(function_hook)
 .endm
 
 ENTRY(ftrace_caller)
-	/* Check if tracing was disabled (quick check) */
-	cmpl $0, function_trace_stop
-	jne  ftrace_stub
-
 	ftrace_caller_setup
 	/* regs go into 4th parameter (but make it NULL) */
 	movq $0, %rcx
@@ -73,10 +69,6 @@ ENTRY(ftrace_regs_caller)
 	/* Save the current flags before compare (in SS location)*/
 	pushfq
 
-	/* Check if tracing was disabled (quick check) */
-	cmpl $0, function_trace_stop
-	jne  ftrace_restore_flags
-
 	/* skip=8 to skip flags saved in SS */
 	ftrace_caller_setup 8
 
@@ -131,7 +123,7 @@ GLOBAL(ftrace_regs_call)
 	popfq
 
 	jmp ftrace_return
-ftrace_restore_flags:
+
 	popfq
 	jmp  ftrace_stub
 
@@ -141,9 +133,6 @@ END(ftrace_regs_caller)
 #else /* ! CONFIG_DYNAMIC_FTRACE */
 
 ENTRY(function_hook)
-	cmpl $0, function_trace_stop
-	jne  ftrace_stub
-
 	cmpq $ftrace_stub, ftrace_trace_function
 	jnz trace
 
@@ -182,10 +171,6 @@ END(function_hook)
 ENTRY(ftrace_graph_caller)
 	MCOUNT_SAVE_FRAME
 
-	/* Check if tracing was disabled (quick check) */
-	cmpl $0, function_trace_stop
-	jne  fgraph_skip
-
 #ifdef CC_USING_FENTRY
 	leaq SS+16(%rsp), %rdi
 	movq $0, %rdx	/* No framepointers needed */
@@ -198,7 +183,6 @@ ENTRY(ftrace_graph_caller)
 
 	call	prepare_ftrace_return
 
-fgraph_skip:
 	MCOUNT_RESTORE_FRAME
 
 	retq
-- 
2.0.0



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

* [RFA][PATCH 17/27] tile: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` Steven Rostedt
                   ` (16 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  2014-06-26 17:33     ` Steven Rostedt
  2014-07-03 13:53     ` Chris Metcalf
  -1 siblings, 2 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf, Chris Metcalf

[-- Attachment #1: 0017-tile-ftrace-Remove-check-of-obsolete-variable-functi.patch --]
[-- Type: text/plain, Size: 1840 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

Nothing sets function_trace_stop to disable function tracing anymore.
Remove the check for it in the arch code.

[ Please test this on your arch ]

Cc: Chris Metcalf <cmetcalf@tilera.com>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 arch/tile/Kconfig            |  1 -
 arch/tile/kernel/mcount_64.S | 18 ------------------
 2 files changed, 19 deletions(-)

diff --git a/arch/tile/Kconfig b/arch/tile/Kconfig
index 4f3006b600e3..7fcd492adbfc 100644
--- a/arch/tile/Kconfig
+++ b/arch/tile/Kconfig
@@ -128,7 +128,6 @@ config TILEGX
 	select SPARSE_IRQ
 	select GENERIC_IRQ_LEGACY_ALLOC_HWIRQ
 	select HAVE_FUNCTION_TRACER
-	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
 	select HAVE_FUNCTION_GRAPH_TRACER
 	select HAVE_DYNAMIC_FTRACE
 	select HAVE_FTRACE_MCOUNT_RECORD
diff --git a/arch/tile/kernel/mcount_64.S b/arch/tile/kernel/mcount_64.S
index 70d7bb0c4d8f..3c2b8d5e1d1a 100644
--- a/arch/tile/kernel/mcount_64.S
+++ b/arch/tile/kernel/mcount_64.S
@@ -77,15 +77,6 @@ STD_ENDPROC(__mcount)
 
 	.align	64
 STD_ENTRY(ftrace_caller)
-	moveli	r11, hw2_last(function_trace_stop)
-	{ shl16insli	r11, r11, hw1(function_trace_stop); move r12, lr }
-	{ shl16insli	r11, r11, hw0(function_trace_stop); move lr, r10 }
-	ld	r11, r11
-	beqz	r11, 1f
-	jrp	r12
-
-1:
-	{ move	r10, lr; move	lr, r12 }
 	MCOUNT_SAVE_REGS
 
 	/* arg1: self return address */
@@ -119,15 +110,6 @@ STD_ENDPROC(ftrace_caller)
 
 	.align	64
 STD_ENTRY(__mcount)
-	moveli	r11, hw2_last(function_trace_stop)
-	{ shl16insli	r11, r11, hw1(function_trace_stop); move r12, lr }
-	{ shl16insli	r11, r11, hw0(function_trace_stop); move lr, r10 }
-	ld	r11, r11
-	beqz	r11, 1f
-	jrp	r12
-
-1:
-	{ move	r10, lr; move	lr, r12 }
 	{
 	 moveli	r11, hw2_last(ftrace_trace_function)
 	 moveli	r13, hw2_last(ftrace_stub)
-- 
2.0.0



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

* [RFA][PATCH 18/27] sparc64,ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` Steven Rostedt
                   ` (17 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  2014-06-26 17:34     ` Steven Rostedt
  2014-07-03 16:41     ` Steven Rostedt
  -1 siblings, 2 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf, David S. Miller

[-- Attachment #1: 0018-sparc64-ftrace-Remove-check-of-obsolete-variable-fun.patch --]
[-- Type: text/plain, Size: 1744 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

Nothing sets function_trace_stop to disable function tracing anymore.
Remove the check for it in the arch code.

[ Please test this on your arch ]

Cc: David S. Miller <davem@davemloft.net>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 arch/sparc/Kconfig      |  1 -
 arch/sparc/lib/mcount.S | 10 ++--------
 2 files changed, 2 insertions(+), 9 deletions(-)

diff --git a/arch/sparc/Kconfig b/arch/sparc/Kconfig
index 29f2e988c56a..abd7d5575a7d 100644
--- a/arch/sparc/Kconfig
+++ b/arch/sparc/Kconfig
@@ -55,7 +55,6 @@ config SPARC64
 	select HAVE_FUNCTION_TRACER
 	select HAVE_FUNCTION_GRAPH_TRACER
 	select HAVE_FUNCTION_GRAPH_FP_TEST
-	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
 	select HAVE_KRETPROBES
 	select HAVE_KPROBES
 	select HAVE_RCU_TABLE_FREE if SMP
diff --git a/arch/sparc/lib/mcount.S b/arch/sparc/lib/mcount.S
index 3ad6cbdc2163..0b0ed4d34219 100644
--- a/arch/sparc/lib/mcount.S
+++ b/arch/sparc/lib/mcount.S
@@ -24,10 +24,7 @@ mcount:
 #ifdef CONFIG_DYNAMIC_FTRACE
 	/* Do nothing, the retl/nop below is all we need.  */
 #else
-	sethi		%hi(function_trace_stop), %g1
-	lduw		[%g1 + %lo(function_trace_stop)], %g2
-	brnz,pn		%g2, 2f
-	 sethi		%hi(ftrace_trace_function), %g1
+	sethi		%hi(ftrace_trace_function), %g1
 	sethi		%hi(ftrace_stub), %g2
 	ldx		[%g1 + %lo(ftrace_trace_function)], %g1
 	or		%g2, %lo(ftrace_stub), %g2
@@ -80,11 +77,8 @@ ftrace_stub:
 	.globl		ftrace_caller
 	.type		ftrace_caller,#function
 ftrace_caller:
-	sethi		%hi(function_trace_stop), %g1
 	mov		%i7, %g2
-	lduw		[%g1 + %lo(function_trace_stop)], %g1
-	brnz,pn		%g1, ftrace_stub
-	 mov		%fp, %g3
+	mov		%fp, %g3
 	save		%sp, -176, %sp
 	mov		%g2, %o1
 	mov		%g2, %l0
-- 
2.0.0



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

* [RFA][PATCH 19/27] sh: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` Steven Rostedt
                   ` (18 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  2014-06-26 17:35     ` Steven Rostedt
  -1 siblings, 1 reply; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf, Matt Fleming, Paul Mundt

[-- Attachment #1: 0019-sh-ftrace-Remove-check-of-obsolete-variable-function.patch --]
[-- Type: text/plain, Size: 2113 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

Nothing sets function_trace_stop to disable function tracing anymore.
Remove the check for it in the arch code.

[ Please test this on your arch ]

Cc: Matt Fleming <matt@console-pimps.org>
Cc: Paul Mundt <lethal@linux-sh.org>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 arch/sh/Kconfig      |  1 -
 arch/sh/lib/mcount.S | 24 ++----------------------
 2 files changed, 2 insertions(+), 23 deletions(-)

diff --git a/arch/sh/Kconfig b/arch/sh/Kconfig
index 834b67c4db5a..aa2df3eaeb29 100644
--- a/arch/sh/Kconfig
+++ b/arch/sh/Kconfig
@@ -57,7 +57,6 @@ config SUPERH32
 	select HAVE_FUNCTION_TRACER
 	select HAVE_FTRACE_MCOUNT_RECORD
 	select HAVE_DYNAMIC_FTRACE
-	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
 	select HAVE_FTRACE_NMI_ENTER if DYNAMIC_FTRACE
 	select ARCH_WANT_IPC_PARSE_VERSION
 	select HAVE_FUNCTION_GRAPH_TRACER
diff --git a/arch/sh/lib/mcount.S b/arch/sh/lib/mcount.S
index 52aa2011d753..7a8572f9d58b 100644
--- a/arch/sh/lib/mcount.S
+++ b/arch/sh/lib/mcount.S
@@ -92,13 +92,6 @@ mcount:
 	rts
 	 nop
 #else
-#ifndef CONFIG_DYNAMIC_FTRACE
-	mov.l	.Lfunction_trace_stop, r0
-	mov.l	@r0, r0
-	tst	r0, r0
-	bf	ftrace_stub
-#endif
-
 	MCOUNT_ENTER()
 
 #ifdef CONFIG_DYNAMIC_FTRACE
@@ -174,11 +167,6 @@ ftrace_graph_call:
 
 	.globl ftrace_caller
 ftrace_caller:
-	mov.l	.Lfunction_trace_stop, r0
-	mov.l	@r0, r0
-	tst	r0, r0
-	bf	ftrace_stub
-
 	MCOUNT_ENTER()
 
 	.globl ftrace_call
@@ -196,8 +184,6 @@ ftrace_call:
 #endif /* CONFIG_DYNAMIC_FTRACE */
 
 	.align 2
-.Lfunction_trace_stop:
-	.long	function_trace_stop
 
 /*
  * NOTE: From here on the locations of the .Lftrace_stub label and
@@ -217,12 +203,7 @@ ftrace_stub:
 #ifdef CONFIG_FUNCTION_GRAPH_TRACER
 	.globl	ftrace_graph_caller
 ftrace_graph_caller:
-	mov.l	2f, r0
-	mov.l	@r0, r0
-	tst	r0, r0
-	bt	1f
-
-	mov.l	3f, r1
+	mov.l	2f, r1
 	jmp	@r1
 	 nop
 1:
@@ -242,8 +223,7 @@ ftrace_graph_caller:
 	MCOUNT_LEAVE()
 
 	.align 2
-2:	.long	function_trace_stop
-3:	.long	skip_trace
+2:	.long	skip_trace
 .Lprepare_ftrace_return:
 	.long	prepare_ftrace_return
 
-- 
2.0.0



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

* [RFA][PATCH 20/27] parisc: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` Steven Rostedt
                   ` (19 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  2014-06-26 17:35     ` Steven Rostedt
  -1 siblings, 1 reply; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf, Helge Deller, Kyle McMartin

[-- Attachment #1: 0020-parisc-ftrace-Remove-check-of-obsolete-variable-func.patch --]
[-- Type: text/plain, Size: 1271 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

Nothing sets function_trace_stop to disable function tracing anymore.
Remove the check for it in the arch code.

Cc: Helge Deller <deller@gmx.de>
Cc: Kyle McMartin <kyle@mcmartin.ca>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 arch/parisc/Kconfig         | 1 -
 arch/parisc/kernel/ftrace.c | 3 ---
 2 files changed, 4 deletions(-)

diff --git a/arch/parisc/Kconfig b/arch/parisc/Kconfig
index 108d48e652af..6e75e2030927 100644
--- a/arch/parisc/Kconfig
+++ b/arch/parisc/Kconfig
@@ -6,7 +6,6 @@ config PARISC
 	select HAVE_OPROFILE
 	select HAVE_FUNCTION_TRACER if 64BIT
 	select HAVE_FUNCTION_GRAPH_TRACER if 64BIT
-	select HAVE_FUNCTION_TRACE_MCOUNT_TEST if 64BIT
 	select ARCH_WANT_FRAME_POINTERS
 	select RTC_CLASS
 	select RTC_DRV_GENERIC
diff --git a/arch/parisc/kernel/ftrace.c b/arch/parisc/kernel/ftrace.c
index 5512ab32c5e0..559d400f9385 100644
--- a/arch/parisc/kernel/ftrace.c
+++ b/arch/parisc/kernel/ftrace.c
@@ -155,9 +155,6 @@ void ftrace_function_trampoline(unsigned long parent,
 {
 	extern ftrace_func_t ftrace_trace_function;
 
-	if (function_trace_stop)
-		return;
-
 	if (ftrace_trace_function != ftrace_stub) {
 		ftrace_trace_function(parent, self_addr);
 		return;
-- 
2.0.0



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

* [RFA][PATCH 21/27] MIPS: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` Steven Rostedt
                   ` (20 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  2014-06-26 17:37     ` Steven Rostedt
                     ` (3 more replies)
  -1 siblings, 4 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf

[-- Attachment #1: 0021-MIPS-ftrace-Remove-check-of-obsolete-variable-functi.patch --]
[-- Type: text/plain, Size: 1491 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

Nothing sets function_trace_stop to disable function tracing anymore.
Remove the check for it in the arch code.

[ Please test this on your arch ]

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 arch/mips/Kconfig         | 1 -
 arch/mips/kernel/mcount.S | 7 -------
 2 files changed, 8 deletions(-)

diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig
index 7a469acee33c..9ca52987fcd5 100644
--- a/arch/mips/Kconfig
+++ b/arch/mips/Kconfig
@@ -15,7 +15,6 @@ config MIPS
 	select HAVE_BPF_JIT if !CPU_MICROMIPS
 	select ARCH_HAVE_CUSTOM_GPIO_H
 	select HAVE_FUNCTION_TRACER
-	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
 	select HAVE_DYNAMIC_FTRACE
 	select HAVE_FTRACE_MCOUNT_RECORD
 	select HAVE_C_RECORDMCOUNT
diff --git a/arch/mips/kernel/mcount.S b/arch/mips/kernel/mcount.S
index 539b6294b613..00940d1d5c4f 100644
--- a/arch/mips/kernel/mcount.S
+++ b/arch/mips/kernel/mcount.S
@@ -74,10 +74,6 @@ _mcount:
 #endif
 
 	/* When tracing is activated, it calls ftrace_caller+8 (aka here) */
-	lw	t1, function_trace_stop
-	bnez	t1, ftrace_stub
-	 nop
-
 	MCOUNT_SAVE_REGS
 #ifdef KBUILD_MCOUNT_RA_ADDRESS
 	PTR_S	MCOUNT_RA_ADDRESS_REG, PT_R12(sp)
@@ -105,9 +101,6 @@ ftrace_stub:
 #else	/* ! CONFIG_DYNAMIC_FTRACE */
 
 NESTED(_mcount, PT_SIZE, ra)
-	lw	t1, function_trace_stop
-	bnez	t1, ftrace_stub
-	 nop
 	PTR_LA	t1, ftrace_stub
 	PTR_L	t2, ftrace_trace_function /* Prepare t2 for (1) */
 	bne	t1, t2, static_trace
-- 
2.0.0



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

* [RFA][PATCH 22/27] microblaze: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` Steven Rostedt
                   ` (21 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  2014-06-26 17:38     ` Steven Rostedt
                     ` (2 more replies)
  -1 siblings, 3 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf, Michal Simek

[-- Attachment #1: 0022-microblaze-ftrace-Remove-check-of-obsolete-variable-.patch --]
[-- Type: text/plain, Size: 1434 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

Nothing sets function_trace_stop to disable function tracing anymore.
Remove the check for it in the arch code.

[ Please test this on your arch ]

Cc: Michal Simek <monstr@monstr.eu>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 arch/microblaze/Kconfig         | 1 -
 arch/microblaze/kernel/mcount.S | 5 -----
 2 files changed, 6 deletions(-)

diff --git a/arch/microblaze/Kconfig b/arch/microblaze/Kconfig
index 9ae08541e30d..40e1c1dd0e24 100644
--- a/arch/microblaze/Kconfig
+++ b/arch/microblaze/Kconfig
@@ -22,7 +22,6 @@ config MICROBLAZE
 	select HAVE_DYNAMIC_FTRACE
 	select HAVE_FTRACE_MCOUNT_RECORD
 	select HAVE_FUNCTION_GRAPH_TRACER
-	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
 	select HAVE_FUNCTION_TRACER
 	select HAVE_MEMBLOCK
 	select HAVE_MEMBLOCK_NODE_MAP
diff --git a/arch/microblaze/kernel/mcount.S b/arch/microblaze/kernel/mcount.S
index fc1e1322ce4c..fed9da5de8c4 100644
--- a/arch/microblaze/kernel/mcount.S
+++ b/arch/microblaze/kernel/mcount.S
@@ -91,11 +91,6 @@ ENTRY(ftrace_caller)
 #endif /* CONFIG_DYNAMIC_FTRACE */
 	SAVE_REGS
 	swi	r15, r1, 0;
-	/* MS: HAVE_FUNCTION_TRACE_MCOUNT_TEST begin of checking */
-	lwi	r5, r0, function_trace_stop;
-	bneid	r5, end;
-	nop;
-	/* MS: HAVE_FUNCTION_TRACE_MCOUNT_TEST end of checking */
 #ifdef CONFIG_FUNCTION_GRAPH_TRACER
 #ifndef CONFIG_DYNAMIC_FTRACE
 	lwi	r5, r0, ftrace_graph_return;
-- 
2.0.0



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

* [RFA][PATCH 23/27] metag: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` Steven Rostedt
                   ` (22 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  2014-06-26 17:38     ` Steven Rostedt
  -1 siblings, 1 reply; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf, James Hogan

[-- Attachment #1: 0023-metag-ftrace-Remove-check-of-obsolete-variable-funct.patch --]
[-- Type: text/plain, Size: 1763 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

Nothing sets function_trace_stop to disable function tracing anymore.
Remove the check for it in the arch code.

[ Please test this on your arch ]

Cc: James Hogan <james.hogan@imgtec.com>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 arch/metag/Kconfig              |  1 -
 arch/metag/kernel/ftrace_stub.S | 14 --------------
 2 files changed, 15 deletions(-)

diff --git a/arch/metag/Kconfig b/arch/metag/Kconfig
index 499b7610eaaf..0b389a81c43a 100644
--- a/arch/metag/Kconfig
+++ b/arch/metag/Kconfig
@@ -13,7 +13,6 @@ config METAG
 	select HAVE_DYNAMIC_FTRACE
 	select HAVE_FTRACE_MCOUNT_RECORD
 	select HAVE_FUNCTION_TRACER
-	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
 	select HAVE_KERNEL_BZIP2
 	select HAVE_KERNEL_GZIP
 	select HAVE_KERNEL_LZO
diff --git a/arch/metag/kernel/ftrace_stub.S b/arch/metag/kernel/ftrace_stub.S
index e70bff745bdd..3acc288217c0 100644
--- a/arch/metag/kernel/ftrace_stub.S
+++ b/arch/metag/kernel/ftrace_stub.S
@@ -16,13 +16,6 @@ _mcount_wrapper:
 	.global _ftrace_caller
 	.type	_ftrace_caller,function
 _ftrace_caller:
-	MOVT    D0Re0,#HI(_function_trace_stop)
-	ADD	D0Re0,D0Re0,#LO(_function_trace_stop)
-	GETD	D0Re0,[D0Re0]
-	CMP	D0Re0,#0
-	BEQ	$Lcall_stub
-	MOV	PC,D0.4
-$Lcall_stub:
 	MSETL   [A0StP], D0Ar6, D0Ar4, D0Ar2, D0.4
 	MOV     D1Ar1, D0.4
 	MOV     D0Ar2, D1RtP
@@ -42,13 +35,6 @@ _ftrace_call:
 	.global	_mcount_wrapper
 	.type	_mcount_wrapper,function
 _mcount_wrapper:
-	MOVT    D0Re0,#HI(_function_trace_stop)
-	ADD	D0Re0,D0Re0,#LO(_function_trace_stop)
-	GETD	D0Re0,[D0Re0]
-	CMP	D0Re0,#0
-	BEQ	$Lcall_mcount
-	MOV	PC,D0.4
-$Lcall_mcount:
 	MSETL   [A0StP], D0Ar6, D0Ar4, D0Ar2, D0.4
 	MOV     D1Ar1, D0.4
 	MOV     D0Ar2, D1RtP
-- 
2.0.0



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

* [RFA][PATCH 24/27] Blackfin: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` Steven Rostedt
                   ` (23 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  2014-06-26 17:39     ` Steven Rostedt
  2014-06-26 19:25   ` Mike Frysinger
  -1 siblings, 2 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf, Mike Frysinger

[-- Attachment #1: 0024-Blackfin-ftrace-Remove-check-of-obsolete-variable-fu.patch --]
[-- Type: text/plain, Size: 1967 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

Nothing sets function_trace_stop to disable function tracing anymore.
Remove the check for it in the arch code.

[ Please test this on your arch ]

Cc: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 arch/blackfin/Kconfig               |  1 -
 arch/blackfin/kernel/ftrace-entry.S | 18 ------------------
 2 files changed, 19 deletions(-)

diff --git a/arch/blackfin/Kconfig b/arch/blackfin/Kconfig
index f81e7b989fff..ed30699cc635 100644
--- a/arch/blackfin/Kconfig
+++ b/arch/blackfin/Kconfig
@@ -18,7 +18,6 @@ config BLACKFIN
 	select HAVE_FTRACE_MCOUNT_RECORD
 	select HAVE_FUNCTION_GRAPH_TRACER
 	select HAVE_FUNCTION_TRACER
-	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
 	select HAVE_IDE
 	select HAVE_KERNEL_GZIP if RAMKERNEL
 	select HAVE_KERNEL_BZIP2 if RAMKERNEL
diff --git a/arch/blackfin/kernel/ftrace-entry.S b/arch/blackfin/kernel/ftrace-entry.S
index 7eed00bbd26d..28d059540424 100644
--- a/arch/blackfin/kernel/ftrace-entry.S
+++ b/arch/blackfin/kernel/ftrace-entry.S
@@ -33,15 +33,6 @@ ENDPROC(__mcount)
  * function will be waiting there.  mmmm pie.
  */
 ENTRY(_ftrace_caller)
-# ifdef CONFIG_HAVE_FUNCTION_TRACE_MCOUNT_TEST
-	/* optional micro optimization: return if stopped */
-	p1.l = _function_trace_stop;
-	p1.h = _function_trace_stop;
-	r3 = [p1];
-	cc = r3 == 0;
-	if ! cc jump _ftrace_stub (bp);
-# endif
-
 	/* save first/second/third function arg and the return register */
 	[--sp] = r2;
 	[--sp] = r0;
@@ -83,15 +74,6 @@ ENDPROC(_ftrace_caller)
 
 /* See documentation for _ftrace_caller */
 ENTRY(__mcount)
-# ifdef CONFIG_HAVE_FUNCTION_TRACE_MCOUNT_TEST
-	/* optional micro optimization: return if stopped */
-	p1.l = _function_trace_stop;
-	p1.h = _function_trace_stop;
-	r3 = [p1];
-	cc = r3 == 0;
-	if ! cc jump _ftrace_stub (bp);
-# endif
-
 	/* save third function arg early so we can do testing below */
 	[--sp] = r2;
 
-- 
2.0.0



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

* [RFA][PATCH 25/27] arm64, ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` Steven Rostedt
                   ` (24 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  2014-06-26 17:40     ` Steven Rostedt
  2014-06-27 12:44   ` Will Deacon
  -1 siblings, 2 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf, AKASHI Takahiro, Will Deacon

[-- Attachment #1: 0025-arm64-ftrace-Remove-check-of-obsolete-variable-funct.patch --]
[-- Type: text/plain, Size: 1144 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

Nothing sets function_trace_stop to disable function tracing anymore.
Remove the check for it in the arch code.

arm64 was broken anyway, as it had an ifdef testing
 CONFIG_HAVE_FUNCTION_TRACE_MCOUNT_TEST which is only set if
the arch supports the code (which it obviously did not), and
it was testing a non existent ftrace_trace_stop instead of
function_trace_stop.

Cc: AKASHI Takahiro <takahiro.akashi@linaro.org>
Cc: Will Deacon <will.deacon@arm.com>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 arch/arm64/kernel/entry-ftrace.S | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/arch/arm64/kernel/entry-ftrace.S b/arch/arm64/kernel/entry-ftrace.S
index b051871f2965..1b1e330e6849 100644
--- a/arch/arm64/kernel/entry-ftrace.S
+++ b/arch/arm64/kernel/entry-ftrace.S
@@ -96,11 +96,6 @@
  *     - ftrace_graph_caller to set up an exit hook
  */
 ENTRY(_mcount)
-#ifdef CONFIG_HAVE_FUNCTION_TRACE_MCOUNT_TEST
-	ldr	x0, =ftrace_trace_stop
-	ldr	x0, [x0]		// if ftrace_trace_stop
-	ret				//   return;
-#endif
 	mcount_enter
 
 	ldr	x0, =ftrace_trace_function
-- 
2.0.0



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

* [RFA][PATCH 26/27] s390/ftrace: remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` Steven Rostedt
                   ` (25 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  2014-06-26 17:41     ` Steven Rostedt
  -1 siblings, 1 reply; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf, Heiko Carstens

[-- Attachment #1: 0026-s390-ftrace-remove-check-of-obsolete-variable-functi.patch --]
[-- Type: text/plain, Size: 1871 bytes --]

From: Heiko Carstens <heiko.carstens@de.ibm.com>

Remove check of obsolete variable function_trace_stop as requested by
Steven Rostedt.

Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 arch/s390/Kconfig           |  1 -
 arch/s390/kernel/mcount.S   | 10 +++-------
 arch/s390/kernel/mcount64.S |  3 ---
 3 files changed, 3 insertions(+), 11 deletions(-)

diff --git a/arch/s390/Kconfig b/arch/s390/Kconfig
index bb63499fc5d3..f5af5f6ef0f4 100644
--- a/arch/s390/Kconfig
+++ b/arch/s390/Kconfig
@@ -116,7 +116,6 @@ config S390
 	select HAVE_FTRACE_MCOUNT_RECORD
 	select HAVE_FUNCTION_GRAPH_TRACER
 	select HAVE_FUNCTION_TRACER
-	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
 	select HAVE_FUTEX_CMPXCHG if FUTEX
 	select HAVE_KERNEL_BZIP2
 	select HAVE_KERNEL_GZIP
diff --git a/arch/s390/kernel/mcount.S b/arch/s390/kernel/mcount.S
index 08dcf21cb8df..433c6dbfa442 100644
--- a/arch/s390/kernel/mcount.S
+++ b/arch/s390/kernel/mcount.S
@@ -21,13 +21,9 @@ ENTRY(_mcount)
 ENTRY(ftrace_caller)
 #endif
 	stm	%r2,%r5,16(%r15)
-	bras	%r1,2f
+	bras	%r1,1f
 0:	.long	ftrace_trace_function
-1:	.long	function_trace_stop
-2:	l	%r2,1b-0b(%r1)
-	icm	%r2,0xf,0(%r2)
-	jnz	3f
-	st	%r14,56(%r15)
+1:	st	%r14,56(%r15)
 	lr	%r0,%r15
 	ahi	%r15,-96
 	l	%r3,100(%r15)
@@ -50,7 +46,7 @@ ENTRY(ftrace_graph_caller)
 #endif
 	ahi	%r15,96
 	l	%r14,56(%r15)
-3:	lm	%r2,%r5,16(%r15)
+	lm	%r2,%r5,16(%r15)
 	br	%r14
 
 #ifdef CONFIG_FUNCTION_GRAPH_TRACER
diff --git a/arch/s390/kernel/mcount64.S b/arch/s390/kernel/mcount64.S
index 1c52eae3396a..c67a8bf0fd9a 100644
--- a/arch/s390/kernel/mcount64.S
+++ b/arch/s390/kernel/mcount64.S
@@ -20,9 +20,6 @@ ENTRY(_mcount)
 
 ENTRY(ftrace_caller)
 #endif
-	larl	%r1,function_trace_stop
-	icm	%r1,0xf,0(%r1)
-	bnzr	%r14
 	stmg	%r2,%r5,32(%r15)
 	stg	%r14,112(%r15)
 	lgr	%r1,%r15
-- 
2.0.0



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

* [RFA][PATCH 27/27] tracing: Remove function_trace_stop and HAVE_FUNCTION_TRACE_MCOUNT_TEST
  2014-06-26 16:52 ` Steven Rostedt
                   ` (26 preceding siblings ...)
  (?)
@ 2014-06-26 16:52 ` Steven Rostedt
  -1 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 16:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf

[-- Attachment #1: 0027-tracing-Remove-function_trace_stop-and-HAVE_FUNCTION.patch --]
[-- Type: text/plain, Size: 1616 bytes --]

From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>

All users of function_trace_stop and HAVE_FUNCTION_TRACE_MCOUNT_TEST have
been removed. We can safely remove them from the kernel.

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 include/linux/ftrace.h | 2 --
 kernel/trace/Kconfig   | 5 -----
 kernel/trace/ftrace.c  | 3 ---
 3 files changed, 10 deletions(-)

diff --git a/include/linux/ftrace.h b/include/linux/ftrace.h
index 7a21d5358b74..ff860dbff75a 100644
--- a/include/linux/ftrace.h
+++ b/include/linux/ftrace.h
@@ -129,8 +129,6 @@ struct ftrace_ops {
 #endif
 };
 
-extern int function_trace_stop;
-
 /*
  * Type of the current tracing.
  */
diff --git a/kernel/trace/Kconfig b/kernel/trace/Kconfig
index d4409356f40d..a5da09c899dd 100644
--- a/kernel/trace/Kconfig
+++ b/kernel/trace/Kconfig
@@ -29,11 +29,6 @@ config HAVE_FUNCTION_GRAPH_FP_TEST
 	help
 	  See Documentation/trace/ftrace-design.txt
 
-config HAVE_FUNCTION_TRACE_MCOUNT_TEST
-	bool
-	help
-	  See Documentation/trace/ftrace-design.txt
-
 config HAVE_DYNAMIC_FTRACE
 	bool
 	help
diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c
index 34994885bb1d..2241bfbe4fbc 100644
--- a/kernel/trace/ftrace.c
+++ b/kernel/trace/ftrace.c
@@ -80,9 +80,6 @@ static struct ftrace_ops ftrace_list_end __read_mostly = {
 int ftrace_enabled __read_mostly;
 static int last_ftrace_enabled;
 
-/* Quick disabling of function tracer. */
-int function_trace_stop __read_mostly;
-
 /* Current function tracing op */
 struct ftrace_ops *function_trace_op __read_mostly = &ftrace_list_end;
 /* What to set function_trace_op to */
-- 
2.0.0



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

* Re: [RFA][PATCH 17/27] tile: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` [RFA][PATCH 17/27] tile: ftrace: " Steven Rostedt
@ 2014-06-26 17:33     ` Steven Rostedt
  2014-07-03 13:53     ` Chris Metcalf
  1 sibling, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 17:33 UTC (permalink / raw)
  To: Chris Metcalf; +Cc: linux-kernel, linux-arch

On Thu, 26 Jun 2014 12:52:38 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> [ Please test this on your arch ]

>From the cover letter (you were not Cc'd on)

Anyway, as there is no more reason to set function_trace_stop it is time
to remove it. Unfortunately it's in several archs in assembly. Most of
the assembly looks rather straight forward and I removed them myself.
But I was only able to compile test them (for archs: arm64, metag, and
microblaze I do not have my cross tools set up for them and did not
even compile test it). But I would really love it if people can
download their patch and test it out. You only need the patches that go
against your arch and to really test it, also include the patch titled: 

 ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST

Otherwise your arch patch will call the list op that still does the
check. That is, if you want to test suspend and resume on your arch.

As you may see, there are patches to the ftrace infrastructure that
depend on the arch patches being implemented. I removed the
functionality from the infrastructure, then removed it from the archs,
and then finally removed the existence of the function_trace_stop
variable, which would cause the archs to fail to compile if that were
to go first.

If you can test your arch and give me your acked-by, I would appreciate
it. Otherwise, if you need this to go through your tree, I would ask you
to set up a dedicated branch that I can pull from to keep this order
intact.

-- Steve

> 
> Cc: Chris Metcalf <cmetcalf@tilera.com>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/tile/Kconfig            |  1 -
>  arch/tile/kernel/mcount_64.S | 18 ------------------
>  2 files changed, 19 deletions(-)
> 
> diff --git a/arch/tile/Kconfig b/arch/tile/Kconfig
> index 4f3006b600e3..7fcd492adbfc 100644
> --- a/arch/tile/Kconfig
> +++ b/arch/tile/Kconfig
> @@ -128,7 +128,6 @@ config TILEGX
>  	select SPARSE_IRQ
>  	select GENERIC_IRQ_LEGACY_ALLOC_HWIRQ
>  	select HAVE_FUNCTION_TRACER
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>  	select HAVE_FUNCTION_GRAPH_TRACER
>  	select HAVE_DYNAMIC_FTRACE
>  	select HAVE_FTRACE_MCOUNT_RECORD
> diff --git a/arch/tile/kernel/mcount_64.S b/arch/tile/kernel/mcount_64.S
> index 70d7bb0c4d8f..3c2b8d5e1d1a 100644
> --- a/arch/tile/kernel/mcount_64.S
> +++ b/arch/tile/kernel/mcount_64.S
> @@ -77,15 +77,6 @@ STD_ENDPROC(__mcount)
>  
>  	.align	64
>  STD_ENTRY(ftrace_caller)
> -	moveli	r11, hw2_last(function_trace_stop)
> -	{ shl16insli	r11, r11, hw1(function_trace_stop); move r12, lr }
> -	{ shl16insli	r11, r11, hw0(function_trace_stop); move lr, r10 }
> -	ld	r11, r11
> -	beqz	r11, 1f
> -	jrp	r12
> -
> -1:
> -	{ move	r10, lr; move	lr, r12 }
>  	MCOUNT_SAVE_REGS
>  
>  	/* arg1: self return address */
> @@ -119,15 +110,6 @@ STD_ENDPROC(ftrace_caller)
>  
>  	.align	64
>  STD_ENTRY(__mcount)
> -	moveli	r11, hw2_last(function_trace_stop)
> -	{ shl16insli	r11, r11, hw1(function_trace_stop); move r12, lr }
> -	{ shl16insli	r11, r11, hw0(function_trace_stop); move lr, r10 }
> -	ld	r11, r11
> -	beqz	r11, 1f
> -	jrp	r12
> -
> -1:
> -	{ move	r10, lr; move	lr, r12 }
>  	{
>  	 moveli	r11, hw2_last(ftrace_trace_function)
>  	 moveli	r13, hw2_last(ftrace_stub)


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

* Re: [RFA][PATCH 17/27] tile: ftrace: Remove check of obsolete variable function_trace_stop
@ 2014-06-26 17:33     ` Steven Rostedt
  0 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 17:33 UTC (permalink / raw)
  To: Chris Metcalf; +Cc: linux-kernel, linux-arch

On Thu, 26 Jun 2014 12:52:38 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> [ Please test this on your arch ]

From the cover letter (you were not Cc'd on)

Anyway, as there is no more reason to set function_trace_stop it is time
to remove it. Unfortunately it's in several archs in assembly. Most of
the assembly looks rather straight forward and I removed them myself.
But I was only able to compile test them (for archs: arm64, metag, and
microblaze I do not have my cross tools set up for them and did not
even compile test it). But I would really love it if people can
download their patch and test it out. You only need the patches that go
against your arch and to really test it, also include the patch titled: 

 ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST

Otherwise your arch patch will call the list op that still does the
check. That is, if you want to test suspend and resume on your arch.

As you may see, there are patches to the ftrace infrastructure that
depend on the arch patches being implemented. I removed the
functionality from the infrastructure, then removed it from the archs,
and then finally removed the existence of the function_trace_stop
variable, which would cause the archs to fail to compile if that were
to go first.

If you can test your arch and give me your acked-by, I would appreciate
it. Otherwise, if you need this to go through your tree, I would ask you
to set up a dedicated branch that I can pull from to keep this order
intact.

-- Steve

> 
> Cc: Chris Metcalf <cmetcalf@tilera.com>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/tile/Kconfig            |  1 -
>  arch/tile/kernel/mcount_64.S | 18 ------------------
>  2 files changed, 19 deletions(-)
> 
> diff --git a/arch/tile/Kconfig b/arch/tile/Kconfig
> index 4f3006b600e3..7fcd492adbfc 100644
> --- a/arch/tile/Kconfig
> +++ b/arch/tile/Kconfig
> @@ -128,7 +128,6 @@ config TILEGX
>  	select SPARSE_IRQ
>  	select GENERIC_IRQ_LEGACY_ALLOC_HWIRQ
>  	select HAVE_FUNCTION_TRACER
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>  	select HAVE_FUNCTION_GRAPH_TRACER
>  	select HAVE_DYNAMIC_FTRACE
>  	select HAVE_FTRACE_MCOUNT_RECORD
> diff --git a/arch/tile/kernel/mcount_64.S b/arch/tile/kernel/mcount_64.S
> index 70d7bb0c4d8f..3c2b8d5e1d1a 100644
> --- a/arch/tile/kernel/mcount_64.S
> +++ b/arch/tile/kernel/mcount_64.S
> @@ -77,15 +77,6 @@ STD_ENDPROC(__mcount)
>  
>  	.align	64
>  STD_ENTRY(ftrace_caller)
> -	moveli	r11, hw2_last(function_trace_stop)
> -	{ shl16insli	r11, r11, hw1(function_trace_stop); move r12, lr }
> -	{ shl16insli	r11, r11, hw0(function_trace_stop); move lr, r10 }
> -	ld	r11, r11
> -	beqz	r11, 1f
> -	jrp	r12
> -
> -1:
> -	{ move	r10, lr; move	lr, r12 }
>  	MCOUNT_SAVE_REGS
>  
>  	/* arg1: self return address */
> @@ -119,15 +110,6 @@ STD_ENDPROC(ftrace_caller)
>  
>  	.align	64
>  STD_ENTRY(__mcount)
> -	moveli	r11, hw2_last(function_trace_stop)
> -	{ shl16insli	r11, r11, hw1(function_trace_stop); move r12, lr }
> -	{ shl16insli	r11, r11, hw0(function_trace_stop); move lr, r10 }
> -	ld	r11, r11
> -	beqz	r11, 1f
> -	jrp	r12
> -
> -1:
> -	{ move	r10, lr; move	lr, r12 }
>  	{
>  	 moveli	r11, hw2_last(ftrace_trace_function)
>  	 moveli	r13, hw2_last(ftrace_stub)

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

* Re: [RFA][PATCH 18/27] sparc64,ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` [RFA][PATCH 18/27] sparc64,ftrace: " Steven Rostedt
@ 2014-06-26 17:34     ` Steven Rostedt
  2014-07-03 16:41     ` Steven Rostedt
  1 sibling, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 17:34 UTC (permalink / raw)
  To: David S. Miller; +Cc: linux-kernel, linux-arch

On Thu, 26 Jun 2014 12:52:39 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> [ Please test this on your arch ]

>From the cover letter, you were not Cc'd on.

Anyway, as there is no more reason to set function_trace_stop it is time
to remove it. Unfortunately it's in several archs in assembly. Most of
the assembly looks rather straight forward and I removed them myself.
But I was only able to compile test them (for archs: arm64, metag, and
microblaze I do not have my cross tools set up for them and did not
even compile test it). But I would really love it if people can
download their patch and test it out. You only need the patches that go
against your arch and to really test it, also include the patch titled: 

 ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST

Otherwise your arch patch will call the list op that still does the
check. That is, if you want to test suspend and resume on your arch.

As you may see, there are patches to the ftrace infrastructure that
depend on the arch patches being implemented. I removed the
functionality from the infrastructure, then removed it from the archs,
and then finally removed the existence of the function_trace_stop
variable, which would cause the archs to fail to compile if that were
to go first.

If you can test your arch and give me your acked-by, I would appreciate
it. Otherwise, if you need this to go through your tree, I would ask you
to set up a dedicated branch that I can pull from to keep this order
intact.

-- Steve

> 
> Cc: David S. Miller <davem@davemloft.net>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/sparc/Kconfig      |  1 -
>  arch/sparc/lib/mcount.S | 10 ++--------
>  2 files changed, 2 insertions(+), 9 deletions(-)
> 
> diff --git a/arch/sparc/Kconfig b/arch/sparc/Kconfig
> index 29f2e988c56a..abd7d5575a7d 100644
> --- a/arch/sparc/Kconfig
> +++ b/arch/sparc/Kconfig
> @@ -55,7 +55,6 @@ config SPARC64
>  	select HAVE_FUNCTION_TRACER
>  	select HAVE_FUNCTION_GRAPH_TRACER
>  	select HAVE_FUNCTION_GRAPH_FP_TEST
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>  	select HAVE_KRETPROBES
>  	select HAVE_KPROBES
>  	select HAVE_RCU_TABLE_FREE if SMP
> diff --git a/arch/sparc/lib/mcount.S b/arch/sparc/lib/mcount.S
> index 3ad6cbdc2163..0b0ed4d34219 100644
> --- a/arch/sparc/lib/mcount.S
> +++ b/arch/sparc/lib/mcount.S
> @@ -24,10 +24,7 @@ mcount:
>  #ifdef CONFIG_DYNAMIC_FTRACE
>  	/* Do nothing, the retl/nop below is all we need.  */
>  #else
> -	sethi		%hi(function_trace_stop), %g1
> -	lduw		[%g1 + %lo(function_trace_stop)], %g2
> -	brnz,pn		%g2, 2f
> -	 sethi		%hi(ftrace_trace_function), %g1
> +	sethi		%hi(ftrace_trace_function), %g1
>  	sethi		%hi(ftrace_stub), %g2
>  	ldx		[%g1 + %lo(ftrace_trace_function)], %g1
>  	or		%g2, %lo(ftrace_stub), %g2
> @@ -80,11 +77,8 @@ ftrace_stub:
>  	.globl		ftrace_caller
>  	.type		ftrace_caller,#function
>  ftrace_caller:
> -	sethi		%hi(function_trace_stop), %g1
>  	mov		%i7, %g2
> -	lduw		[%g1 + %lo(function_trace_stop)], %g1
> -	brnz,pn		%g1, ftrace_stub
> -	 mov		%fp, %g3
> +	mov		%fp, %g3
>  	save		%sp, -176, %sp
>  	mov		%g2, %o1
>  	mov		%g2, %l0


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

* Re: [RFA][PATCH 18/27] sparc64,ftrace: Remove check of obsolete variable function_trace_stop
@ 2014-06-26 17:34     ` Steven Rostedt
  0 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 17:34 UTC (permalink / raw)
  To: David S. Miller; +Cc: linux-kernel, linux-arch

On Thu, 26 Jun 2014 12:52:39 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> [ Please test this on your arch ]

From the cover letter, you were not Cc'd on.

Anyway, as there is no more reason to set function_trace_stop it is time
to remove it. Unfortunately it's in several archs in assembly. Most of
the assembly looks rather straight forward and I removed them myself.
But I was only able to compile test them (for archs: arm64, metag, and
microblaze I do not have my cross tools set up for them and did not
even compile test it). But I would really love it if people can
download their patch and test it out. You only need the patches that go
against your arch and to really test it, also include the patch titled: 

 ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST

Otherwise your arch patch will call the list op that still does the
check. That is, if you want to test suspend and resume on your arch.

As you may see, there are patches to the ftrace infrastructure that
depend on the arch patches being implemented. I removed the
functionality from the infrastructure, then removed it from the archs,
and then finally removed the existence of the function_trace_stop
variable, which would cause the archs to fail to compile if that were
to go first.

If you can test your arch and give me your acked-by, I would appreciate
it. Otherwise, if you need this to go through your tree, I would ask you
to set up a dedicated branch that I can pull from to keep this order
intact.

-- Steve

> 
> Cc: David S. Miller <davem@davemloft.net>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/sparc/Kconfig      |  1 -
>  arch/sparc/lib/mcount.S | 10 ++--------
>  2 files changed, 2 insertions(+), 9 deletions(-)
> 
> diff --git a/arch/sparc/Kconfig b/arch/sparc/Kconfig
> index 29f2e988c56a..abd7d5575a7d 100644
> --- a/arch/sparc/Kconfig
> +++ b/arch/sparc/Kconfig
> @@ -55,7 +55,6 @@ config SPARC64
>  	select HAVE_FUNCTION_TRACER
>  	select HAVE_FUNCTION_GRAPH_TRACER
>  	select HAVE_FUNCTION_GRAPH_FP_TEST
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>  	select HAVE_KRETPROBES
>  	select HAVE_KPROBES
>  	select HAVE_RCU_TABLE_FREE if SMP
> diff --git a/arch/sparc/lib/mcount.S b/arch/sparc/lib/mcount.S
> index 3ad6cbdc2163..0b0ed4d34219 100644
> --- a/arch/sparc/lib/mcount.S
> +++ b/arch/sparc/lib/mcount.S
> @@ -24,10 +24,7 @@ mcount:
>  #ifdef CONFIG_DYNAMIC_FTRACE
>  	/* Do nothing, the retl/nop below is all we need.  */
>  #else
> -	sethi		%hi(function_trace_stop), %g1
> -	lduw		[%g1 + %lo(function_trace_stop)], %g2
> -	brnz,pn		%g2, 2f
> -	 sethi		%hi(ftrace_trace_function), %g1
> +	sethi		%hi(ftrace_trace_function), %g1
>  	sethi		%hi(ftrace_stub), %g2
>  	ldx		[%g1 + %lo(ftrace_trace_function)], %g1
>  	or		%g2, %lo(ftrace_stub), %g2
> @@ -80,11 +77,8 @@ ftrace_stub:
>  	.globl		ftrace_caller
>  	.type		ftrace_caller,#function
>  ftrace_caller:
> -	sethi		%hi(function_trace_stop), %g1
>  	mov		%i7, %g2
> -	lduw		[%g1 + %lo(function_trace_stop)], %g1
> -	brnz,pn		%g1, ftrace_stub
> -	 mov		%fp, %g3
> +	mov		%fp, %g3
>  	save		%sp, -176, %sp
>  	mov		%g2, %o1
>  	mov		%g2, %l0

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

* Re: [RFA][PATCH 19/27] sh: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` [RFA][PATCH 19/27] sh: ftrace: " Steven Rostedt
@ 2014-06-26 17:35     ` Steven Rostedt
  0 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 17:35 UTC (permalink / raw)
  To: Matt Fleming, Paul Mundt; +Cc: linux-kernel, linux-arch

On Thu, 26 Jun 2014 12:52:40 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> [ Please test this on your arch ]

>From the cover letter, you were not Cc'd on.

Anyway, as there is no more reason to set function_trace_stop it is time
to remove it. Unfortunately it's in several archs in assembly. Most of
the assembly looks rather straight forward and I removed them myself.
But I was only able to compile test them (for archs: arm64, metag, and
microblaze I do not have my cross tools set up for them and did not
even compile test it). But I would really love it if people can
download their patch and test it out. You only need the patches that go
against your arch and to really test it, also include the patch titled: 

 ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST

Otherwise your arch patch will call the list op that still does the
check. That is, if you want to test suspend and resume on your arch.

As you may see, there are patches to the ftrace infrastructure that
depend on the arch patches being implemented. I removed the
functionality from the infrastructure, then removed it from the archs,
and then finally removed the existence of the function_trace_stop
variable, which would cause the archs to fail to compile if that were
to go first.

If you can test your arch and give me your acked-by, I would appreciate
it. Otherwise, if you need this to go through your tree, I would ask you
to set up a dedicated branch that I can pull from to keep this order
intact.

-- Steve

> 
> Cc: Matt Fleming <matt@console-pimps.org>
> Cc: Paul Mundt <lethal@linux-sh.org>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/sh/Kconfig      |  1 -
>  arch/sh/lib/mcount.S | 24 ++----------------------
>  2 files changed, 2 insertions(+), 23 deletions(-)
> 
> diff --git a/arch/sh/Kconfig b/arch/sh/Kconfig
> index 834b67c4db5a..aa2df3eaeb29 100644
> --- a/arch/sh/Kconfig
> +++ b/arch/sh/Kconfig
> @@ -57,7 +57,6 @@ config SUPERH32
>  	select HAVE_FUNCTION_TRACER
>  	select HAVE_FTRACE_MCOUNT_RECORD
>  	select HAVE_DYNAMIC_FTRACE
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>  	select HAVE_FTRACE_NMI_ENTER if DYNAMIC_FTRACE
>  	select ARCH_WANT_IPC_PARSE_VERSION
>  	select HAVE_FUNCTION_GRAPH_TRACER
> diff --git a/arch/sh/lib/mcount.S b/arch/sh/lib/mcount.S
> index 52aa2011d753..7a8572f9d58b 100644
> --- a/arch/sh/lib/mcount.S
> +++ b/arch/sh/lib/mcount.S
> @@ -92,13 +92,6 @@ mcount:
>  	rts
>  	 nop
>  #else
> -#ifndef CONFIG_DYNAMIC_FTRACE
> -	mov.l	.Lfunction_trace_stop, r0
> -	mov.l	@r0, r0
> -	tst	r0, r0
> -	bf	ftrace_stub
> -#endif
> -
>  	MCOUNT_ENTER()
>  
>  #ifdef CONFIG_DYNAMIC_FTRACE
> @@ -174,11 +167,6 @@ ftrace_graph_call:
>  
>  	.globl ftrace_caller
>  ftrace_caller:
> -	mov.l	.Lfunction_trace_stop, r0
> -	mov.l	@r0, r0
> -	tst	r0, r0
> -	bf	ftrace_stub
> -
>  	MCOUNT_ENTER()
>  
>  	.globl ftrace_call
> @@ -196,8 +184,6 @@ ftrace_call:
>  #endif /* CONFIG_DYNAMIC_FTRACE */
>  
>  	.align 2
> -.Lfunction_trace_stop:
> -	.long	function_trace_stop
>  
>  /*
>   * NOTE: From here on the locations of the .Lftrace_stub label and
> @@ -217,12 +203,7 @@ ftrace_stub:
>  #ifdef CONFIG_FUNCTION_GRAPH_TRACER
>  	.globl	ftrace_graph_caller
>  ftrace_graph_caller:
> -	mov.l	2f, r0
> -	mov.l	@r0, r0
> -	tst	r0, r0
> -	bt	1f
> -
> -	mov.l	3f, r1
> +	mov.l	2f, r1
>  	jmp	@r1
>  	 nop
>  1:
> @@ -242,8 +223,7 @@ ftrace_graph_caller:
>  	MCOUNT_LEAVE()
>  
>  	.align 2
> -2:	.long	function_trace_stop
> -3:	.long	skip_trace
> +2:	.long	skip_trace
>  .Lprepare_ftrace_return:
>  	.long	prepare_ftrace_return
>  


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

* Re: [RFA][PATCH 19/27] sh: ftrace: Remove check of obsolete variable function_trace_stop
@ 2014-06-26 17:35     ` Steven Rostedt
  0 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 17:35 UTC (permalink / raw)
  To: Matt Fleming, Paul Mundt; +Cc: linux-kernel, linux-arch

On Thu, 26 Jun 2014 12:52:40 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> [ Please test this on your arch ]

From the cover letter, you were not Cc'd on.

Anyway, as there is no more reason to set function_trace_stop it is time
to remove it. Unfortunately it's in several archs in assembly. Most of
the assembly looks rather straight forward and I removed them myself.
But I was only able to compile test them (for archs: arm64, metag, and
microblaze I do not have my cross tools set up for them and did not
even compile test it). But I would really love it if people can
download their patch and test it out. You only need the patches that go
against your arch and to really test it, also include the patch titled: 

 ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST

Otherwise your arch patch will call the list op that still does the
check. That is, if you want to test suspend and resume on your arch.

As you may see, there are patches to the ftrace infrastructure that
depend on the arch patches being implemented. I removed the
functionality from the infrastructure, then removed it from the archs,
and then finally removed the existence of the function_trace_stop
variable, which would cause the archs to fail to compile if that were
to go first.

If you can test your arch and give me your acked-by, I would appreciate
it. Otherwise, if you need this to go through your tree, I would ask you
to set up a dedicated branch that I can pull from to keep this order
intact.

-- Steve

> 
> Cc: Matt Fleming <matt@console-pimps.org>
> Cc: Paul Mundt <lethal@linux-sh.org>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/sh/Kconfig      |  1 -
>  arch/sh/lib/mcount.S | 24 ++----------------------
>  2 files changed, 2 insertions(+), 23 deletions(-)
> 
> diff --git a/arch/sh/Kconfig b/arch/sh/Kconfig
> index 834b67c4db5a..aa2df3eaeb29 100644
> --- a/arch/sh/Kconfig
> +++ b/arch/sh/Kconfig
> @@ -57,7 +57,6 @@ config SUPERH32
>  	select HAVE_FUNCTION_TRACER
>  	select HAVE_FTRACE_MCOUNT_RECORD
>  	select HAVE_DYNAMIC_FTRACE
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>  	select HAVE_FTRACE_NMI_ENTER if DYNAMIC_FTRACE
>  	select ARCH_WANT_IPC_PARSE_VERSION
>  	select HAVE_FUNCTION_GRAPH_TRACER
> diff --git a/arch/sh/lib/mcount.S b/arch/sh/lib/mcount.S
> index 52aa2011d753..7a8572f9d58b 100644
> --- a/arch/sh/lib/mcount.S
> +++ b/arch/sh/lib/mcount.S
> @@ -92,13 +92,6 @@ mcount:
>  	rts
>  	 nop
>  #else
> -#ifndef CONFIG_DYNAMIC_FTRACE
> -	mov.l	.Lfunction_trace_stop, r0
> -	mov.l	@r0, r0
> -	tst	r0, r0
> -	bf	ftrace_stub
> -#endif
> -
>  	MCOUNT_ENTER()
>  
>  #ifdef CONFIG_DYNAMIC_FTRACE
> @@ -174,11 +167,6 @@ ftrace_graph_call:
>  
>  	.globl ftrace_caller
>  ftrace_caller:
> -	mov.l	.Lfunction_trace_stop, r0
> -	mov.l	@r0, r0
> -	tst	r0, r0
> -	bf	ftrace_stub
> -
>  	MCOUNT_ENTER()
>  
>  	.globl ftrace_call
> @@ -196,8 +184,6 @@ ftrace_call:
>  #endif /* CONFIG_DYNAMIC_FTRACE */
>  
>  	.align 2
> -.Lfunction_trace_stop:
> -	.long	function_trace_stop
>  
>  /*
>   * NOTE: From here on the locations of the .Lftrace_stub label and
> @@ -217,12 +203,7 @@ ftrace_stub:
>  #ifdef CONFIG_FUNCTION_GRAPH_TRACER
>  	.globl	ftrace_graph_caller
>  ftrace_graph_caller:
> -	mov.l	2f, r0
> -	mov.l	@r0, r0
> -	tst	r0, r0
> -	bt	1f
> -
> -	mov.l	3f, r1
> +	mov.l	2f, r1
>  	jmp	@r1
>  	 nop
>  1:
> @@ -242,8 +223,7 @@ ftrace_graph_caller:
>  	MCOUNT_LEAVE()
>  
>  	.align 2
> -2:	.long	function_trace_stop
> -3:	.long	skip_trace
> +2:	.long	skip_trace
>  .Lprepare_ftrace_return:
>  	.long	prepare_ftrace_return
>  

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

* Re: [RFA][PATCH 20/27] parisc: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` [RFA][PATCH 20/27] parisc: " Steven Rostedt
@ 2014-06-26 17:35     ` Steven Rostedt
  0 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 17:35 UTC (permalink / raw)
  To: Helge Deller, Kyle McMartin; +Cc: linux-kernel, linux-arch

On Thu, 26 Jun 2014 12:52:41 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.

>From the cover letter, you were not Cc'd on.

Anyway, as there is no more reason to set function_trace_stop it is time
to remove it. Unfortunately it's in several archs in assembly. Most of
the assembly looks rather straight forward and I removed them myself.
But I was only able to compile test them (for archs: arm64, metag, and
microblaze I do not have my cross tools set up for them and did not
even compile test it). But I would really love it if people can
download their patch and test it out. You only need the patches that go
against your arch and to really test it, also include the patch titled: 

 ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST

Otherwise your arch patch will call the list op that still does the
check. That is, if you want to test suspend and resume on your arch.

As you may see, there are patches to the ftrace infrastructure that
depend on the arch patches being implemented. I removed the
functionality from the infrastructure, then removed it from the archs,
and then finally removed the existence of the function_trace_stop
variable, which would cause the archs to fail to compile if that were
to go first.

If you can test your arch and give me your acked-by, I would appreciate
it. Otherwise, if you need this to go through your tree, I would ask you
to set up a dedicated branch that I can pull from to keep this order
intact.

-- Steve

> 
> Cc: Helge Deller <deller@gmx.de>
> Cc: Kyle McMartin <kyle@mcmartin.ca>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/parisc/Kconfig         | 1 -
>  arch/parisc/kernel/ftrace.c | 3 ---
>  2 files changed, 4 deletions(-)
> 
> diff --git a/arch/parisc/Kconfig b/arch/parisc/Kconfig
> index 108d48e652af..6e75e2030927 100644
> --- a/arch/parisc/Kconfig
> +++ b/arch/parisc/Kconfig
> @@ -6,7 +6,6 @@ config PARISC
>  	select HAVE_OPROFILE
>  	select HAVE_FUNCTION_TRACER if 64BIT
>  	select HAVE_FUNCTION_GRAPH_TRACER if 64BIT
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST if 64BIT
>  	select ARCH_WANT_FRAME_POINTERS
>  	select RTC_CLASS
>  	select RTC_DRV_GENERIC
> diff --git a/arch/parisc/kernel/ftrace.c b/arch/parisc/kernel/ftrace.c
> index 5512ab32c5e0..559d400f9385 100644
> --- a/arch/parisc/kernel/ftrace.c
> +++ b/arch/parisc/kernel/ftrace.c
> @@ -155,9 +155,6 @@ void ftrace_function_trampoline(unsigned long parent,
>  {
>  	extern ftrace_func_t ftrace_trace_function;
>  
> -	if (function_trace_stop)
> -		return;
> -
>  	if (ftrace_trace_function != ftrace_stub) {
>  		ftrace_trace_function(parent, self_addr);
>  		return;


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

* Re: [RFA][PATCH 20/27] parisc: ftrace: Remove check of obsolete variable function_trace_stop
@ 2014-06-26 17:35     ` Steven Rostedt
  0 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 17:35 UTC (permalink / raw)
  To: Helge Deller, Kyle McMartin; +Cc: linux-kernel, linux-arch

On Thu, 26 Jun 2014 12:52:41 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.

From the cover letter, you were not Cc'd on.

Anyway, as there is no more reason to set function_trace_stop it is time
to remove it. Unfortunately it's in several archs in assembly. Most of
the assembly looks rather straight forward and I removed them myself.
But I was only able to compile test them (for archs: arm64, metag, and
microblaze I do not have my cross tools set up for them and did not
even compile test it). But I would really love it if people can
download their patch and test it out. You only need the patches that go
against your arch and to really test it, also include the patch titled: 

 ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST

Otherwise your arch patch will call the list op that still does the
check. That is, if you want to test suspend and resume on your arch.

As you may see, there are patches to the ftrace infrastructure that
depend on the arch patches being implemented. I removed the
functionality from the infrastructure, then removed it from the archs,
and then finally removed the existence of the function_trace_stop
variable, which would cause the archs to fail to compile if that were
to go first.

If you can test your arch and give me your acked-by, I would appreciate
it. Otherwise, if you need this to go through your tree, I would ask you
to set up a dedicated branch that I can pull from to keep this order
intact.

-- Steve

> 
> Cc: Helge Deller <deller@gmx.de>
> Cc: Kyle McMartin <kyle@mcmartin.ca>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/parisc/Kconfig         | 1 -
>  arch/parisc/kernel/ftrace.c | 3 ---
>  2 files changed, 4 deletions(-)
> 
> diff --git a/arch/parisc/Kconfig b/arch/parisc/Kconfig
> index 108d48e652af..6e75e2030927 100644
> --- a/arch/parisc/Kconfig
> +++ b/arch/parisc/Kconfig
> @@ -6,7 +6,6 @@ config PARISC
>  	select HAVE_OPROFILE
>  	select HAVE_FUNCTION_TRACER if 64BIT
>  	select HAVE_FUNCTION_GRAPH_TRACER if 64BIT
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST if 64BIT
>  	select ARCH_WANT_FRAME_POINTERS
>  	select RTC_CLASS
>  	select RTC_DRV_GENERIC
> diff --git a/arch/parisc/kernel/ftrace.c b/arch/parisc/kernel/ftrace.c
> index 5512ab32c5e0..559d400f9385 100644
> --- a/arch/parisc/kernel/ftrace.c
> +++ b/arch/parisc/kernel/ftrace.c
> @@ -155,9 +155,6 @@ void ftrace_function_trampoline(unsigned long parent,
>  {
>  	extern ftrace_func_t ftrace_trace_function;
>  
> -	if (function_trace_stop)
> -		return;
> -
>  	if (ftrace_trace_function != ftrace_stub) {
>  		ftrace_trace_function(parent, self_addr);
>  		return;

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

* Re: [RFA][PATCH 21/27] MIPS: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` [RFA][PATCH 21/27] MIPS: " Steven Rostedt
@ 2014-06-26 17:37     ` Steven Rostedt
  2014-07-02 14:32   ` Steven Rostedt
                       ` (2 subsequent siblings)
  3 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 17:37 UTC (permalink / raw)
  To: Ralf Baechle; +Cc: linux-kernel, linux-arch

On Thu, 26 Jun 2014 12:52:42 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> [ Please test this on your arch ]
> 

Bah! I forgot to add you to the Cc of this email :-p

Anyway,

>From the cover letter, you were not Cc'd on.

Anyway, as there is no more reason to set function_trace_stop it is time
to remove it. Unfortunately it's in several archs in assembly. Most of
the assembly looks rather straight forward and I removed them myself.
But I was only able to compile test them (for archs: arm64, metag, and
microblaze I do not have my cross tools set up for them and did not
even compile test it). But I would really love it if people can
download their patch and test it out. You only need the patches that go
against your arch and to really test it, also include the patch titled: 

 ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST

Otherwise your arch patch will call the list op that still does the
check. That is, if you want to test suspend and resume on your arch.

As you may see, there are patches to the ftrace infrastructure that
depend on the arch patches being implemented. I removed the
functionality from the infrastructure, then removed it from the archs,
and then finally removed the existence of the function_trace_stop
variable, which would cause the archs to fail to compile if that were
to go first.

If you can test your arch and give me your acked-by, I would appreciate
it. Otherwise, if you need this to go through your tree, I would ask you
to set up a dedicated branch that I can pull from to keep this order
intact.

-- Steve


> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/mips/Kconfig         | 1 -
>  arch/mips/kernel/mcount.S | 7 -------
>  2 files changed, 8 deletions(-)
> 
> diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig
> index 7a469acee33c..9ca52987fcd5 100644
> --- a/arch/mips/Kconfig
> +++ b/arch/mips/Kconfig
> @@ -15,7 +15,6 @@ config MIPS
>  	select HAVE_BPF_JIT if !CPU_MICROMIPS
>  	select ARCH_HAVE_CUSTOM_GPIO_H
>  	select HAVE_FUNCTION_TRACER
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>  	select HAVE_DYNAMIC_FTRACE
>  	select HAVE_FTRACE_MCOUNT_RECORD
>  	select HAVE_C_RECORDMCOUNT
> diff --git a/arch/mips/kernel/mcount.S b/arch/mips/kernel/mcount.S
> index 539b6294b613..00940d1d5c4f 100644
> --- a/arch/mips/kernel/mcount.S
> +++ b/arch/mips/kernel/mcount.S
> @@ -74,10 +74,6 @@ _mcount:
>  #endif
>  
>  	/* When tracing is activated, it calls ftrace_caller+8 (aka here) */
> -	lw	t1, function_trace_stop
> -	bnez	t1, ftrace_stub
> -	 nop
> -
>  	MCOUNT_SAVE_REGS
>  #ifdef KBUILD_MCOUNT_RA_ADDRESS
>  	PTR_S	MCOUNT_RA_ADDRESS_REG, PT_R12(sp)
> @@ -105,9 +101,6 @@ ftrace_stub:
>  #else	/* ! CONFIG_DYNAMIC_FTRACE */
>  
>  NESTED(_mcount, PT_SIZE, ra)
> -	lw	t1, function_trace_stop
> -	bnez	t1, ftrace_stub
> -	 nop
>  	PTR_LA	t1, ftrace_stub
>  	PTR_L	t2, ftrace_trace_function /* Prepare t2 for (1) */
>  	bne	t1, t2, static_trace


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

* Re: [RFA][PATCH 21/27] MIPS: ftrace: Remove check of obsolete variable function_trace_stop
@ 2014-06-26 17:37     ` Steven Rostedt
  0 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 17:37 UTC (permalink / raw)
  To: Ralf Baechle; +Cc: linux-kernel, linux-arch

On Thu, 26 Jun 2014 12:52:42 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> [ Please test this on your arch ]
> 

Bah! I forgot to add you to the Cc of this email :-p

Anyway,

From the cover letter, you were not Cc'd on.

Anyway, as there is no more reason to set function_trace_stop it is time
to remove it. Unfortunately it's in several archs in assembly. Most of
the assembly looks rather straight forward and I removed them myself.
But I was only able to compile test them (for archs: arm64, metag, and
microblaze I do not have my cross tools set up for them and did not
even compile test it). But I would really love it if people can
download their patch and test it out. You only need the patches that go
against your arch and to really test it, also include the patch titled: 

 ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST

Otherwise your arch patch will call the list op that still does the
check. That is, if you want to test suspend and resume on your arch.

As you may see, there are patches to the ftrace infrastructure that
depend on the arch patches being implemented. I removed the
functionality from the infrastructure, then removed it from the archs,
and then finally removed the existence of the function_trace_stop
variable, which would cause the archs to fail to compile if that were
to go first.

If you can test your arch and give me your acked-by, I would appreciate
it. Otherwise, if you need this to go through your tree, I would ask you
to set up a dedicated branch that I can pull from to keep this order
intact.

-- Steve


> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/mips/Kconfig         | 1 -
>  arch/mips/kernel/mcount.S | 7 -------
>  2 files changed, 8 deletions(-)
> 
> diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig
> index 7a469acee33c..9ca52987fcd5 100644
> --- a/arch/mips/Kconfig
> +++ b/arch/mips/Kconfig
> @@ -15,7 +15,6 @@ config MIPS
>  	select HAVE_BPF_JIT if !CPU_MICROMIPS
>  	select ARCH_HAVE_CUSTOM_GPIO_H
>  	select HAVE_FUNCTION_TRACER
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>  	select HAVE_DYNAMIC_FTRACE
>  	select HAVE_FTRACE_MCOUNT_RECORD
>  	select HAVE_C_RECORDMCOUNT
> diff --git a/arch/mips/kernel/mcount.S b/arch/mips/kernel/mcount.S
> index 539b6294b613..00940d1d5c4f 100644
> --- a/arch/mips/kernel/mcount.S
> +++ b/arch/mips/kernel/mcount.S
> @@ -74,10 +74,6 @@ _mcount:
>  #endif
>  
>  	/* When tracing is activated, it calls ftrace_caller+8 (aka here) */
> -	lw	t1, function_trace_stop
> -	bnez	t1, ftrace_stub
> -	 nop
> -
>  	MCOUNT_SAVE_REGS
>  #ifdef KBUILD_MCOUNT_RA_ADDRESS
>  	PTR_S	MCOUNT_RA_ADDRESS_REG, PT_R12(sp)
> @@ -105,9 +101,6 @@ ftrace_stub:
>  #else	/* ! CONFIG_DYNAMIC_FTRACE */
>  
>  NESTED(_mcount, PT_SIZE, ra)
> -	lw	t1, function_trace_stop
> -	bnez	t1, ftrace_stub
> -	 nop
>  	PTR_LA	t1, ftrace_stub
>  	PTR_L	t2, ftrace_trace_function /* Prepare t2 for (1) */
>  	bne	t1, t2, static_trace

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

* Re: [RFA][PATCH 22/27] microblaze: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` [RFA][PATCH 22/27] microblaze: " Steven Rostedt
@ 2014-06-26 17:38     ` Steven Rostedt
  2014-07-09 14:16   ` Steven Rostedt
  2014-07-15 21:51   ` Steven Rostedt
  2 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 17:38 UTC (permalink / raw)
  To: Michal Simek; +Cc: linux-kernel, linux-arch

On Thu, 26 Jun 2014 12:52:43 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> [ Please test this on your arch ]

>From the cover letter, you were not Cc'd on.

Anyway, as there is no more reason to set function_trace_stop it is time
to remove it. Unfortunately it's in several archs in assembly. Most of
the assembly looks rather straight forward and I removed them myself.
But I was only able to compile test them (for archs: arm64, metag, and
microblaze I do not have my cross tools set up for them and did not
even compile test it). But I would really love it if people can
download their patch and test it out. You only need the patches that go
against your arch and to really test it, also include the patch titled: 

 ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST

Otherwise your arch patch will call the list op that still does the
check. That is, if you want to test suspend and resume on your arch.

As you may see, there are patches to the ftrace infrastructure that
depend on the arch patches being implemented. I removed the
functionality from the infrastructure, then removed it from the archs,
and then finally removed the existence of the function_trace_stop
variable, which would cause the archs to fail to compile if that were
to go first.

If you can test your arch and give me your acked-by, I would appreciate
it. Otherwise, if you need this to go through your tree, I would ask you
to set up a dedicated branch that I can pull from to keep this order
intact.

-- Steve

> 
> Cc: Michal Simek <monstr@monstr.eu>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/microblaze/Kconfig         | 1 -
>  arch/microblaze/kernel/mcount.S | 5 -----
>  2 files changed, 6 deletions(-)
> 
> diff --git a/arch/microblaze/Kconfig b/arch/microblaze/Kconfig
> index 9ae08541e30d..40e1c1dd0e24 100644
> --- a/arch/microblaze/Kconfig
> +++ b/arch/microblaze/Kconfig
> @@ -22,7 +22,6 @@ config MICROBLAZE
>  	select HAVE_DYNAMIC_FTRACE
>  	select HAVE_FTRACE_MCOUNT_RECORD
>  	select HAVE_FUNCTION_GRAPH_TRACER
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>  	select HAVE_FUNCTION_TRACER
>  	select HAVE_MEMBLOCK
>  	select HAVE_MEMBLOCK_NODE_MAP
> diff --git a/arch/microblaze/kernel/mcount.S b/arch/microblaze/kernel/mcount.S
> index fc1e1322ce4c..fed9da5de8c4 100644
> --- a/arch/microblaze/kernel/mcount.S
> +++ b/arch/microblaze/kernel/mcount.S
> @@ -91,11 +91,6 @@ ENTRY(ftrace_caller)
>  #endif /* CONFIG_DYNAMIC_FTRACE */
>  	SAVE_REGS
>  	swi	r15, r1, 0;
> -	/* MS: HAVE_FUNCTION_TRACE_MCOUNT_TEST begin of checking */
> -	lwi	r5, r0, function_trace_stop;
> -	bneid	r5, end;
> -	nop;
> -	/* MS: HAVE_FUNCTION_TRACE_MCOUNT_TEST end of checking */
>  #ifdef CONFIG_FUNCTION_GRAPH_TRACER
>  #ifndef CONFIG_DYNAMIC_FTRACE
>  	lwi	r5, r0, ftrace_graph_return;


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

* Re: [RFA][PATCH 22/27] microblaze: ftrace: Remove check of obsolete variable function_trace_stop
@ 2014-06-26 17:38     ` Steven Rostedt
  0 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 17:38 UTC (permalink / raw)
  To: Michal Simek; +Cc: linux-kernel, linux-arch

On Thu, 26 Jun 2014 12:52:43 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> [ Please test this on your arch ]

From the cover letter, you were not Cc'd on.

Anyway, as there is no more reason to set function_trace_stop it is time
to remove it. Unfortunately it's in several archs in assembly. Most of
the assembly looks rather straight forward and I removed them myself.
But I was only able to compile test them (for archs: arm64, metag, and
microblaze I do not have my cross tools set up for them and did not
even compile test it). But I would really love it if people can
download their patch and test it out. You only need the patches that go
against your arch and to really test it, also include the patch titled: 

 ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST

Otherwise your arch patch will call the list op that still does the
check. That is, if you want to test suspend and resume on your arch.

As you may see, there are patches to the ftrace infrastructure that
depend on the arch patches being implemented. I removed the
functionality from the infrastructure, then removed it from the archs,
and then finally removed the existence of the function_trace_stop
variable, which would cause the archs to fail to compile if that were
to go first.

If you can test your arch and give me your acked-by, I would appreciate
it. Otherwise, if you need this to go through your tree, I would ask you
to set up a dedicated branch that I can pull from to keep this order
intact.

-- Steve

> 
> Cc: Michal Simek <monstr@monstr.eu>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/microblaze/Kconfig         | 1 -
>  arch/microblaze/kernel/mcount.S | 5 -----
>  2 files changed, 6 deletions(-)
> 
> diff --git a/arch/microblaze/Kconfig b/arch/microblaze/Kconfig
> index 9ae08541e30d..40e1c1dd0e24 100644
> --- a/arch/microblaze/Kconfig
> +++ b/arch/microblaze/Kconfig
> @@ -22,7 +22,6 @@ config MICROBLAZE
>  	select HAVE_DYNAMIC_FTRACE
>  	select HAVE_FTRACE_MCOUNT_RECORD
>  	select HAVE_FUNCTION_GRAPH_TRACER
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>  	select HAVE_FUNCTION_TRACER
>  	select HAVE_MEMBLOCK
>  	select HAVE_MEMBLOCK_NODE_MAP
> diff --git a/arch/microblaze/kernel/mcount.S b/arch/microblaze/kernel/mcount.S
> index fc1e1322ce4c..fed9da5de8c4 100644
> --- a/arch/microblaze/kernel/mcount.S
> +++ b/arch/microblaze/kernel/mcount.S
> @@ -91,11 +91,6 @@ ENTRY(ftrace_caller)
>  #endif /* CONFIG_DYNAMIC_FTRACE */
>  	SAVE_REGS
>  	swi	r15, r1, 0;
> -	/* MS: HAVE_FUNCTION_TRACE_MCOUNT_TEST begin of checking */
> -	lwi	r5, r0, function_trace_stop;
> -	bneid	r5, end;
> -	nop;
> -	/* MS: HAVE_FUNCTION_TRACE_MCOUNT_TEST end of checking */
>  #ifdef CONFIG_FUNCTION_GRAPH_TRACER
>  #ifndef CONFIG_DYNAMIC_FTRACE
>  	lwi	r5, r0, ftrace_graph_return;

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

* Re: [RFA][PATCH 23/27] metag: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` [RFA][PATCH 23/27] metag: " Steven Rostedt
@ 2014-06-26 17:38     ` Steven Rostedt
  0 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 17:38 UTC (permalink / raw)
  Cc: linux-kernel, linux-arch, James Hogan

On Thu, 26 Jun 2014 12:52:44 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> [ Please test this on your arch ]

>From the cover letter, you were not Cc'd on.

Anyway, as there is no more reason to set function_trace_stop it is time
to remove it. Unfortunately it's in several archs in assembly. Most of
the assembly looks rather straight forward and I removed them myself.
But I was only able to compile test them (for archs: arm64, metag, and
microblaze I do not have my cross tools set up for them and did not
even compile test it). But I would really love it if people can
download their patch and test it out. You only need the patches that go
against your arch and to really test it, also include the patch titled: 

 ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST

Otherwise your arch patch will call the list op that still does the
check. That is, if you want to test suspend and resume on your arch.

As you may see, there are patches to the ftrace infrastructure that
depend on the arch patches being implemented. I removed the
functionality from the infrastructure, then removed it from the archs,
and then finally removed the existence of the function_trace_stop
variable, which would cause the archs to fail to compile if that were
to go first.

If you can test your arch and give me your acked-by, I would appreciate
it. Otherwise, if you need this to go through your tree, I would ask you
to set up a dedicated branch that I can pull from to keep this order
intact.

-- Steve

> 
> Cc: James Hogan <james.hogan@imgtec.com>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/metag/Kconfig              |  1 -
>  arch/metag/kernel/ftrace_stub.S | 14 --------------
>  2 files changed, 15 deletions(-)
> 
> diff --git a/arch/metag/Kconfig b/arch/metag/Kconfig
> index 499b7610eaaf..0b389a81c43a 100644
> --- a/arch/metag/Kconfig
> +++ b/arch/metag/Kconfig
> @@ -13,7 +13,6 @@ config METAG
>  	select HAVE_DYNAMIC_FTRACE
>  	select HAVE_FTRACE_MCOUNT_RECORD
>  	select HAVE_FUNCTION_TRACER
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>  	select HAVE_KERNEL_BZIP2
>  	select HAVE_KERNEL_GZIP
>  	select HAVE_KERNEL_LZO
> diff --git a/arch/metag/kernel/ftrace_stub.S b/arch/metag/kernel/ftrace_stub.S
> index e70bff745bdd..3acc288217c0 100644
> --- a/arch/metag/kernel/ftrace_stub.S
> +++ b/arch/metag/kernel/ftrace_stub.S
> @@ -16,13 +16,6 @@ _mcount_wrapper:
>  	.global _ftrace_caller
>  	.type	_ftrace_caller,function
>  _ftrace_caller:
> -	MOVT    D0Re0,#HI(_function_trace_stop)
> -	ADD	D0Re0,D0Re0,#LO(_function_trace_stop)
> -	GETD	D0Re0,[D0Re0]
> -	CMP	D0Re0,#0
> -	BEQ	$Lcall_stub
> -	MOV	PC,D0.4
> -$Lcall_stub:
>  	MSETL   [A0StP], D0Ar6, D0Ar4, D0Ar2, D0.4
>  	MOV     D1Ar1, D0.4
>  	MOV     D0Ar2, D1RtP
> @@ -42,13 +35,6 @@ _ftrace_call:
>  	.global	_mcount_wrapper
>  	.type	_mcount_wrapper,function
>  _mcount_wrapper:
> -	MOVT    D0Re0,#HI(_function_trace_stop)
> -	ADD	D0Re0,D0Re0,#LO(_function_trace_stop)
> -	GETD	D0Re0,[D0Re0]
> -	CMP	D0Re0,#0
> -	BEQ	$Lcall_mcount
> -	MOV	PC,D0.4
> -$Lcall_mcount:
>  	MSETL   [A0StP], D0Ar6, D0Ar4, D0Ar2, D0.4
>  	MOV     D1Ar1, D0.4
>  	MOV     D0Ar2, D1RtP


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

* Re: [RFA][PATCH 23/27] metag: ftrace: Remove check of obsolete variable function_trace_stop
@ 2014-06-26 17:38     ` Steven Rostedt
  0 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 17:38 UTC (permalink / raw)
  Cc: linux-kernel, linux-arch, James Hogan

On Thu, 26 Jun 2014 12:52:44 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> [ Please test this on your arch ]

From the cover letter, you were not Cc'd on.

Anyway, as there is no more reason to set function_trace_stop it is time
to remove it. Unfortunately it's in several archs in assembly. Most of
the assembly looks rather straight forward and I removed them myself.
But I was only able to compile test them (for archs: arm64, metag, and
microblaze I do not have my cross tools set up for them and did not
even compile test it). But I would really love it if people can
download their patch and test it out. You only need the patches that go
against your arch and to really test it, also include the patch titled: 

 ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST

Otherwise your arch patch will call the list op that still does the
check. That is, if you want to test suspend and resume on your arch.

As you may see, there are patches to the ftrace infrastructure that
depend on the arch patches being implemented. I removed the
functionality from the infrastructure, then removed it from the archs,
and then finally removed the existence of the function_trace_stop
variable, which would cause the archs to fail to compile if that were
to go first.

If you can test your arch and give me your acked-by, I would appreciate
it. Otherwise, if you need this to go through your tree, I would ask you
to set up a dedicated branch that I can pull from to keep this order
intact.

-- Steve

> 
> Cc: James Hogan <james.hogan@imgtec.com>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/metag/Kconfig              |  1 -
>  arch/metag/kernel/ftrace_stub.S | 14 --------------
>  2 files changed, 15 deletions(-)
> 
> diff --git a/arch/metag/Kconfig b/arch/metag/Kconfig
> index 499b7610eaaf..0b389a81c43a 100644
> --- a/arch/metag/Kconfig
> +++ b/arch/metag/Kconfig
> @@ -13,7 +13,6 @@ config METAG
>  	select HAVE_DYNAMIC_FTRACE
>  	select HAVE_FTRACE_MCOUNT_RECORD
>  	select HAVE_FUNCTION_TRACER
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>  	select HAVE_KERNEL_BZIP2
>  	select HAVE_KERNEL_GZIP
>  	select HAVE_KERNEL_LZO
> diff --git a/arch/metag/kernel/ftrace_stub.S b/arch/metag/kernel/ftrace_stub.S
> index e70bff745bdd..3acc288217c0 100644
> --- a/arch/metag/kernel/ftrace_stub.S
> +++ b/arch/metag/kernel/ftrace_stub.S
> @@ -16,13 +16,6 @@ _mcount_wrapper:
>  	.global _ftrace_caller
>  	.type	_ftrace_caller,function
>  _ftrace_caller:
> -	MOVT    D0Re0,#HI(_function_trace_stop)
> -	ADD	D0Re0,D0Re0,#LO(_function_trace_stop)
> -	GETD	D0Re0,[D0Re0]
> -	CMP	D0Re0,#0
> -	BEQ	$Lcall_stub
> -	MOV	PC,D0.4
> -$Lcall_stub:
>  	MSETL   [A0StP], D0Ar6, D0Ar4, D0Ar2, D0.4
>  	MOV     D1Ar1, D0.4
>  	MOV     D0Ar2, D1RtP
> @@ -42,13 +35,6 @@ _ftrace_call:
>  	.global	_mcount_wrapper
>  	.type	_mcount_wrapper,function
>  _mcount_wrapper:
> -	MOVT    D0Re0,#HI(_function_trace_stop)
> -	ADD	D0Re0,D0Re0,#LO(_function_trace_stop)
> -	GETD	D0Re0,[D0Re0]
> -	CMP	D0Re0,#0
> -	BEQ	$Lcall_mcount
> -	MOV	PC,D0.4
> -$Lcall_mcount:
>  	MSETL   [A0StP], D0Ar6, D0Ar4, D0Ar2, D0.4
>  	MOV     D1Ar1, D0.4
>  	MOV     D0Ar2, D1RtP

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

* Re: [RFA][PATCH 24/27] Blackfin: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` [RFA][PATCH 24/27] Blackfin: " Steven Rostedt
@ 2014-06-26 17:39     ` Steven Rostedt
  2014-06-26 19:25   ` Mike Frysinger
  1 sibling, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 17:39 UTC (permalink / raw)
  Cc: linux-kernel, linux-arch, Mike Frysinger

On Thu, 26 Jun 2014 12:52:45 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> [ Please test this on your arch ]

>From the cover letter, you were not Cc'd on.

Anyway, as there is no more reason to set function_trace_stop it is time
to remove it. Unfortunately it's in several archs in assembly. Most of
the assembly looks rather straight forward and I removed them myself.
But I was only able to compile test them (for archs: arm64, metag, and
microblaze I do not have my cross tools set up for them and did not
even compile test it). But I would really love it if people can
download their patch and test it out. You only need the patches that go
against your arch and to really test it, also include the patch titled: 

 ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST

Otherwise your arch patch will call the list op that still does the
check. That is, if you want to test suspend and resume on your arch.

As you may see, there are patches to the ftrace infrastructure that
depend on the arch patches being implemented. I removed the
functionality from the infrastructure, then removed it from the archs,
and then finally removed the existence of the function_trace_stop
variable, which would cause the archs to fail to compile if that were
to go first.

If you can test your arch and give me your acked-by, I would appreciate
it. Otherwise, if you need this to go through your tree, I would ask you
to set up a dedicated branch that I can pull from to keep this order
intact.

-- Steve

> 
> Cc: Mike Frysinger <vapier@gentoo.org>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/blackfin/Kconfig               |  1 -
>  arch/blackfin/kernel/ftrace-entry.S | 18 ------------------
>  2 files changed, 19 deletions(-)
> 
> diff --git a/arch/blackfin/Kconfig b/arch/blackfin/Kconfig
> index f81e7b989fff..ed30699cc635 100644
> --- a/arch/blackfin/Kconfig
> +++ b/arch/blackfin/Kconfig
> @@ -18,7 +18,6 @@ config BLACKFIN
>  	select HAVE_FTRACE_MCOUNT_RECORD
>  	select HAVE_FUNCTION_GRAPH_TRACER
>  	select HAVE_FUNCTION_TRACER
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>  	select HAVE_IDE
>  	select HAVE_KERNEL_GZIP if RAMKERNEL
>  	select HAVE_KERNEL_BZIP2 if RAMKERNEL
> diff --git a/arch/blackfin/kernel/ftrace-entry.S b/arch/blackfin/kernel/ftrace-entry.S
> index 7eed00bbd26d..28d059540424 100644
> --- a/arch/blackfin/kernel/ftrace-entry.S
> +++ b/arch/blackfin/kernel/ftrace-entry.S
> @@ -33,15 +33,6 @@ ENDPROC(__mcount)
>   * function will be waiting there.  mmmm pie.
>   */
>  ENTRY(_ftrace_caller)
> -# ifdef CONFIG_HAVE_FUNCTION_TRACE_MCOUNT_TEST
> -	/* optional micro optimization: return if stopped */
> -	p1.l = _function_trace_stop;
> -	p1.h = _function_trace_stop;
> -	r3 = [p1];
> -	cc = r3 == 0;
> -	if ! cc jump _ftrace_stub (bp);
> -# endif
> -
>  	/* save first/second/third function arg and the return register */
>  	[--sp] = r2;
>  	[--sp] = r0;
> @@ -83,15 +74,6 @@ ENDPROC(_ftrace_caller)
>  
>  /* See documentation for _ftrace_caller */
>  ENTRY(__mcount)
> -# ifdef CONFIG_HAVE_FUNCTION_TRACE_MCOUNT_TEST
> -	/* optional micro optimization: return if stopped */
> -	p1.l = _function_trace_stop;
> -	p1.h = _function_trace_stop;
> -	r3 = [p1];
> -	cc = r3 == 0;
> -	if ! cc jump _ftrace_stub (bp);
> -# endif
> -
>  	/* save third function arg early so we can do testing below */
>  	[--sp] = r2;
>  


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

* Re: [RFA][PATCH 24/27] Blackfin: ftrace: Remove check of obsolete variable function_trace_stop
@ 2014-06-26 17:39     ` Steven Rostedt
  0 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 17:39 UTC (permalink / raw)
  Cc: linux-kernel, linux-arch, Mike Frysinger

On Thu, 26 Jun 2014 12:52:45 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> [ Please test this on your arch ]

From the cover letter, you were not Cc'd on.

Anyway, as there is no more reason to set function_trace_stop it is time
to remove it. Unfortunately it's in several archs in assembly. Most of
the assembly looks rather straight forward and I removed them myself.
But I was only able to compile test them (for archs: arm64, metag, and
microblaze I do not have my cross tools set up for them and did not
even compile test it). But I would really love it if people can
download their patch and test it out. You only need the patches that go
against your arch and to really test it, also include the patch titled: 

 ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST

Otherwise your arch patch will call the list op that still does the
check. That is, if you want to test suspend and resume on your arch.

As you may see, there are patches to the ftrace infrastructure that
depend on the arch patches being implemented. I removed the
functionality from the infrastructure, then removed it from the archs,
and then finally removed the existence of the function_trace_stop
variable, which would cause the archs to fail to compile if that were
to go first.

If you can test your arch and give me your acked-by, I would appreciate
it. Otherwise, if you need this to go through your tree, I would ask you
to set up a dedicated branch that I can pull from to keep this order
intact.

-- Steve

> 
> Cc: Mike Frysinger <vapier@gentoo.org>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/blackfin/Kconfig               |  1 -
>  arch/blackfin/kernel/ftrace-entry.S | 18 ------------------
>  2 files changed, 19 deletions(-)
> 
> diff --git a/arch/blackfin/Kconfig b/arch/blackfin/Kconfig
> index f81e7b989fff..ed30699cc635 100644
> --- a/arch/blackfin/Kconfig
> +++ b/arch/blackfin/Kconfig
> @@ -18,7 +18,6 @@ config BLACKFIN
>  	select HAVE_FTRACE_MCOUNT_RECORD
>  	select HAVE_FUNCTION_GRAPH_TRACER
>  	select HAVE_FUNCTION_TRACER
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>  	select HAVE_IDE
>  	select HAVE_KERNEL_GZIP if RAMKERNEL
>  	select HAVE_KERNEL_BZIP2 if RAMKERNEL
> diff --git a/arch/blackfin/kernel/ftrace-entry.S b/arch/blackfin/kernel/ftrace-entry.S
> index 7eed00bbd26d..28d059540424 100644
> --- a/arch/blackfin/kernel/ftrace-entry.S
> +++ b/arch/blackfin/kernel/ftrace-entry.S
> @@ -33,15 +33,6 @@ ENDPROC(__mcount)
>   * function will be waiting there.  mmmm pie.
>   */
>  ENTRY(_ftrace_caller)
> -# ifdef CONFIG_HAVE_FUNCTION_TRACE_MCOUNT_TEST
> -	/* optional micro optimization: return if stopped */
> -	p1.l = _function_trace_stop;
> -	p1.h = _function_trace_stop;
> -	r3 = [p1];
> -	cc = r3 == 0;
> -	if ! cc jump _ftrace_stub (bp);
> -# endif
> -
>  	/* save first/second/third function arg and the return register */
>  	[--sp] = r2;
>  	[--sp] = r0;
> @@ -83,15 +74,6 @@ ENDPROC(_ftrace_caller)
>  
>  /* See documentation for _ftrace_caller */
>  ENTRY(__mcount)
> -# ifdef CONFIG_HAVE_FUNCTION_TRACE_MCOUNT_TEST
> -	/* optional micro optimization: return if stopped */
> -	p1.l = _function_trace_stop;
> -	p1.h = _function_trace_stop;
> -	r3 = [p1];
> -	cc = r3 == 0;
> -	if ! cc jump _ftrace_stub (bp);
> -# endif
> -
>  	/* save third function arg early so we can do testing below */
>  	[--sp] = r2;
>  

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

* Re: [RFA][PATCH 25/27] arm64, ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` [RFA][PATCH 25/27] arm64, " Steven Rostedt
@ 2014-06-26 17:40     ` Steven Rostedt
  2014-06-27 12:44   ` Will Deacon
  1 sibling, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 17:40 UTC (permalink / raw)
  To: AKASHI Takahiro, Will Deacon; +Cc: linux-kernel, linux-arch

On Thu, 26 Jun 2014 12:52:46 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> arm64 was broken anyway, as it had an ifdef testing
>  CONFIG_HAVE_FUNCTION_TRACE_MCOUNT_TEST which is only set if
> the arch supports the code (which it obviously did not), and
> it was testing a non existent ftrace_trace_stop instead of
> function_trace_stop.

>From the cover letter, you were not Cc'd on.

Anyway, as there is no more reason to set function_trace_stop it is time
to remove it. Unfortunately it's in several archs in assembly. Most of
the assembly looks rather straight forward and I removed them myself.
But I was only able to compile test them (for archs: arm64, metag, and
microblaze I do not have my cross tools set up for them and did not
even compile test it). But I would really love it if people can
download their patch and test it out. You only need the patches that go
against your arch and to really test it, also include the patch titled: 

 ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST

Otherwise your arch patch will call the list op that still does the
check. That is, if you want to test suspend and resume on your arch.

As you may see, there are patches to the ftrace infrastructure that
depend on the arch patches being implemented. I removed the
functionality from the infrastructure, then removed it from the archs,
and then finally removed the existence of the function_trace_stop
variable, which would cause the archs to fail to compile if that were
to go first.

If you can test your arch and give me your acked-by, I would appreciate
it. Otherwise, if you need this to go through your tree, I would ask you
to set up a dedicated branch that I can pull from to keep this order
intact.

-- Steve

> 
> Cc: AKASHI Takahiro <takahiro.akashi@linaro.org>
> Cc: Will Deacon <will.deacon@arm.com>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/arm64/kernel/entry-ftrace.S | 5 -----
>  1 file changed, 5 deletions(-)
> 
> diff --git a/arch/arm64/kernel/entry-ftrace.S b/arch/arm64/kernel/entry-ftrace.S
> index b051871f2965..1b1e330e6849 100644
> --- a/arch/arm64/kernel/entry-ftrace.S
> +++ b/arch/arm64/kernel/entry-ftrace.S
> @@ -96,11 +96,6 @@
>   *     - ftrace_graph_caller to set up an exit hook
>   */
>  ENTRY(_mcount)
> -#ifdef CONFIG_HAVE_FUNCTION_TRACE_MCOUNT_TEST
> -	ldr	x0, =ftrace_trace_stop
> -	ldr	x0, [x0]		// if ftrace_trace_stop
> -	ret				//   return;
> -#endif
>  	mcount_enter
>  
>  	ldr	x0, =ftrace_trace_function


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

* Re: [RFA][PATCH 25/27] arm64, ftrace: Remove check of obsolete variable function_trace_stop
@ 2014-06-26 17:40     ` Steven Rostedt
  0 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 17:40 UTC (permalink / raw)
  To: AKASHI Takahiro, Will Deacon; +Cc: linux-kernel, linux-arch

On Thu, 26 Jun 2014 12:52:46 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> arm64 was broken anyway, as it had an ifdef testing
>  CONFIG_HAVE_FUNCTION_TRACE_MCOUNT_TEST which is only set if
> the arch supports the code (which it obviously did not), and
> it was testing a non existent ftrace_trace_stop instead of
> function_trace_stop.

From the cover letter, you were not Cc'd on.

Anyway, as there is no more reason to set function_trace_stop it is time
to remove it. Unfortunately it's in several archs in assembly. Most of
the assembly looks rather straight forward and I removed them myself.
But I was only able to compile test them (for archs: arm64, metag, and
microblaze I do not have my cross tools set up for them and did not
even compile test it). But I would really love it if people can
download their patch and test it out. You only need the patches that go
against your arch and to really test it, also include the patch titled: 

 ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST

Otherwise your arch patch will call the list op that still does the
check. That is, if you want to test suspend and resume on your arch.

As you may see, there are patches to the ftrace infrastructure that
depend on the arch patches being implemented. I removed the
functionality from the infrastructure, then removed it from the archs,
and then finally removed the existence of the function_trace_stop
variable, which would cause the archs to fail to compile if that were
to go first.

If you can test your arch and give me your acked-by, I would appreciate
it. Otherwise, if you need this to go through your tree, I would ask you
to set up a dedicated branch that I can pull from to keep this order
intact.

-- Steve

> 
> Cc: AKASHI Takahiro <takahiro.akashi@linaro.org>
> Cc: Will Deacon <will.deacon@arm.com>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/arm64/kernel/entry-ftrace.S | 5 -----
>  1 file changed, 5 deletions(-)
> 
> diff --git a/arch/arm64/kernel/entry-ftrace.S b/arch/arm64/kernel/entry-ftrace.S
> index b051871f2965..1b1e330e6849 100644
> --- a/arch/arm64/kernel/entry-ftrace.S
> +++ b/arch/arm64/kernel/entry-ftrace.S
> @@ -96,11 +96,6 @@
>   *     - ftrace_graph_caller to set up an exit hook
>   */
>  ENTRY(_mcount)
> -#ifdef CONFIG_HAVE_FUNCTION_TRACE_MCOUNT_TEST
> -	ldr	x0, =ftrace_trace_stop
> -	ldr	x0, [x0]		// if ftrace_trace_stop
> -	ret				//   return;
> -#endif
>  	mcount_enter
>  
>  	ldr	x0, =ftrace_trace_function

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

* Re: [RFA][PATCH 26/27] s390/ftrace: remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` [RFA][PATCH 26/27] s390/ftrace: remove " Steven Rostedt
@ 2014-06-26 17:41     ` Steven Rostedt
  0 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 17:41 UTC (permalink / raw)
  To: Heiko Carstens; +Cc: linux-kernel, linux-arch

On Thu, 26 Jun 2014 12:52:47 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: Heiko Carstens <heiko.carstens@de.ibm.com>
> 
> Remove check of obsolete variable function_trace_stop as requested by
> Steven Rostedt.

>From the cover letter, you were not Cc'd on.

Anyway, as there is no more reason to set function_trace_stop it is time
to remove it. Unfortunately it's in several archs in assembly. Most of
the assembly looks rather straight forward and I removed them myself.
But I was only able to compile test them (for archs: arm64, metag, and
microblaze I do not have my cross tools set up for them and did not
even compile test it). But I would really love it if people can
download their patch and test it out. You only need the patches that go
against your arch and to really test it, also include the patch titled: 

 ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST

Otherwise your arch patch will call the list op that still does the
check. That is, if you want to test suspend and resume on your arch.

As you may see, there are patches to the ftrace infrastructure that
depend on the arch patches being implemented. I removed the
functionality from the infrastructure, then removed it from the archs,
and then finally removed the existence of the function_trace_stop
variable, which would cause the archs to fail to compile if that were
to go first.

If you can test your arch and give me your acked-by, I would appreciate
it. Otherwise, if you need this to go through your tree, I would ask you
to set up a dedicated branch that I can pull from to keep this order
intact.
---

I know you wrote this patch, but you may want to test it out with
the ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST patch
applied too.

-- Steve

> 
> Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/s390/Kconfig           |  1 -
>  arch/s390/kernel/mcount.S   | 10 +++-------
>  arch/s390/kernel/mcount64.S |  3 ---
>  3 files changed, 3 insertions(+), 11 deletions(-)
> 
> diff --git a/arch/s390/Kconfig b/arch/s390/Kconfig
> index bb63499fc5d3..f5af5f6ef0f4 100644
> --- a/arch/s390/Kconfig
> +++ b/arch/s390/Kconfig
> @@ -116,7 +116,6 @@ config S390
>  	select HAVE_FTRACE_MCOUNT_RECORD
>  	select HAVE_FUNCTION_GRAPH_TRACER
>  	select HAVE_FUNCTION_TRACER
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>  	select HAVE_FUTEX_CMPXCHG if FUTEX
>  	select HAVE_KERNEL_BZIP2
>  	select HAVE_KERNEL_GZIP
> diff --git a/arch/s390/kernel/mcount.S b/arch/s390/kernel/mcount.S
> index 08dcf21cb8df..433c6dbfa442 100644
> --- a/arch/s390/kernel/mcount.S
> +++ b/arch/s390/kernel/mcount.S
> @@ -21,13 +21,9 @@ ENTRY(_mcount)
>  ENTRY(ftrace_caller)
>  #endif
>  	stm	%r2,%r5,16(%r15)
> -	bras	%r1,2f
> +	bras	%r1,1f
>  0:	.long	ftrace_trace_function
> -1:	.long	function_trace_stop
> -2:	l	%r2,1b-0b(%r1)
> -	icm	%r2,0xf,0(%r2)
> -	jnz	3f
> -	st	%r14,56(%r15)
> +1:	st	%r14,56(%r15)
>  	lr	%r0,%r15
>  	ahi	%r15,-96
>  	l	%r3,100(%r15)
> @@ -50,7 +46,7 @@ ENTRY(ftrace_graph_caller)
>  #endif
>  	ahi	%r15,96
>  	l	%r14,56(%r15)
> -3:	lm	%r2,%r5,16(%r15)
> +	lm	%r2,%r5,16(%r15)
>  	br	%r14
>  
>  #ifdef CONFIG_FUNCTION_GRAPH_TRACER
> diff --git a/arch/s390/kernel/mcount64.S b/arch/s390/kernel/mcount64.S
> index 1c52eae3396a..c67a8bf0fd9a 100644
> --- a/arch/s390/kernel/mcount64.S
> +++ b/arch/s390/kernel/mcount64.S
> @@ -20,9 +20,6 @@ ENTRY(_mcount)
>  
>  ENTRY(ftrace_caller)
>  #endif
> -	larl	%r1,function_trace_stop
> -	icm	%r1,0xf,0(%r1)
> -	bnzr	%r14
>  	stmg	%r2,%r5,32(%r15)
>  	stg	%r14,112(%r15)
>  	lgr	%r1,%r15


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

* Re: [RFA][PATCH 26/27] s390/ftrace: remove check of obsolete variable function_trace_stop
@ 2014-06-26 17:41     ` Steven Rostedt
  0 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 17:41 UTC (permalink / raw)
  To: Heiko Carstens; +Cc: linux-kernel, linux-arch

On Thu, 26 Jun 2014 12:52:47 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: Heiko Carstens <heiko.carstens@de.ibm.com>
> 
> Remove check of obsolete variable function_trace_stop as requested by
> Steven Rostedt.

From the cover letter, you were not Cc'd on.

Anyway, as there is no more reason to set function_trace_stop it is time
to remove it. Unfortunately it's in several archs in assembly. Most of
the assembly looks rather straight forward and I removed them myself.
But I was only able to compile test them (for archs: arm64, metag, and
microblaze I do not have my cross tools set up for them and did not
even compile test it). But I would really love it if people can
download their patch and test it out. You only need the patches that go
against your arch and to really test it, also include the patch titled: 

 ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST

Otherwise your arch patch will call the list op that still does the
check. That is, if you want to test suspend and resume on your arch.

As you may see, there are patches to the ftrace infrastructure that
depend on the arch patches being implemented. I removed the
functionality from the infrastructure, then removed it from the archs,
and then finally removed the existence of the function_trace_stop
variable, which would cause the archs to fail to compile if that were
to go first.

If you can test your arch and give me your acked-by, I would appreciate
it. Otherwise, if you need this to go through your tree, I would ask you
to set up a dedicated branch that I can pull from to keep this order
intact.
---

I know you wrote this patch, but you may want to test it out with
the ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST patch
applied too.

-- Steve

> 
> Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/s390/Kconfig           |  1 -
>  arch/s390/kernel/mcount.S   | 10 +++-------
>  arch/s390/kernel/mcount64.S |  3 ---
>  3 files changed, 3 insertions(+), 11 deletions(-)
> 
> diff --git a/arch/s390/Kconfig b/arch/s390/Kconfig
> index bb63499fc5d3..f5af5f6ef0f4 100644
> --- a/arch/s390/Kconfig
> +++ b/arch/s390/Kconfig
> @@ -116,7 +116,6 @@ config S390
>  	select HAVE_FTRACE_MCOUNT_RECORD
>  	select HAVE_FUNCTION_GRAPH_TRACER
>  	select HAVE_FUNCTION_TRACER
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>  	select HAVE_FUTEX_CMPXCHG if FUTEX
>  	select HAVE_KERNEL_BZIP2
>  	select HAVE_KERNEL_GZIP
> diff --git a/arch/s390/kernel/mcount.S b/arch/s390/kernel/mcount.S
> index 08dcf21cb8df..433c6dbfa442 100644
> --- a/arch/s390/kernel/mcount.S
> +++ b/arch/s390/kernel/mcount.S
> @@ -21,13 +21,9 @@ ENTRY(_mcount)
>  ENTRY(ftrace_caller)
>  #endif
>  	stm	%r2,%r5,16(%r15)
> -	bras	%r1,2f
> +	bras	%r1,1f
>  0:	.long	ftrace_trace_function
> -1:	.long	function_trace_stop
> -2:	l	%r2,1b-0b(%r1)
> -	icm	%r2,0xf,0(%r2)
> -	jnz	3f
> -	st	%r14,56(%r15)
> +1:	st	%r14,56(%r15)
>  	lr	%r0,%r15
>  	ahi	%r15,-96
>  	l	%r3,100(%r15)
> @@ -50,7 +46,7 @@ ENTRY(ftrace_graph_caller)
>  #endif
>  	ahi	%r15,96
>  	l	%r14,56(%r15)
> -3:	lm	%r2,%r5,16(%r15)
> +	lm	%r2,%r5,16(%r15)
>  	br	%r14
>  
>  #ifdef CONFIG_FUNCTION_GRAPH_TRACER
> diff --git a/arch/s390/kernel/mcount64.S b/arch/s390/kernel/mcount64.S
> index 1c52eae3396a..c67a8bf0fd9a 100644
> --- a/arch/s390/kernel/mcount64.S
> +++ b/arch/s390/kernel/mcount64.S
> @@ -20,9 +20,6 @@ ENTRY(_mcount)
>  
>  ENTRY(ftrace_caller)
>  #endif
> -	larl	%r1,function_trace_stop
> -	icm	%r1,0xf,0(%r1)
> -	bnzr	%r14
>  	stmg	%r2,%r5,32(%r15)
>  	stg	%r14,112(%r15)
>  	lgr	%r1,%r15

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

* Re: [RFA][PATCH 24/27] Blackfin: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` [RFA][PATCH 24/27] Blackfin: " Steven Rostedt
  2014-06-26 17:39     ` Steven Rostedt
@ 2014-06-26 19:25   ` Mike Frysinger
  2014-06-26 19:34     ` Steven Rostedt
  1 sibling, 1 reply; 89+ messages in thread
From: Mike Frysinger @ 2014-06-26 19:25 UTC (permalink / raw)
  To: Steven Rostedt
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	Masami Hiramatsu, H. Peter Anvin, linux-arch, Rafael J. Wysocki,
	Jiri Kosina, Josh Poimboeuf

[-- Attachment #1: Type: text/plain, Size: 492 bytes --]

On Thu 26 Jun 2014 12:52:45 Steven Rostedt wrote:
> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> [ Please test this on your arch ]

i haven't tested, but the asm looks correct -- it's only using scratch 
registers, and the rest of the code doesn't rely on the state in that ifdef 
(by design).

Acked-by: Mike Frysinger <vapier@gentoo.org>
-mike

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

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

* Re: [RFA][PATCH 24/27] Blackfin: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 19:25   ` Mike Frysinger
@ 2014-06-26 19:34     ` Steven Rostedt
  0 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-26 19:34 UTC (permalink / raw)
  To: Mike Frysinger
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	Masami Hiramatsu, H. Peter Anvin, linux-arch, Rafael J. Wysocki,
	Jiri Kosina, Josh Poimboeuf

On Thu, 26 Jun 2014 15:25:31 -0400
Mike Frysinger <vapier@gentoo.org> wrote:

> On Thu 26 Jun 2014 12:52:45 Steven Rostedt wrote:
> > From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> > 
> > Nothing sets function_trace_stop to disable function tracing anymore.
> > Remove the check for it in the arch code.
> > 
> > [ Please test this on your arch ]
> 
> i haven't tested, but the asm looks correct -- it's only using scratch 
> registers, and the rest of the code doesn't rely on the state in that ifdef 
> (by design).
> 
> Acked-by: Mike Frysinger <vapier@gentoo.org>
> -mike

Thanks!

-- Steve

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

* Re: [RFA][PATCH 26/27] s390/ftrace: remove check of obsolete variable function_trace_stop
  2014-06-26 17:41     ` Steven Rostedt
  (?)
@ 2014-06-27  6:01     ` Heiko Carstens
  -1 siblings, 0 replies; 89+ messages in thread
From: Heiko Carstens @ 2014-06-27  6:01 UTC (permalink / raw)
  To: Steven Rostedt; +Cc: linux-kernel, linux-arch

On Thu, Jun 26, 2014 at 01:41:41PM -0400, Steven Rostedt wrote:
> 
> I know you wrote this patch, but you may want to test it out with
> the ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST patch
> applied too.

In order to compile this, I'd have to apply all common code patches, I think.
But they don't apply against Linus' master tree and I wouldn't know which
tree these patches are against.
But anyway, it all looks good ;)

Acked-by: Heiko Carstens <heiko.carstens@de.ibm.com>


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

* Re: [RFA][PATCH 25/27] arm64, ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` [RFA][PATCH 25/27] arm64, " Steven Rostedt
  2014-06-26 17:40     ` Steven Rostedt
@ 2014-06-27 12:44   ` Will Deacon
  2014-07-01 11:33     ` AKASHI Takahiro
  1 sibling, 1 reply; 89+ messages in thread
From: Will Deacon @ 2014-06-27 12:44 UTC (permalink / raw)
  To: Steven Rostedt
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	Masami Hiramatsu, H. Peter Anvin, linux-arch, Rafael J. Wysocki,
	Jiri Kosina, Josh Poimboeuf, AKASHI Takahiro

Hi Steve,

On Thu, Jun 26, 2014 at 05:52:46PM +0100, Steven Rostedt wrote:
> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> arm64 was broken anyway, as it had an ifdef testing
>  CONFIG_HAVE_FUNCTION_TRACE_MCOUNT_TEST which is only set if
> the arch supports the code (which it obviously did not), and
> it was testing a non existent ftrace_trace_stop instead of
> function_trace_stop.

Yeah, the current code is total crap. Well spotted.

> Cc: AKASHI Takahiro <takahiro.akashi@linaro.org>
> Cc: Will Deacon <will.deacon@arm.com>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/arm64/kernel/entry-ftrace.S | 5 -----
>  1 file changed, 5 deletions(-)

  Acked-by: Will Deacon <will.deacon@arm.com>

I'm happy for you to take this via the ftrace tree, along with the rest of
the series.

I successfully ran the ftrace self tests with this applied (on top of
"ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST"), but note
that I don't have a platform with working suspend/resume right now.

Cheers,

Will

> diff --git a/arch/arm64/kernel/entry-ftrace.S b/arch/arm64/kernel/entry-ftrace.S
> index b051871f2965..1b1e330e6849 100644
> --- a/arch/arm64/kernel/entry-ftrace.S
> +++ b/arch/arm64/kernel/entry-ftrace.S
> @@ -96,11 +96,6 @@
>   *     - ftrace_graph_caller to set up an exit hook
>   */
>  ENTRY(_mcount)
> -#ifdef CONFIG_HAVE_FUNCTION_TRACE_MCOUNT_TEST
> -	ldr	x0, =ftrace_trace_stop
> -	ldr	x0, [x0]		// if ftrace_trace_stop
> -	ret				//   return;
> -#endif
>  	mcount_enter
>  
>  	ldr	x0, =ftrace_trace_function
> -- 
> 2.0.0
> 
> 
> 

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

* Re: [RFA][PATCH 01/27] x86, power, suspend: Annotate restore_processor_state() with notrace
  2014-06-26 16:52 ` [RFA][PATCH 01/27] x86, power, suspend: Annotate restore_processor_state() with notrace Steven Rostedt
@ 2014-06-28  0:02   ` Rafael J. Wysocki
  0 siblings, 0 replies; 89+ messages in thread
From: Rafael J. Wysocki @ 2014-06-28  0:02 UTC (permalink / raw)
  To: Steven Rostedt
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	Masami Hiramatsu, H. Peter Anvin, linux-arch, Jiri Kosina,
	Josh Poimboeuf

On Thursday, June 26, 2014 12:52:22 PM Steven Rostedt wrote:
> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> ftrace_stop() is used to stop function tracing during suspend and resume
> which removes a lot of possible debugging opportunities with tracing.
> The reason was that some function in the resume path was causing a triple
> fault if it were to be traced. The issue I found was that doing something
> as simple as calling smp_processor_id() would reboot the box!
> 
> When function tracing was first created I didn't have a good way to figure
> out what function was having issues, or it looked to be multiple ones. To
> fix it, we just created a big hammer approach to the problem which was to
> add a flag in the mcount trampoline that could be checked and not call
> the traced functions.
> 
> Lately I developed better ways to find problem functions and I can bisect
> down to see what function is causing the issue. I removed the flag that
> stopped tracing and proceeded to find the problem function and it ended
> up being restore_processor_state(). This function makes sense as when the
> CPU comes back online from a suspend it calls this function to set up
> registers, amongst them the GS register, which stores things such as
> what CPU the processor is (if you call smp_processor_id() without this
> set up properly, it would fault).
> 
> By making restore_processor_state() notrace, the system can suspend and
> resume without the need of the big hammer tracing to stop.
> 
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>

ACK

> ---
>  arch/x86/power/cpu.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/arch/x86/power/cpu.c b/arch/x86/power/cpu.c
> index 424f4c97a44d..6ec7910f59bf 100644
> --- a/arch/x86/power/cpu.c
> +++ b/arch/x86/power/cpu.c
> @@ -165,7 +165,7 @@ static void fix_processor_context(void)
>   *		by __save_processor_state()
>   *	@ctxt - structure to load the registers contents from
>   */
> -static void __restore_processor_state(struct saved_context *ctxt)
> +static void notrace __restore_processor_state(struct saved_context *ctxt)
>  {
>  	if (ctxt->misc_enable_saved)
>  		wrmsrl(MSR_IA32_MISC_ENABLE, ctxt->misc_enable);
> @@ -239,7 +239,7 @@ static void __restore_processor_state(struct saved_context *ctxt)
>  }
>  
>  /* Needed by apm.c */
> -void restore_processor_state(void)
> +void notrace restore_processor_state(void)
>  {
>  	__restore_processor_state(&saved_context);
>  }
> 

-- 
I speak only for myself.
Rafael J. Wysocki, Intel Open Source Technology Center.

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

* Re: [RFA][PATCH 02/27] PM / Sleep: Remove ftrace_stop/start() from suspend and hibernate
  2014-06-26 16:52 ` [RFA][PATCH 02/27] PM / Sleep: Remove ftrace_stop/start() from suspend and hibernate Steven Rostedt
@ 2014-06-28  0:02   ` Rafael J. Wysocki
  0 siblings, 0 replies; 89+ messages in thread
From: Rafael J. Wysocki @ 2014-06-28  0:02 UTC (permalink / raw)
  To: Steven Rostedt
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	Masami Hiramatsu, H. Peter Anvin, linux-arch, Jiri Kosina,
	Josh Poimboeuf

On Thursday, June 26, 2014 12:52:23 PM Steven Rostedt wrote:
> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> ftrace_stop() and ftrace_start() were added to the suspend and hibernate
> process because there was some function within the work flow that caused
> the system to reboot if it was traced. This function has recently been
> found (restore_processor_state()). Now there's no reason to disable
> function tracing while we are going into suspend or hibernate, which means
> that being able to trace this will help tremendously in debugging any
> issues with suspend or hibernate.
> 
> This also means that the ftrace_stop/start() functions can be removed
> and simplify the function tracing code a bit.
> 
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>

ACK

> ---
>  kernel/power/hibernate.c | 6 ------
>  kernel/power/suspend.c   | 2 --
>  2 files changed, 8 deletions(-)
> 
> diff --git a/kernel/power/hibernate.c b/kernel/power/hibernate.c
> index 49e0a20fd010..ca7b1906c6c8 100644
> --- a/kernel/power/hibernate.c
> +++ b/kernel/power/hibernate.c
> @@ -365,7 +365,6 @@ int hibernation_snapshot(int platform_mode)
>  	}
>  
>  	suspend_console();
> -	ftrace_stop();
>  	pm_restrict_gfp_mask();
>  
>  	error = dpm_suspend(PMSG_FREEZE);
> @@ -391,7 +390,6 @@ int hibernation_snapshot(int platform_mode)
>  	if (error || !in_suspend)
>  		pm_restore_gfp_mask();
>  
> -	ftrace_start();
>  	resume_console();
>  	dpm_complete(msg);
>  
> @@ -494,7 +492,6 @@ int hibernation_restore(int platform_mode)
>  
>  	pm_prepare_console();
>  	suspend_console();
> -	ftrace_stop();
>  	pm_restrict_gfp_mask();
>  	error = dpm_suspend_start(PMSG_QUIESCE);
>  	if (!error) {
> @@ -502,7 +499,6 @@ int hibernation_restore(int platform_mode)
>  		dpm_resume_end(PMSG_RECOVER);
>  	}
>  	pm_restore_gfp_mask();
> -	ftrace_start();
>  	resume_console();
>  	pm_restore_console();
>  	return error;
> @@ -529,7 +525,6 @@ int hibernation_platform_enter(void)
>  
>  	entering_platform_hibernation = true;
>  	suspend_console();
> -	ftrace_stop();
>  	error = dpm_suspend_start(PMSG_HIBERNATE);
>  	if (error) {
>  		if (hibernation_ops->recover)
> @@ -573,7 +568,6 @@ int hibernation_platform_enter(void)
>   Resume_devices:
>  	entering_platform_hibernation = false;
>  	dpm_resume_end(PMSG_RESTORE);
> -	ftrace_start();
>  	resume_console();
>  
>   Close:
> diff --git a/kernel/power/suspend.c b/kernel/power/suspend.c
> index 4dd8822f732a..f6623da034d8 100644
> --- a/kernel/power/suspend.c
> +++ b/kernel/power/suspend.c
> @@ -248,7 +248,6 @@ static int suspend_enter(suspend_state_t state, bool *wakeup)
>  		goto Platform_wake;
>  	}
>  
> -	ftrace_stop();
>  	error = disable_nonboot_cpus();
>  	if (error || suspend_test(TEST_CPUS))
>  		goto Enable_cpus;
> @@ -275,7 +274,6 @@ static int suspend_enter(suspend_state_t state, bool *wakeup)
>  
>   Enable_cpus:
>  	enable_nonboot_cpus();
> -	ftrace_start();
>  
>   Platform_wake:
>  	if (need_suspend_ops(state) && suspend_ops->wake)
> 

-- 
I speak only for myself.
Rafael J. Wysocki, Intel Open Source Technology Center.

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

* Re: [RFA][PATCH 20/27] parisc: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 17:35     ` Steven Rostedt
  (?)
@ 2014-06-29 21:20     ` Helge Deller
  2014-06-30 14:11       ` Steven Rostedt
  -1 siblings, 1 reply; 89+ messages in thread
From: Helge Deller @ 2014-06-29 21:20 UTC (permalink / raw)
  To: Steven Rostedt; +Cc: linux-kernel, linux-arch

Hi Steven,

On 06/26/2014 07:35 PM, Steven Rostedt wrote:
> On Thu, 26 Jun 2014 12:52:41 -0400
> Steven Rostedt <rostedt@goodmis.org> wrote:
> 
>> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
>>
>> Nothing sets function_trace_stop to disable function tracing anymore.
>> Remove the check for it in the arch code.
> 
> From the cover letter, you were not Cc'd on.
> 
> Anyway, as there is no more reason to set function_trace_stop it is time
> to remove it. Unfortunately it's in several archs in assembly. Most of
> the assembly looks rather straight forward and I removed them myself.
> But I was only able to compile test them (for archs: arm64, metag, and
> microblaze I do not have my cross tools set up for them and did not
> even compile test it). But I would really love it if people can
> download their patch and test it out. You only need the patches that go
> against your arch and to really test it, also include the patch titled: 
> 
>  ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST
> 
> Otherwise your arch patch will call the list op that still does the
> check. That is, if you want to test suspend and resume on your arch.
> 
> As you may see, there are patches to the ftrace infrastructure that
> depend on the arch patches being implemented. I removed the
> functionality from the infrastructure, then removed it from the archs,
> and then finally removed the existence of the function_trace_stop
> variable, which would cause the archs to fail to compile if that were
> to go first.
> 
> If you can test your arch and give me your acked-by, I would appreciate
> it. Otherwise, if you need this to go through your tree, I would ask you
> to set up a dedicated branch that I can pull from to keep this order
> intact.

Sadly the arch-related tracing code in parisc is really broken.
It doesn't even compile cleanly on parisc (at least on 64bit), and as I wrote you in another mail
I really need to fix this soon (which I already started on).

But your patches look clean, so to get the basics right, I'm happy to give a 
Acked-by: Helge Deller <deller@gmx.de>
for the two patches which affect parisc, which are:
[PATCH 08/27] parisc: ftrace: Add call to ftrace_graph_is_dead() in function graph code
[PATCH 20/27] parisc: ftrace: Remove check of obsolete variable function_trace_stop

It would be good if you can push them through your tree.
I assume your tree is: 
git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace.git
with branch ftrace/next. 
Is this correct?
If yes, I can build my patches upon this tree...

Thanks!
Helge


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

* Re: [RFA][PATCH 00/27] ftrace: Remove ftrace_start/stop() and friends
  2014-06-26 16:52 ` Steven Rostedt
                   ` (27 preceding siblings ...)
  (?)
@ 2014-06-30  3:13 ` Masami Hiramatsu
  2014-06-30 14:16   ` Steven Rostedt
  -1 siblings, 1 reply; 89+ messages in thread
From: Masami Hiramatsu @ 2014-06-30  3:13 UTC (permalink / raw)
  To: Steven Rostedt
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf

(2014/06/27 1:52), Steven Rostedt wrote:
> * Request for Acks *
> 
>>From the time I created the use of function_trace_stop, I hated it.
> There was two reasons to create this, one was to try to lower the
> function tracing overhead when debugfs file tracing_enable was set to zero
> (note, tracing_enable no longer exists), the other was a way to stop
> function tracing when going down into suspend and resume.
> 
> Some function was causing suspend and resume to reboot the kernel. In
> debugging this I found that an empty callback from mcount would work.
> That is, instead of running the tracing code, I would just have the
> function trace callback be a nop:
> 
>  void function_trace_call(unsigned long ip, unsigned long parent_ip)
>  {
>  }
> 
> This worked. That means the code in mcount wasn't an issue. I started
> bisecting the contents of the function_trace_call and found that this
> would cause the system to reboot!
> 
>  void function_trace_call(unsigned long ip, unsigned long parent_ip)
>  {
> 	smp_processor_id();
>  }
> 
> That is, just calling smp_processor_id() was enough to trigger a triple
> fault on resume of the system.
> 
> Today, this big hammer approach of disabling the function tracer is starting
> to show its issues. It can't help out in debugging suspend and resume,
> and there's other function trace callbacks that should still work.
> 
> I also have learned ways to bisect functions that cause bugs in function
> tracing. I finally got some time to do so with a box that would reboot
> on suspend and resume. This led me down to a single function:
> 
>  restore_processor_state()
> 
> This made perfect sense, as this function is called from assembly on a
> CPU startup. One of the jobs of this function was to set up the GS register.
> That register is also the register that is used by smp_processor_id()
> to find what CPU the task is running on. With it not set up it will offset
> into some random location and fault. As the fault handlers can also be
> traced, those will fault too and finally the system will reset due to a
> triple fault.

Uh, from the same reason, I must list it in the kprobe blacklist too...

BTW, as far as I can review, x86 and generic parts of the series seems
OK to me. :)

Thank you,

-- 
Masami HIRAMATSU
Software Platform Research Dept. Linux Technology Research Center
Hitachi, Ltd., Yokohama Research Laboratory
E-mail: masami.hiramatsu.pt@hitachi.com



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

* Re: [RFA][PATCH 20/27] parisc: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-29 21:20     ` Helge Deller
@ 2014-06-30 14:11       ` Steven Rostedt
  0 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-06-30 14:11 UTC (permalink / raw)
  To: Helge Deller; +Cc: linux-kernel, linux-arch

On Sun, 29 Jun 2014 23:20:23 +0200
Helge Deller <deller@gmx.de> wrote:

> Sadly the arch-related tracing code in parisc is really broken.
> It doesn't even compile cleanly on parisc (at least on 64bit), and as I wrote you in another mail
> I really need to fix this soon (which I already started on).
> 
> But your patches look clean, so to get the basics right, I'm happy to give a 
> Acked-by: Helge Deller <deller@gmx.de>
> for the two patches which affect parisc, which are:
> [PATCH 08/27] parisc: ftrace: Add call to ftrace_graph_is_dead() in function graph code
> [PATCH 20/27] parisc: ftrace: Remove check of obsolete variable function_trace_stop

Thanks!

> 
> It would be good if you can push them through your tree.
> I assume your tree is: 
> git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace.git
> with branch ftrace/next. 
> Is this correct?
> If yes, I can build my patches upon this tree...
> 

Actually the patches are in my branch: rfc/remove-function-trace-stop


-- Steve

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

* Re: [RFA][PATCH 00/27] ftrace: Remove ftrace_start/stop() and friends
  2014-06-30  3:13 ` [RFA][PATCH 00/27] ftrace: Remove ftrace_start/stop() and friends Masami Hiramatsu
@ 2014-06-30 14:16   ` Steven Rostedt
  2014-07-01  0:58     ` Masami Hiramatsu
  0 siblings, 1 reply; 89+ messages in thread
From: Steven Rostedt @ 2014-06-30 14:16 UTC (permalink / raw)
  To: Masami Hiramatsu
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf

On Mon, 30 Jun 2014 12:13:08 +0900
Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> wrote:

> Uh, from the same reason, I must list it in the kprobe blacklist too...

Ah yes!

> 
> BTW, as far as I can review, x86 and generic parts of the series seems
> OK to me. :)
> 

Can you post a Acked-by or Reviewed-by then?

Thanks,

-- Steve

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

* Re: Re: [RFA][PATCH 00/27] ftrace: Remove ftrace_start/stop() and friends
  2014-06-30 14:16   ` Steven Rostedt
@ 2014-07-01  0:58     ` Masami Hiramatsu
  0 siblings, 0 replies; 89+ messages in thread
From: Masami Hiramatsu @ 2014-07-01  0:58 UTC (permalink / raw)
  To: Steven Rostedt
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf

(2014/06/30 23:16), Steven Rostedt wrote:
> On Mon, 30 Jun 2014 12:13:08 +0900
> Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> wrote:
> 
>> Uh, from the same reason, I must list it in the kprobe blacklist too...
> 
> Ah yes!
> 
>>
>> BTW, as far as I can review, x86 and generic parts of the series seems
>> OK to me. :)
>>
> 
> Can you post a Acked-by or Reviewed-by then?

Yeah, Please feel free to add my Reviewed-by to 1-5, 11-16, and 27 :)

Reviewed-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>

Thank you!


-- 
Masami HIRAMATSU
Software Platform Research Dept. Linux Technology Research Center
Hitachi, Ltd., Yokohama Research Laboratory
E-mail: masami.hiramatsu.pt@hitachi.com



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

* Re: [RFA][PATCH 25/27] arm64, ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-27 12:44   ` Will Deacon
@ 2014-07-01 11:33     ` AKASHI Takahiro
  0 siblings, 0 replies; 89+ messages in thread
From: AKASHI Takahiro @ 2014-07-01 11:33 UTC (permalink / raw)
  To: Will Deacon, Steven Rostedt
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	Masami Hiramatsu, H. Peter Anvin, linux-arch, Rafael J. Wysocki,
	Jiri Kosina, Josh Poimboeuf

On 06/27/2014 09:44 PM, Will Deacon wrote:
> Hi Steve,
>
> On Thu, Jun 26, 2014 at 05:52:46PM +0100, Steven Rostedt wrote:
>> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
>>
>> Nothing sets function_trace_stop to disable function tracing anymore.
>> Remove the check for it in the arch code.
>>
>> arm64 was broken anyway, as it had an ifdef testing
>>   CONFIG_HAVE_FUNCTION_TRACE_MCOUNT_TEST which is only set if
>> the arch supports the code (which it obviously did not), and
>> it was testing a non existent ftrace_trace_stop instead of
>> function_trace_stop.
>
> Yeah, the current code is total crap. Well spotted.

Thank you for fixing my bug :)
I also exercised ftrace with sysfs interface, and it just works well.

-Takahiro AKASHI

>
>> Cc: AKASHI Takahiro <takahiro.akashi@linaro.org>
>> Cc: Will Deacon <will.deacon@arm.com>
>> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
>> ---
>>   arch/arm64/kernel/entry-ftrace.S | 5 -----
>>   1 file changed, 5 deletions(-)
>
>    Acked-by: Will Deacon <will.deacon@arm.com>
>
> I'm happy for you to take this via the ftrace tree, along with the rest of
> the series.
>
> I successfully ran the ftrace self tests with this applied (on top of
> "ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST"), but note
> that I don't have a platform with working suspend/resume right now.
>
> Cheers,
>
> Will
>
>> diff --git a/arch/arm64/kernel/entry-ftrace.S b/arch/arm64/kernel/entry-ftrace.S
>> index b051871f2965..1b1e330e6849 100644
>> --- a/arch/arm64/kernel/entry-ftrace.S
>> +++ b/arch/arm64/kernel/entry-ftrace.S
>> @@ -96,11 +96,6 @@
>>    *     - ftrace_graph_caller to set up an exit hook
>>    */
>>   ENTRY(_mcount)
>> -#ifdef CONFIG_HAVE_FUNCTION_TRACE_MCOUNT_TEST
>> -	ldr	x0, =ftrace_trace_stop
>> -	ldr	x0, [x0]		// if ftrace_trace_stop
>> -	ret				//   return;
>> -#endif
>>   	mcount_enter
>>
>>   	ldr	x0, =ftrace_trace_function
>> --
>> 2.0.0
>>
>>
>>

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

* Re: [RFA][PATCH 23/27] metag: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 17:38     ` Steven Rostedt
@ 2014-07-02 13:34       ` James Hogan
  -1 siblings, 0 replies; 89+ messages in thread
From: James Hogan @ 2014-07-02 13:34 UTC (permalink / raw)
  To: Steven Rostedt; +Cc: linux-kernel, linux-arch

On 26/06/14 18:38, Steven Rostedt wrote:
> On Thu, 26 Jun 2014 12:52:44 -0400
> Steven Rostedt <rostedt@goodmis.org> wrote:
> 
>> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
>>
>> Nothing sets function_trace_stop to disable function tracing anymore.
>> Remove the check for it in the arch code.
>>
>> [ Please test this on your arch ]
> 
> From the cover letter, you were not Cc'd on.
> 
> Anyway, as there is no more reason to set function_trace_stop it is time
> to remove it. Unfortunately it's in several archs in assembly. Most of
> the assembly looks rather straight forward and I removed them myself.
> But I was only able to compile test them (for archs: arm64, metag, and
> microblaze I do not have my cross tools set up for them and did not
> even compile test it). But I would really love it if people can
> download their patch and test it out. You only need the patches that go
> against your arch and to really test it, also include the patch titled: 
> 
>  ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST
> 
> Otherwise your arch patch will call the list op that still does the
> check. That is, if you want to test suspend and resume on your arch.
> 
> As you may see, there are patches to the ftrace infrastructure that
> depend on the arch patches being implemented. I removed the
> functionality from the infrastructure, then removed it from the archs,
> and then finally removed the existence of the function_trace_stop
> variable, which would cause the archs to fail to compile if that were
> to go first.
> 
> If you can test your arch and give me your acked-by, I would appreciate
> it. Otherwise, if you need this to go through your tree, I would ask you
> to set up a dedicated branch that I can pull from to keep this order
> intact.
> 

This patch is pretty much the inverse of the original patch that added
it, so looks good to me (and it didn't seem to break anything).

So, for both this patch and the "ftrace: Remove check for
HAVE_FUNCTION_TRACE_MCOUNT_TEST" one:

Acked-by: James Hogan <james.hogan@imgtec.com>

Cheers
James

> -- Steve
> 
>>
>> Cc: James Hogan <james.hogan@imgtec.com>
>> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
>> ---
>>  arch/metag/Kconfig              |  1 -
>>  arch/metag/kernel/ftrace_stub.S | 14 --------------
>>  2 files changed, 15 deletions(-)
>>
>> diff --git a/arch/metag/Kconfig b/arch/metag/Kconfig
>> index 499b7610eaaf..0b389a81c43a 100644
>> --- a/arch/metag/Kconfig
>> +++ b/arch/metag/Kconfig
>> @@ -13,7 +13,6 @@ config METAG
>>  	select HAVE_DYNAMIC_FTRACE
>>  	select HAVE_FTRACE_MCOUNT_RECORD
>>  	select HAVE_FUNCTION_TRACER
>> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>>  	select HAVE_KERNEL_BZIP2
>>  	select HAVE_KERNEL_GZIP
>>  	select HAVE_KERNEL_LZO
>> diff --git a/arch/metag/kernel/ftrace_stub.S b/arch/metag/kernel/ftrace_stub.S
>> index e70bff745bdd..3acc288217c0 100644
>> --- a/arch/metag/kernel/ftrace_stub.S
>> +++ b/arch/metag/kernel/ftrace_stub.S
>> @@ -16,13 +16,6 @@ _mcount_wrapper:
>>  	.global _ftrace_caller
>>  	.type	_ftrace_caller,function
>>  _ftrace_caller:
>> -	MOVT    D0Re0,#HI(_function_trace_stop)
>> -	ADD	D0Re0,D0Re0,#LO(_function_trace_stop)
>> -	GETD	D0Re0,[D0Re0]
>> -	CMP	D0Re0,#0
>> -	BEQ	$Lcall_stub
>> -	MOV	PC,D0.4
>> -$Lcall_stub:
>>  	MSETL   [A0StP], D0Ar6, D0Ar4, D0Ar2, D0.4
>>  	MOV     D1Ar1, D0.4
>>  	MOV     D0Ar2, D1RtP
>> @@ -42,13 +35,6 @@ _ftrace_call:
>>  	.global	_mcount_wrapper
>>  	.type	_mcount_wrapper,function
>>  _mcount_wrapper:
>> -	MOVT    D0Re0,#HI(_function_trace_stop)
>> -	ADD	D0Re0,D0Re0,#LO(_function_trace_stop)
>> -	GETD	D0Re0,[D0Re0]
>> -	CMP	D0Re0,#0
>> -	BEQ	$Lcall_mcount
>> -	MOV	PC,D0.4
>> -$Lcall_mcount:
>>  	MSETL   [A0StP], D0Ar6, D0Ar4, D0Ar2, D0.4
>>  	MOV     D1Ar1, D0.4
>>  	MOV     D0Ar2, D1RtP
> 

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

* Re: [RFA][PATCH 23/27] metag: ftrace: Remove check of obsolete variable function_trace_stop
@ 2014-07-02 13:34       ` James Hogan
  0 siblings, 0 replies; 89+ messages in thread
From: James Hogan @ 2014-07-02 13:34 UTC (permalink / raw)
  To: Steven Rostedt; +Cc: linux-kernel, linux-arch

On 26/06/14 18:38, Steven Rostedt wrote:
> On Thu, 26 Jun 2014 12:52:44 -0400
> Steven Rostedt <rostedt@goodmis.org> wrote:
> 
>> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
>>
>> Nothing sets function_trace_stop to disable function tracing anymore.
>> Remove the check for it in the arch code.
>>
>> [ Please test this on your arch ]
> 
> From the cover letter, you were not Cc'd on.
> 
> Anyway, as there is no more reason to set function_trace_stop it is time
> to remove it. Unfortunately it's in several archs in assembly. Most of
> the assembly looks rather straight forward and I removed them myself.
> But I was only able to compile test them (for archs: arm64, metag, and
> microblaze I do not have my cross tools set up for them and did not
> even compile test it). But I would really love it if people can
> download their patch and test it out. You only need the patches that go
> against your arch and to really test it, also include the patch titled: 
> 
>  ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST
> 
> Otherwise your arch patch will call the list op that still does the
> check. That is, if you want to test suspend and resume on your arch.
> 
> As you may see, there are patches to the ftrace infrastructure that
> depend on the arch patches being implemented. I removed the
> functionality from the infrastructure, then removed it from the archs,
> and then finally removed the existence of the function_trace_stop
> variable, which would cause the archs to fail to compile if that were
> to go first.
> 
> If you can test your arch and give me your acked-by, I would appreciate
> it. Otherwise, if you need this to go through your tree, I would ask you
> to set up a dedicated branch that I can pull from to keep this order
> intact.
> 

This patch is pretty much the inverse of the original patch that added
it, so looks good to me (and it didn't seem to break anything).

So, for both this patch and the "ftrace: Remove check for
HAVE_FUNCTION_TRACE_MCOUNT_TEST" one:

Acked-by: James Hogan <james.hogan@imgtec.com>

Cheers
James

> -- Steve
> 
>>
>> Cc: James Hogan <james.hogan@imgtec.com>
>> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
>> ---
>>  arch/metag/Kconfig              |  1 -
>>  arch/metag/kernel/ftrace_stub.S | 14 --------------
>>  2 files changed, 15 deletions(-)
>>
>> diff --git a/arch/metag/Kconfig b/arch/metag/Kconfig
>> index 499b7610eaaf..0b389a81c43a 100644
>> --- a/arch/metag/Kconfig
>> +++ b/arch/metag/Kconfig
>> @@ -13,7 +13,6 @@ config METAG
>>  	select HAVE_DYNAMIC_FTRACE
>>  	select HAVE_FTRACE_MCOUNT_RECORD
>>  	select HAVE_FUNCTION_TRACER
>> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>>  	select HAVE_KERNEL_BZIP2
>>  	select HAVE_KERNEL_GZIP
>>  	select HAVE_KERNEL_LZO
>> diff --git a/arch/metag/kernel/ftrace_stub.S b/arch/metag/kernel/ftrace_stub.S
>> index e70bff745bdd..3acc288217c0 100644
>> --- a/arch/metag/kernel/ftrace_stub.S
>> +++ b/arch/metag/kernel/ftrace_stub.S
>> @@ -16,13 +16,6 @@ _mcount_wrapper:
>>  	.global _ftrace_caller
>>  	.type	_ftrace_caller,function
>>  _ftrace_caller:
>> -	MOVT    D0Re0,#HI(_function_trace_stop)
>> -	ADD	D0Re0,D0Re0,#LO(_function_trace_stop)
>> -	GETD	D0Re0,[D0Re0]
>> -	CMP	D0Re0,#0
>> -	BEQ	$Lcall_stub
>> -	MOV	PC,D0.4
>> -$Lcall_stub:
>>  	MSETL   [A0StP], D0Ar6, D0Ar4, D0Ar2, D0.4
>>  	MOV     D1Ar1, D0.4
>>  	MOV     D0Ar2, D1RtP
>> @@ -42,13 +35,6 @@ _ftrace_call:
>>  	.global	_mcount_wrapper
>>  	.type	_mcount_wrapper,function
>>  _mcount_wrapper:
>> -	MOVT    D0Re0,#HI(_function_trace_stop)
>> -	ADD	D0Re0,D0Re0,#LO(_function_trace_stop)
>> -	GETD	D0Re0,[D0Re0]
>> -	CMP	D0Re0,#0
>> -	BEQ	$Lcall_mcount
>> -	MOV	PC,D0.4
>> -$Lcall_mcount:
>>  	MSETL   [A0StP], D0Ar6, D0Ar4, D0Ar2, D0.4
>>  	MOV     D1Ar1, D0.4
>>  	MOV     D0Ar2, D1RtP
> 

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

* Re: [RFA][PATCH 23/27] metag: ftrace: Remove check of obsolete variable function_trace_stop
  2014-07-02 13:34       ` James Hogan
@ 2014-07-02 14:22         ` Steven Rostedt
  -1 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-07-02 14:22 UTC (permalink / raw)
  To: James Hogan; +Cc: linux-kernel, linux-arch

On Wed, 2 Jul 2014 14:34:07 +0100
James Hogan <james.hogan@imgtec.com> wrote:

> This patch is pretty much the inverse of the original patch that added
> it, so looks good to me (and it didn't seem to break anything).
> 
> So, for both this patch and the "ftrace: Remove check for
> HAVE_FUNCTION_TRACE_MCOUNT_TEST" one:
> 
> Acked-by: James Hogan <james.hogan@imgtec.com>

Thanks!

-- Steve


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

* Re: [RFA][PATCH 23/27] metag: ftrace: Remove check of obsolete variable function_trace_stop
@ 2014-07-02 14:22         ` Steven Rostedt
  0 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-07-02 14:22 UTC (permalink / raw)
  To: James Hogan; +Cc: linux-kernel, linux-arch

On Wed, 2 Jul 2014 14:34:07 +0100
James Hogan <james.hogan@imgtec.com> wrote:

> This patch is pretty much the inverse of the original patch that added
> it, so looks good to me (and it didn't seem to break anything).
> 
> So, for both this patch and the "ftrace: Remove check for
> HAVE_FUNCTION_TRACE_MCOUNT_TEST" one:
> 
> Acked-by: James Hogan <james.hogan@imgtec.com>

Thanks!

-- Steve

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

* Re: [RFA][PATCH 07/27] MIPS: ftrace: Add call to ftrace_graph_is_dead() in function graph code
  2014-06-26 16:52 ` [RFA][PATCH 07/27] MIPS: " Steven Rostedt
@ 2014-07-02 14:31   ` Steven Rostedt
  2014-07-09 15:48       ` James Hogan
  2014-07-03 16:36   ` Steven Rostedt
  1 sibling, 1 reply; 89+ messages in thread
From: Steven Rostedt @ 2014-07-02 14:31 UTC (permalink / raw)
  To: linux-mips
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	Masami Hiramatsu, H. Peter Anvin, linux-arch, Rafael J. Wysocki,
	Jiri Kosina, Josh Poimboeuf, Ralf Baechle


Adding linux-mips@linux-mips.org.

-- Steve


On Thu, 26 Jun 2014 12:52:28 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> ftrace_stop() is going away as it disables parts of function tracing
> that affects users that should not be affected. But ftrace_graph_stop()
> is built on ftrace_stop(). Here's another example of killing all of
> function tracing because something went wrong with function graph
> tracing.
> 
> Instead of disabling all users of function tracing on function graph
> error, disable only function graph tracing. To do this, the arch code
> must call ftrace_graph_is_dead() before it implements function graph.
> 
> Cc: Ralf Baechle <ralf@linux-mips.org>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/mips/kernel/ftrace.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/arch/mips/kernel/ftrace.c b/arch/mips/kernel/ftrace.c
> index 60e7e5e45af1..8b6538750fe1 100644
> --- a/arch/mips/kernel/ftrace.c
> +++ b/arch/mips/kernel/ftrace.c
> @@ -302,6 +302,9 @@ void prepare_ftrace_return(unsigned long *parent_ra_addr, unsigned long self_ra,
>  	    &return_to_handler;
>  	int faulted, insns;
>  
> +	if (unlikely(ftrace_graph_is_dead()))
> +		return;
> +
>  	if (unlikely(atomic_read(&current->tracing_graph_pause)))
>  		return;
>  


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

* Re: [RFA][PATCH 21/27] MIPS: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` [RFA][PATCH 21/27] MIPS: " Steven Rostedt
  2014-06-26 17:37     ` Steven Rostedt
@ 2014-07-02 14:32   ` Steven Rostedt
  2014-07-09 14:15   ` Steven Rostedt
  2014-07-15 21:58   ` Steven Rostedt
  3 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-07-02 14:32 UTC (permalink / raw)
  To: linux-mips
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	Masami Hiramatsu, H. Peter Anvin, linux-arch, Rafael J. Wysocki,
	Jiri Kosina, Josh Poimboeuf


Adding linux-mips@linux-mips.org.

-- Steve

On Thu, 26 Jun 2014 12:52:42 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> [ Please test this on your arch ]
> 
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/mips/Kconfig         | 1 -
>  arch/mips/kernel/mcount.S | 7 -------
>  2 files changed, 8 deletions(-)
> 
> diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig
> index 7a469acee33c..9ca52987fcd5 100644
> --- a/arch/mips/Kconfig
> +++ b/arch/mips/Kconfig
> @@ -15,7 +15,6 @@ config MIPS
>  	select HAVE_BPF_JIT if !CPU_MICROMIPS
>  	select ARCH_HAVE_CUSTOM_GPIO_H
>  	select HAVE_FUNCTION_TRACER
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>  	select HAVE_DYNAMIC_FTRACE
>  	select HAVE_FTRACE_MCOUNT_RECORD
>  	select HAVE_C_RECORDMCOUNT
> diff --git a/arch/mips/kernel/mcount.S b/arch/mips/kernel/mcount.S
> index 539b6294b613..00940d1d5c4f 100644
> --- a/arch/mips/kernel/mcount.S
> +++ b/arch/mips/kernel/mcount.S
> @@ -74,10 +74,6 @@ _mcount:
>  #endif
>  
>  	/* When tracing is activated, it calls ftrace_caller+8 (aka here) */
> -	lw	t1, function_trace_stop
> -	bnez	t1, ftrace_stub
> -	 nop
> -
>  	MCOUNT_SAVE_REGS
>  #ifdef KBUILD_MCOUNT_RA_ADDRESS
>  	PTR_S	MCOUNT_RA_ADDRESS_REG, PT_R12(sp)
> @@ -105,9 +101,6 @@ ftrace_stub:
>  #else	/* ! CONFIG_DYNAMIC_FTRACE */
>  
>  NESTED(_mcount, PT_SIZE, ra)
> -	lw	t1, function_trace_stop
> -	bnez	t1, ftrace_stub
> -	 nop
>  	PTR_LA	t1, ftrace_stub
>  	PTR_L	t2, ftrace_trace_function /* Prepare t2 for (1) */
>  	bne	t1, t2, static_trace


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

* Re: [RFA][PATCH 17/27] tile: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` [RFA][PATCH 17/27] tile: ftrace: " Steven Rostedt
@ 2014-07-03 13:53     ` Chris Metcalf
  2014-07-03 13:53     ` Chris Metcalf
  1 sibling, 0 replies; 89+ messages in thread
From: Chris Metcalf @ 2014-07-03 13:53 UTC (permalink / raw)
  To: Steven Rostedt, linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf, Tony Lu

On 6/26/2014 12:52 PM, Steven Rostedt wrote:
> From: "Steven Rostedt (Red Hat)"<rostedt@goodmis.org>
>
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
>
> [ Please test this on your arch ]
>
> Cc: Chris Metcalf<cmetcalf@tilera.com>
> Signed-off-by: Steven Rostedt<rostedt@goodmis.org>

I forwarded this internally to the guy who did the work at Tilera and he's happy with the change.

Acked-by: Zhigang Lu<zlu@tilera.com>

-- 
Chris Metcalf, Tilera Corp.
http://www.tilera.com


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

* Re: [RFA][PATCH 17/27] tile: ftrace: Remove check of obsolete variable function_trace_stop
@ 2014-07-03 13:53     ` Chris Metcalf
  0 siblings, 0 replies; 89+ messages in thread
From: Chris Metcalf @ 2014-07-03 13:53 UTC (permalink / raw)
  To: Steven Rostedt, linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	H. Peter Anvin, linux-arch, Rafael J. Wysocki, Jiri Kosina,
	Josh Poimboeuf, Tony Lu

On 6/26/2014 12:52 PM, Steven Rostedt wrote:
> From: "Steven Rostedt (Red Hat)"<rostedt@goodmis.org>
>
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
>
> [ Please test this on your arch ]
>
> Cc: Chris Metcalf<cmetcalf@tilera.com>
> Signed-off-by: Steven Rostedt<rostedt@goodmis.org>

I forwarded this internally to the guy who did the work at Tilera and he's happy with the change.

Acked-by: Zhigang Lu<zlu@tilera.com>

-- 
Chris Metcalf, Tilera Corp.
http://www.tilera.com

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

* Re: [RFA][PATCH 17/27] tile: ftrace: Remove check of obsolete variable function_trace_stop
  2014-07-03 13:53     ` Chris Metcalf
@ 2014-07-03 14:02       ` Steven Rostedt
  -1 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-07-03 14:02 UTC (permalink / raw)
  To: Chris Metcalf
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	Masami Hiramatsu, H. Peter Anvin, linux-arch, Rafael J. Wysocki,
	Jiri Kosina, Josh Poimboeuf, Tony Lu

On Thu, 3 Jul 2014 09:53:37 -0400
Chris Metcalf <cmetcalf@tilera.com> wrote:

> On 6/26/2014 12:52 PM, Steven Rostedt wrote:
> > From: "Steven Rostedt (Red Hat)"<rostedt@goodmis.org>
> >
> > Nothing sets function_trace_stop to disable function tracing anymore.
> > Remove the check for it in the arch code.
> >
> > [ Please test this on your arch ]
> >
> > Cc: Chris Metcalf<cmetcalf@tilera.com>
> > Signed-off-by: Steven Rostedt<rostedt@goodmis.org>
> 
> I forwarded this internally to the guy who did the work at Tilera and he's happy with the change.
> 
> Acked-by: Zhigang Lu<zlu@tilera.com>
> 

Thanks!

-- Steve

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

* Re: [RFA][PATCH 17/27] tile: ftrace: Remove check of obsolete variable function_trace_stop
@ 2014-07-03 14:02       ` Steven Rostedt
  0 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-07-03 14:02 UTC (permalink / raw)
  To: Chris Metcalf
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	Masami Hiramatsu, H. Peter Anvin, linux-arch, Rafael J. Wysocki,
	Jiri Kosina, Josh Poimboeuf, Tony Lu

On Thu, 3 Jul 2014 09:53:37 -0400
Chris Metcalf <cmetcalf@tilera.com> wrote:

> On 6/26/2014 12:52 PM, Steven Rostedt wrote:
> > From: "Steven Rostedt (Red Hat)"<rostedt@goodmis.org>
> >
> > Nothing sets function_trace_stop to disable function tracing anymore.
> > Remove the check for it in the arch code.
> >
> > [ Please test this on your arch ]
> >
> > Cc: Chris Metcalf<cmetcalf@tilera.com>
> > Signed-off-by: Steven Rostedt<rostedt@goodmis.org>
> 
> I forwarded this internally to the guy who did the work at Tilera and he's happy with the change.
> 
> Acked-by: Zhigang Lu<zlu@tilera.com>
> 

Thanks!

-- Steve

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

* Re: [RFA][PATCH 06/27] microblaze: ftrace: Add call to ftrace_graph_is_dead() in function graph code
  2014-06-26 16:52 ` [RFA][PATCH 06/27] microblaze: ftrace: " Steven Rostedt
@ 2014-07-03 16:34   ` Steven Rostedt
  2014-07-09 14:03   ` Steven Rostedt
  1 sibling, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-07-03 16:34 UTC (permalink / raw)
  To: Steven Rostedt
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	Masami Hiramatsu, H. Peter Anvin, linux-arch, Rafael J. Wysocki,
	Jiri Kosina, Josh Poimboeuf, Michal Simek

Michal,

Can you give me your Acked-by on this and patch 22? I'm still waiting
of a few arch maintainers before I can push these up to my for-next
branch.

-- Steve


On Thu, 26 Jun 2014 12:52:27 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> ftrace_stop() is going away as it disables parts of function tracing
> that affects users that should not be affected. But ftrace_graph_stop()
> is built on ftrace_stop(). Here's another example of killing all of
> function tracing because something went wrong with function graph
> tracing.
> 
> Instead of disabling all users of function tracing on function graph
> error, disable only function graph tracing. To do this, the arch code
> must call ftrace_graph_is_dead() before it implements function graph.
> 
> Cc: Michal Simek <monstr@monstr.eu>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/microblaze/kernel/ftrace.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/arch/microblaze/kernel/ftrace.c b/arch/microblaze/kernel/ftrace.c
> index bbcd2533766c..fc7b48a52cd5 100644
> --- a/arch/microblaze/kernel/ftrace.c
> +++ b/arch/microblaze/kernel/ftrace.c
> @@ -27,6 +27,9 @@ void prepare_ftrace_return(unsigned long *parent, unsigned long self_addr)
>  	unsigned long return_hooker = (unsigned long)
>  				&return_to_handler;
>  
> +	if (unlikely(ftrace_graph_is_dead()))
> +		return;
> +
>  	if (unlikely(atomic_read(&current->tracing_graph_pause)))
>  		return;
>  


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

* Re: [RFA][PATCH 07/27] MIPS: ftrace: Add call to ftrace_graph_is_dead() in function graph code
  2014-06-26 16:52 ` [RFA][PATCH 07/27] MIPS: " Steven Rostedt
  2014-07-02 14:31   ` Steven Rostedt
@ 2014-07-03 16:36   ` Steven Rostedt
  1 sibling, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-07-03 16:36 UTC (permalink / raw)
  To: Ralf Baechle
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	Masami Hiramatsu, H. Peter Anvin, linux-arch, Rafael J. Wysocki,
	Jiri Kosina, Josh Poimboeuf, linux-mips

Ralf,

Can you give me your Acked-by on this and patch 21. I'm still waiting
on a few arch maintainers for acks before I can push this to my
for-next branch.

Thanks,

-- Steve


On Thu, 26 Jun 2014 12:52:28 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> ftrace_stop() is going away as it disables parts of function tracing
> that affects users that should not be affected. But ftrace_graph_stop()
> is built on ftrace_stop(). Here's another example of killing all of
> function tracing because something went wrong with function graph
> tracing.
> 
> Instead of disabling all users of function tracing on function graph
> error, disable only function graph tracing. To do this, the arch code
> must call ftrace_graph_is_dead() before it implements function graph.
> 
> Cc: Ralf Baechle <ralf@linux-mips.org>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/mips/kernel/ftrace.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/arch/mips/kernel/ftrace.c b/arch/mips/kernel/ftrace.c
> index 60e7e5e45af1..8b6538750fe1 100644
> --- a/arch/mips/kernel/ftrace.c
> +++ b/arch/mips/kernel/ftrace.c
> @@ -302,6 +302,9 @@ void prepare_ftrace_return(unsigned long *parent_ra_addr, unsigned long self_ra,
>  	    &return_to_handler;
>  	int faulted, insns;
>  
> +	if (unlikely(ftrace_graph_is_dead()))
> +		return;
> +
>  	if (unlikely(atomic_read(&current->tracing_graph_pause)))
>  		return;
>  


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

* Re: [RFA][PATCH 18/27] sparc64,ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` [RFA][PATCH 18/27] sparc64,ftrace: " Steven Rostedt
@ 2014-07-03 16:41     ` Steven Rostedt
  2014-07-03 16:41     ` Steven Rostedt
  1 sibling, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-07-03 16:41 UTC (permalink / raw)
  To: Steven Rostedt
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	Masami Hiramatsu, H. Peter Anvin, linux-arch, Rafael J. Wysocki,
	Jiri Kosina, Josh Poimboeuf, David S. Miller, sparclinux


David,

Do you have any problem with this patch going through my tree? It
compiles, but I do not have any hardware to test it. If you can verify
that this patch works and ack it, it would be much appreciated.

This code is at:

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

branch: rfc/remove-function-trace-stop

Thanks!

-- Steve

On Thu, 26 Jun 2014 12:52:39 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> [ Please test this on your arch ]
> 
> Cc: David S. Miller <davem@davemloft.net>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/sparc/Kconfig      |  1 -
>  arch/sparc/lib/mcount.S | 10 ++--------
>  2 files changed, 2 insertions(+), 9 deletions(-)
> 
> diff --git a/arch/sparc/Kconfig b/arch/sparc/Kconfig
> index 29f2e988c56a..abd7d5575a7d 100644
> --- a/arch/sparc/Kconfig
> +++ b/arch/sparc/Kconfig
> @@ -55,7 +55,6 @@ config SPARC64
>  	select HAVE_FUNCTION_TRACER
>  	select HAVE_FUNCTION_GRAPH_TRACER
>  	select HAVE_FUNCTION_GRAPH_FP_TEST
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>  	select HAVE_KRETPROBES
>  	select HAVE_KPROBES
>  	select HAVE_RCU_TABLE_FREE if SMP
> diff --git a/arch/sparc/lib/mcount.S b/arch/sparc/lib/mcount.S
> index 3ad6cbdc2163..0b0ed4d34219 100644
> --- a/arch/sparc/lib/mcount.S
> +++ b/arch/sparc/lib/mcount.S
> @@ -24,10 +24,7 @@ mcount:
>  #ifdef CONFIG_DYNAMIC_FTRACE
>  	/* Do nothing, the retl/nop below is all we need.  */
>  #else
> -	sethi		%hi(function_trace_stop), %g1
> -	lduw		[%g1 + %lo(function_trace_stop)], %g2
> -	brnz,pn		%g2, 2f
> -	 sethi		%hi(ftrace_trace_function), %g1
> +	sethi		%hi(ftrace_trace_function), %g1
>  	sethi		%hi(ftrace_stub), %g2
>  	ldx		[%g1 + %lo(ftrace_trace_function)], %g1
>  	or		%g2, %lo(ftrace_stub), %g2
> @@ -80,11 +77,8 @@ ftrace_stub:
>  	.globl		ftrace_caller
>  	.type		ftrace_caller,#function
>  ftrace_caller:
> -	sethi		%hi(function_trace_stop), %g1
>  	mov		%i7, %g2
> -	lduw		[%g1 + %lo(function_trace_stop)], %g1
> -	brnz,pn		%g1, ftrace_stub
> -	 mov		%fp, %g3
> +	mov		%fp, %g3
>  	save		%sp, -176, %sp
>  	mov		%g2, %o1
>  	mov		%g2, %l0


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

* Re: [RFA][PATCH 18/27] sparc64,ftrace: Remove check of obsolete variable function_trace_stop
@ 2014-07-03 16:41     ` Steven Rostedt
  0 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-07-03 16:41 UTC (permalink / raw)
  To: Steven Rostedt
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	Masami Hiramatsu, H. Peter Anvin, linux-arch, Rafael J. Wysocki,
	Jiri Kosina, Josh Poimboeuf, David S. Miller, sparclinux


David,

Do you have any problem with this patch going through my tree? It
compiles, but I do not have any hardware to test it. If you can verify
that this patch works and ack it, it would be much appreciated.

This code is at:

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

branch: rfc/remove-function-trace-stop

Thanks!

-- Steve

On Thu, 26 Jun 2014 12:52:39 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> [ Please test this on your arch ]
> 
> Cc: David S. Miller <davem@davemloft.net>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/sparc/Kconfig      |  1 -
>  arch/sparc/lib/mcount.S | 10 ++--------
>  2 files changed, 2 insertions(+), 9 deletions(-)
> 
> diff --git a/arch/sparc/Kconfig b/arch/sparc/Kconfig
> index 29f2e988c56a..abd7d5575a7d 100644
> --- a/arch/sparc/Kconfig
> +++ b/arch/sparc/Kconfig
> @@ -55,7 +55,6 @@ config SPARC64
>  	select HAVE_FUNCTION_TRACER
>  	select HAVE_FUNCTION_GRAPH_TRACER
>  	select HAVE_FUNCTION_GRAPH_FP_TEST
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>  	select HAVE_KRETPROBES
>  	select HAVE_KPROBES
>  	select HAVE_RCU_TABLE_FREE if SMP
> diff --git a/arch/sparc/lib/mcount.S b/arch/sparc/lib/mcount.S
> index 3ad6cbdc2163..0b0ed4d34219 100644
> --- a/arch/sparc/lib/mcount.S
> +++ b/arch/sparc/lib/mcount.S
> @@ -24,10 +24,7 @@ mcount:
>  #ifdef CONFIG_DYNAMIC_FTRACE
>  	/* Do nothing, the retl/nop below is all we need.  */
>  #else
> -	sethi		%hi(function_trace_stop), %g1
> -	lduw		[%g1 + %lo(function_trace_stop)], %g2
> -	brnz,pn		%g2, 2f
> -	 sethi		%hi(ftrace_trace_function), %g1
> +	sethi		%hi(ftrace_trace_function), %g1
>  	sethi		%hi(ftrace_stub), %g2
>  	ldx		[%g1 + %lo(ftrace_trace_function)], %g1
>  	or		%g2, %lo(ftrace_stub), %g2
> @@ -80,11 +77,8 @@ ftrace_stub:
>  	.globl		ftrace_caller
>  	.type		ftrace_caller,#function
>  ftrace_caller:
> -	sethi		%hi(function_trace_stop), %g1
>  	mov		%i7, %g2
> -	lduw		[%g1 + %lo(function_trace_stop)], %g1
> -	brnz,pn		%g1, ftrace_stub
> -	 mov		%fp, %g3
> +	mov		%fp, %g3
>  	save		%sp, -176, %sp
>  	mov		%g2, %o1
>  	mov		%g2, %l0


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

* Re: [RFA][PATCH 18/27] sparc64,ftrace: Remove check of obsolete variable function_trace_stop
  2014-07-03 16:41     ` Steven Rostedt
@ 2014-07-04  4:18       ` David Miller
  -1 siblings, 0 replies; 89+ messages in thread
From: David Miller @ 2014-07-04  4:18 UTC (permalink / raw)
  To: rostedt
  Cc: linux-kernel, mingo, akpm, tglx, masami.hiramatsu.pt, hpa,
	linux-arch, rjw, jkosina, notifications, sparclinux

From: Steven Rostedt <rostedt@goodmis.org>
Date: Thu, 3 Jul 2014 12:41:46 -0400

> Do you have any problem with this patch going through my tree? It
> compiles, but I do not have any hardware to test it. If you can verify
> that this patch works and ack it, it would be much appreciated.
> 
> This code is at:
> 
>  git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace.git
> 
> branch: rfc/remove-function-trace-stop

I can look at this next week at the earliest.  But frankly I have no problem
if you just merge it as-is now, we can sort out any fallout later.

Thanks.

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

* Re: [RFA][PATCH 18/27] sparc64,ftrace: Remove check of obsolete variable function_trace_stop
@ 2014-07-04  4:18       ` David Miller
  0 siblings, 0 replies; 89+ messages in thread
From: David Miller @ 2014-07-04  4:18 UTC (permalink / raw)
  To: rostedt
  Cc: linux-kernel, mingo, akpm, tglx, masami.hiramatsu.pt, hpa,
	linux-arch, rjw, jkosina, notifications, sparclinux

From: Steven Rostedt <rostedt@goodmis.org>
Date: Thu, 3 Jul 2014 12:41:46 -0400

> Do you have any problem with this patch going through my tree? It
> compiles, but I do not have any hardware to test it. If you can verify
> that this patch works and ack it, it would be much appreciated.
> 
> This code is at:
> 
>  git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace.git
> 
> branch: rfc/remove-function-trace-stop

I can look at this next week at the earliest.  But frankly I have no problem
if you just merge it as-is now, we can sort out any fallout later.

Thanks.

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

* Re: [RFA][PATCH 06/27] microblaze: ftrace: Add call to ftrace_graph_is_dead() in function graph code
  2014-06-26 16:52 ` [RFA][PATCH 06/27] microblaze: ftrace: " Steven Rostedt
  2014-07-03 16:34   ` Steven Rostedt
@ 2014-07-09 14:03   ` Steven Rostedt
  2014-07-18  8:19     ` Michal Simek
  1 sibling, 1 reply; 89+ messages in thread
From: Steven Rostedt @ 2014-07-09 14:03 UTC (permalink / raw)
  To: Michal Simek
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	Masami Hiramatsu, H. Peter Anvin, linux-arch, Rafael J. Wysocki,
	Jiri Kosina, Josh Poimboeuf

Michal,

Can you ack this please?

-- Steve


On Thu, 26 Jun 2014 12:52:27 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> ftrace_stop() is going away as it disables parts of function tracing
> that affects users that should not be affected. But ftrace_graph_stop()
> is built on ftrace_stop(). Here's another example of killing all of
> function tracing because something went wrong with function graph
> tracing.
> 
> Instead of disabling all users of function tracing on function graph
> error, disable only function graph tracing. To do this, the arch code
> must call ftrace_graph_is_dead() before it implements function graph.
> 
> Cc: Michal Simek <monstr@monstr.eu>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/microblaze/kernel/ftrace.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/arch/microblaze/kernel/ftrace.c b/arch/microblaze/kernel/ftrace.c
> index bbcd2533766c..fc7b48a52cd5 100644
> --- a/arch/microblaze/kernel/ftrace.c
> +++ b/arch/microblaze/kernel/ftrace.c
> @@ -27,6 +27,9 @@ void prepare_ftrace_return(unsigned long *parent, unsigned long self_addr)
>  	unsigned long return_hooker = (unsigned long)
>  				&return_to_handler;
>  
> +	if (unlikely(ftrace_graph_is_dead()))
> +		return;
> +
>  	if (unlikely(atomic_read(&current->tracing_graph_pause)))
>  		return;
>  


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

* Re: [RFA][PATCH 09/27] powerpc/ftrace: Add call to ftrace_graph_is_dead() in function graph code
  2014-06-26 16:52 ` [RFA][PATCH 09/27] powerpc/ftrace: " Steven Rostedt
@ 2014-07-09 14:04   ` Steven Rostedt
  0 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-07-09 14:04 UTC (permalink / raw)
  To: Benjamin Herrenschmidt
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	Masami Hiramatsu, H. Peter Anvin, linux-arch, Rafael J. Wysocki,
	Jiri Kosina, Josh Poimboeuf, Anton Blanchard

Ben,

Can you ack this please?

Thanks,

-- Steve


On Thu, 26 Jun 2014 12:52:30 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> ftrace_stop() is going away as it disables parts of function tracing
> that affects users that should not be affected. But ftrace_graph_stop()
> is built on ftrace_stop(). Here's another example of killing all of
> function tracing because something went wrong with function graph
> tracing.
> 
> Instead of disabling all users of function tracing on function graph
> error, disable only function graph tracing. To do this, the arch code
> must call ftrace_graph_is_dead() before it implements function graph.
> 
> Cc: Anton Blanchard <anton@samba.org>
> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/powerpc/kernel/ftrace.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/arch/powerpc/kernel/ftrace.c b/arch/powerpc/kernel/ftrace.c
> index f202d0731b06..f8c0ce5523a5 100644
> --- a/arch/powerpc/kernel/ftrace.c
> +++ b/arch/powerpc/kernel/ftrace.c
> @@ -527,6 +527,9 @@ void prepare_ftrace_return(unsigned long *parent, unsigned long self_addr)
>  	struct ftrace_graph_ent trace;
>  	unsigned long return_hooker = (unsigned long)&return_to_handler;
>  
> +	if (unlikely(ftrace_graph_is_dead()))
> +		return;
> +
>  	if (unlikely(atomic_read(&current->tracing_graph_pause)))
>  		return;
>  


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

* Re: [RFA][PATCH 21/27] MIPS: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` [RFA][PATCH 21/27] MIPS: " Steven Rostedt
  2014-06-26 17:37     ` Steven Rostedt
  2014-07-02 14:32   ` Steven Rostedt
@ 2014-07-09 14:15   ` Steven Rostedt
  2014-07-15 21:58   ` Steven Rostedt
  3 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-07-09 14:15 UTC (permalink / raw)
  To: Ralf Baechle
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	Masami Hiramatsu, H. Peter Anvin, linux-arch, Rafael J. Wysocki,
	Jiri Kosina, Josh Poimboeuf, linux-mips

Ralf,

Can you please ack this patch.

Thanks,

-- Steve


On Thu, 26 Jun 2014 12:52:42 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> [ Please test this on your arch ]
> 
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/mips/Kconfig         | 1 -
>  arch/mips/kernel/mcount.S | 7 -------
>  2 files changed, 8 deletions(-)
> 
> diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig
> index 7a469acee33c..9ca52987fcd5 100644
> --- a/arch/mips/Kconfig
> +++ b/arch/mips/Kconfig
> @@ -15,7 +15,6 @@ config MIPS
>  	select HAVE_BPF_JIT if !CPU_MICROMIPS
>  	select ARCH_HAVE_CUSTOM_GPIO_H
>  	select HAVE_FUNCTION_TRACER
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>  	select HAVE_DYNAMIC_FTRACE
>  	select HAVE_FTRACE_MCOUNT_RECORD
>  	select HAVE_C_RECORDMCOUNT
> diff --git a/arch/mips/kernel/mcount.S b/arch/mips/kernel/mcount.S
> index 539b6294b613..00940d1d5c4f 100644
> --- a/arch/mips/kernel/mcount.S
> +++ b/arch/mips/kernel/mcount.S
> @@ -74,10 +74,6 @@ _mcount:
>  #endif
>  
>  	/* When tracing is activated, it calls ftrace_caller+8 (aka here) */
> -	lw	t1, function_trace_stop
> -	bnez	t1, ftrace_stub
> -	 nop
> -
>  	MCOUNT_SAVE_REGS
>  #ifdef KBUILD_MCOUNT_RA_ADDRESS
>  	PTR_S	MCOUNT_RA_ADDRESS_REG, PT_R12(sp)
> @@ -105,9 +101,6 @@ ftrace_stub:
>  #else	/* ! CONFIG_DYNAMIC_FTRACE */
>  
>  NESTED(_mcount, PT_SIZE, ra)
> -	lw	t1, function_trace_stop
> -	bnez	t1, ftrace_stub
> -	 nop
>  	PTR_LA	t1, ftrace_stub
>  	PTR_L	t2, ftrace_trace_function /* Prepare t2 for (1) */
>  	bne	t1, t2, static_trace


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

* Re: [RFA][PATCH 22/27] microblaze: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` [RFA][PATCH 22/27] microblaze: " Steven Rostedt
  2014-06-26 17:38     ` Steven Rostedt
@ 2014-07-09 14:16   ` Steven Rostedt
  2014-07-15 21:51   ` Steven Rostedt
  2 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-07-09 14:16 UTC (permalink / raw)
  To: Michal Simek
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	Masami Hiramatsu, H. Peter Anvin, linux-arch, Rafael J. Wysocki,
	Jiri Kosina, Josh Poimboeuf

Michal,

Can you please ack this patch.

Thanks!

-- Steve


On Thu, 26 Jun 2014 12:52:43 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> [ Please test this on your arch ]
> 
> Cc: Michal Simek <monstr@monstr.eu>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/microblaze/Kconfig         | 1 -
>  arch/microblaze/kernel/mcount.S | 5 -----
>  2 files changed, 6 deletions(-)
> 
> diff --git a/arch/microblaze/Kconfig b/arch/microblaze/Kconfig
> index 9ae08541e30d..40e1c1dd0e24 100644
> --- a/arch/microblaze/Kconfig
> +++ b/arch/microblaze/Kconfig
> @@ -22,7 +22,6 @@ config MICROBLAZE
>  	select HAVE_DYNAMIC_FTRACE
>  	select HAVE_FTRACE_MCOUNT_RECORD
>  	select HAVE_FUNCTION_GRAPH_TRACER
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>  	select HAVE_FUNCTION_TRACER
>  	select HAVE_MEMBLOCK
>  	select HAVE_MEMBLOCK_NODE_MAP
> diff --git a/arch/microblaze/kernel/mcount.S b/arch/microblaze/kernel/mcount.S
> index fc1e1322ce4c..fed9da5de8c4 100644
> --- a/arch/microblaze/kernel/mcount.S
> +++ b/arch/microblaze/kernel/mcount.S
> @@ -91,11 +91,6 @@ ENTRY(ftrace_caller)
>  #endif /* CONFIG_DYNAMIC_FTRACE */
>  	SAVE_REGS
>  	swi	r15, r1, 0;
> -	/* MS: HAVE_FUNCTION_TRACE_MCOUNT_TEST begin of checking */
> -	lwi	r5, r0, function_trace_stop;
> -	bneid	r5, end;
> -	nop;
> -	/* MS: HAVE_FUNCTION_TRACE_MCOUNT_TEST end of checking */
>  #ifdef CONFIG_FUNCTION_GRAPH_TRACER
>  #ifndef CONFIG_DYNAMIC_FTRACE
>  	lwi	r5, r0, ftrace_graph_return;


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

* Re: [RFA][PATCH 07/27] MIPS: ftrace: Add call to ftrace_graph_is_dead() in function graph code
  2014-07-02 14:31   ` Steven Rostedt
@ 2014-07-09 15:48       ` James Hogan
  0 siblings, 0 replies; 89+ messages in thread
From: James Hogan @ 2014-07-09 15:48 UTC (permalink / raw)
  To: Steven Rostedt, linux-mips
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	Masami Hiramatsu, H. Peter Anvin, linux-arch, Rafael J. Wysocki,
	Jiri Kosina, Josh Poimboeuf, Ralf Baechle

Hi Steven,

I've given this a quick test on a mips32 le target, on your
rfc/remove-function-trace-stop branch (4161daee7df8). Booted fine,
startup tests fine, function and function_graph trace appear to work
from a quick cat of the trace file. Feel free to add my Tested-by:

Tested-by: James Hogan <james.hogan@imgtec.com> [MIPS]

Cheers
James

On 02/07/14 15:31, Steven Rostedt wrote:
> 
> Adding linux-mips@linux-mips.org.
> 
> -- Steve
> 
> 
> On Thu, 26 Jun 2014 12:52:28 -0400
> Steven Rostedt <rostedt@goodmis.org> wrote:
> 
>> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
>>
>> ftrace_stop() is going away as it disables parts of function tracing
>> that affects users that should not be affected. But ftrace_graph_stop()
>> is built on ftrace_stop(). Here's another example of killing all of
>> function tracing because something went wrong with function graph
>> tracing.
>>
>> Instead of disabling all users of function tracing on function graph
>> error, disable only function graph tracing. To do this, the arch code
>> must call ftrace_graph_is_dead() before it implements function graph.
>>
>> Cc: Ralf Baechle <ralf@linux-mips.org>
>> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
>> ---
>>  arch/mips/kernel/ftrace.c | 3 +++
>>  1 file changed, 3 insertions(+)
>>
>> diff --git a/arch/mips/kernel/ftrace.c b/arch/mips/kernel/ftrace.c
>> index 60e7e5e45af1..8b6538750fe1 100644
>> --- a/arch/mips/kernel/ftrace.c
>> +++ b/arch/mips/kernel/ftrace.c
>> @@ -302,6 +302,9 @@ void prepare_ftrace_return(unsigned long *parent_ra_addr, unsigned long self_ra,
>>  	    &return_to_handler;
>>  	int faulted, insns;
>>  
>> +	if (unlikely(ftrace_graph_is_dead()))
>> +		return;
>> +
>>  	if (unlikely(atomic_read(&current->tracing_graph_pause)))
>>  		return;
>>  
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-arch" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 

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

* Re: [RFA][PATCH 07/27] MIPS: ftrace: Add call to ftrace_graph_is_dead() in function graph code
@ 2014-07-09 15:48       ` James Hogan
  0 siblings, 0 replies; 89+ messages in thread
From: James Hogan @ 2014-07-09 15:48 UTC (permalink / raw)
  To: Steven Rostedt, linux-mips
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	Masami Hiramatsu, H. Peter Anvin, linux-arch, Rafael J. Wysocki,
	Jiri Kosina, Josh Poimboeuf, Ralf Baechle

Hi Steven,

I've given this a quick test on a mips32 le target, on your
rfc/remove-function-trace-stop branch (4161daee7df8). Booted fine,
startup tests fine, function and function_graph trace appear to work
from a quick cat of the trace file. Feel free to add my Tested-by:

Tested-by: James Hogan <james.hogan@imgtec.com> [MIPS]

Cheers
James

On 02/07/14 15:31, Steven Rostedt wrote:
> 
> Adding linux-mips@linux-mips.org.
> 
> -- Steve
> 
> 
> On Thu, 26 Jun 2014 12:52:28 -0400
> Steven Rostedt <rostedt@goodmis.org> wrote:
> 
>> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
>>
>> ftrace_stop() is going away as it disables parts of function tracing
>> that affects users that should not be affected. But ftrace_graph_stop()
>> is built on ftrace_stop(). Here's another example of killing all of
>> function tracing because something went wrong with function graph
>> tracing.
>>
>> Instead of disabling all users of function tracing on function graph
>> error, disable only function graph tracing. To do this, the arch code
>> must call ftrace_graph_is_dead() before it implements function graph.
>>
>> Cc: Ralf Baechle <ralf@linux-mips.org>
>> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
>> ---
>>  arch/mips/kernel/ftrace.c | 3 +++
>>  1 file changed, 3 insertions(+)
>>
>> diff --git a/arch/mips/kernel/ftrace.c b/arch/mips/kernel/ftrace.c
>> index 60e7e5e45af1..8b6538750fe1 100644
>> --- a/arch/mips/kernel/ftrace.c
>> +++ b/arch/mips/kernel/ftrace.c
>> @@ -302,6 +302,9 @@ void prepare_ftrace_return(unsigned long *parent_ra_addr, unsigned long self_ra,
>>  	    &return_to_handler;
>>  	int faulted, insns;
>>  
>> +	if (unlikely(ftrace_graph_is_dead()))
>> +		return;
>> +
>>  	if (unlikely(atomic_read(&current->tracing_graph_pause)))
>>  		return;
>>  
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-arch" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 

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

* Re: [RFA][PATCH 05/27] ftrace/x86: Add call to ftrace_graph_is_dead() in function graph code
  2014-06-26 16:52 ` [RFA][PATCH 05/27] ftrace/x86: Add call to ftrace_graph_is_dead() in function graph code Steven Rostedt
@ 2014-07-15 15:47   ` H. Peter Anvin
  0 siblings, 0 replies; 89+ messages in thread
From: H. Peter Anvin @ 2014-07-15 15:47 UTC (permalink / raw)
  To: Steven Rostedt, linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	linux-arch, Rafael J. Wysocki, Jiri Kosina, Josh Poimboeuf

On 06/26/2014 09:52 AM, Steven Rostedt wrote:
> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> ftrace_stop() is going away as it disables parts of function tracing
> that affects users that should not be affected. But ftrace_graph_stop()
> is built on ftrace_stop(). Here's another example of killing all of
> function tracing because something went wrong with function graph
> tracing.
> 
> Instead of disabling all users of function tracing on function graph
> error, disable only function graph tracing. To do this, the arch code
> must call ftrace_graph_is_dead() before it implements function graph.
> 
> Cc: H. Peter Anvin <hpa@zytor.com>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>

Acked-by: H. Peter Anvin <hpa@linux.intel.com>


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

* Re: [RFA][PATCH 16/27] ftrace: x86: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` [RFA][PATCH 16/27] ftrace: x86: Remove check of obsolete variable function_trace_stop Steven Rostedt
@ 2014-07-15 15:48   ` H. Peter Anvin
  0 siblings, 0 replies; 89+ messages in thread
From: H. Peter Anvin @ 2014-07-15 15:48 UTC (permalink / raw)
  To: Steven Rostedt, linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Thomas Gleixner, Masami Hiramatsu,
	linux-arch, Rafael J. Wysocki, Jiri Kosina, Josh Poimboeuf,
	H. Peter Anvin

On 06/26/2014 09:52 AM, Steven Rostedt wrote:
> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> Cc: H. Peter Anvin <hpa@linux.intel.com>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>

Acked-by: H. Peter Anvin <hpa@linux.intel.com>


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

* Re: [RFA][PATCH 22/27] microblaze: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` [RFA][PATCH 22/27] microblaze: " Steven Rostedt
  2014-06-26 17:38     ` Steven Rostedt
  2014-07-09 14:16   ` Steven Rostedt
@ 2014-07-15 21:51   ` Steven Rostedt
  2014-07-18  8:17     ` Michal Simek
  2 siblings, 1 reply; 89+ messages in thread
From: Steven Rostedt @ 2014-07-15 21:51 UTC (permalink / raw)
  To: Steven Rostedt
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	Masami Hiramatsu, H. Peter Anvin, linux-arch, Rafael J. Wysocki,
	Jiri Kosina, Josh Poimboeuf, Michal Simek

Michal,

Can you please test and ack this and patch 6 of this series. Otherwise I
may have to stip it out of the series which will break the build on
microblaze.

You can test my branch at:

  git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace.git
rfc/remove-function-trace-stop

-- Steve


On Thu, 26 Jun 2014 12:52:43 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> [ Please test this on your arch ]
> 
> Cc: Michal Simek <monstr@monstr.eu>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/microblaze/Kconfig         | 1 -
>  arch/microblaze/kernel/mcount.S | 5 -----
>  2 files changed, 6 deletions(-)
> 
> diff --git a/arch/microblaze/Kconfig b/arch/microblaze/Kconfig
> index 9ae08541e30d..40e1c1dd0e24 100644
> --- a/arch/microblaze/Kconfig
> +++ b/arch/microblaze/Kconfig
> @@ -22,7 +22,6 @@ config MICROBLAZE
>  	select HAVE_DYNAMIC_FTRACE
>  	select HAVE_FTRACE_MCOUNT_RECORD
>  	select HAVE_FUNCTION_GRAPH_TRACER
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>  	select HAVE_FUNCTION_TRACER
>  	select HAVE_MEMBLOCK
>  	select HAVE_MEMBLOCK_NODE_MAP
> diff --git a/arch/microblaze/kernel/mcount.S b/arch/microblaze/kernel/mcount.S
> index fc1e1322ce4c..fed9da5de8c4 100644
> --- a/arch/microblaze/kernel/mcount.S
> +++ b/arch/microblaze/kernel/mcount.S
> @@ -91,11 +91,6 @@ ENTRY(ftrace_caller)
>  #endif /* CONFIG_DYNAMIC_FTRACE */
>  	SAVE_REGS
>  	swi	r15, r1, 0;
> -	/* MS: HAVE_FUNCTION_TRACE_MCOUNT_TEST begin of checking */
> -	lwi	r5, r0, function_trace_stop;
> -	bneid	r5, end;
> -	nop;
> -	/* MS: HAVE_FUNCTION_TRACE_MCOUNT_TEST end of checking */
>  #ifdef CONFIG_FUNCTION_GRAPH_TRACER
>  #ifndef CONFIG_DYNAMIC_FTRACE
>  	lwi	r5, r0, ftrace_graph_return;


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

* Re: [RFA][PATCH 21/27] MIPS: ftrace: Remove check of obsolete variable function_trace_stop
  2014-06-26 16:52 ` [RFA][PATCH 21/27] MIPS: " Steven Rostedt
                     ` (2 preceding siblings ...)
  2014-07-09 14:15   ` Steven Rostedt
@ 2014-07-15 21:58   ` Steven Rostedt
  3 siblings, 0 replies; 89+ messages in thread
From: Steven Rostedt @ 2014-07-15 21:58 UTC (permalink / raw)
  To: Steven Rostedt
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	Masami Hiramatsu, H. Peter Anvin, linux-arch, Rafael J. Wysocki,
	Jiri Kosina, Josh Poimboeuf, ralf

Ralf,

Can you please test and ack this and patch 7. It would make it better
than just pushing it through.

Thanks!

-- Steve


On Thu, 26 Jun 2014 12:52:42 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
> 
> Nothing sets function_trace_stop to disable function tracing anymore.
> Remove the check for it in the arch code.
> 
> [ Please test this on your arch ]
> 
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> ---
>  arch/mips/Kconfig         | 1 -
>  arch/mips/kernel/mcount.S | 7 -------
>  2 files changed, 8 deletions(-)
> 
> diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig
> index 7a469acee33c..9ca52987fcd5 100644
> --- a/arch/mips/Kconfig
> +++ b/arch/mips/Kconfig
> @@ -15,7 +15,6 @@ config MIPS
>  	select HAVE_BPF_JIT if !CPU_MICROMIPS
>  	select ARCH_HAVE_CUSTOM_GPIO_H
>  	select HAVE_FUNCTION_TRACER
> -	select HAVE_FUNCTION_TRACE_MCOUNT_TEST
>  	select HAVE_DYNAMIC_FTRACE
>  	select HAVE_FTRACE_MCOUNT_RECORD
>  	select HAVE_C_RECORDMCOUNT
> diff --git a/arch/mips/kernel/mcount.S b/arch/mips/kernel/mcount.S
> index 539b6294b613..00940d1d5c4f 100644
> --- a/arch/mips/kernel/mcount.S
> +++ b/arch/mips/kernel/mcount.S
> @@ -74,10 +74,6 @@ _mcount:
>  #endif
>  
>  	/* When tracing is activated, it calls ftrace_caller+8 (aka here) */
> -	lw	t1, function_trace_stop
> -	bnez	t1, ftrace_stub
> -	 nop
> -
>  	MCOUNT_SAVE_REGS
>  #ifdef KBUILD_MCOUNT_RA_ADDRESS
>  	PTR_S	MCOUNT_RA_ADDRESS_REG, PT_R12(sp)
> @@ -105,9 +101,6 @@ ftrace_stub:
>  #else	/* ! CONFIG_DYNAMIC_FTRACE */
>  
>  NESTED(_mcount, PT_SIZE, ra)
> -	lw	t1, function_trace_stop
> -	bnez	t1, ftrace_stub
> -	 nop
>  	PTR_LA	t1, ftrace_stub
>  	PTR_L	t2, ftrace_trace_function /* Prepare t2 for (1) */
>  	bne	t1, t2, static_trace


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

* Re: [RFA][PATCH 22/27] microblaze: ftrace: Remove check of obsolete variable function_trace_stop
  2014-07-15 21:51   ` Steven Rostedt
@ 2014-07-18  8:17     ` Michal Simek
  0 siblings, 0 replies; 89+ messages in thread
From: Michal Simek @ 2014-07-18  8:17 UTC (permalink / raw)
  To: Steven Rostedt
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	Masami Hiramatsu, H. Peter Anvin, linux-arch, Rafael J. Wysocki,
	Jiri Kosina, Josh Poimboeuf

[-- Attachment #1: Type: text/plain, Size: 558 bytes --]

Hi Steve,

On 07/15/2014 11:51 PM, Steven Rostedt wrote:
> Michal,
> 
> Can you please test and ack this and patch 6 of this series. Otherwise I
> may have to stip it out of the series which will break the build on
> microblaze.
> 
> You can test my branch at:
> 
>   git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace.git
> rfc/remove-function-trace-stop

I have tested this full branch and there is no issue on Microblaze that's why
here is:
Tested-by: Michal Simek <monstr@monstr.eu>

Thanks,
Michal











[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 263 bytes --]

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

* Re: [RFA][PATCH 06/27] microblaze: ftrace: Add call to ftrace_graph_is_dead() in function graph code
  2014-07-09 14:03   ` Steven Rostedt
@ 2014-07-18  8:19     ` Michal Simek
  0 siblings, 0 replies; 89+ messages in thread
From: Michal Simek @ 2014-07-18  8:19 UTC (permalink / raw)
  To: Steven Rostedt
  Cc: linux-kernel, Ingo Molnar, Andrew Morton, Thomas Gleixner,
	Masami Hiramatsu, H. Peter Anvin, linux-arch, Rafael J. Wysocki,
	Jiri Kosina, Josh Poimboeuf

[-- Attachment #1: Type: text/plain, Size: 1960 bytes --]

Hi Steve,

On 07/09/2014 04:03 PM, Steven Rostedt wrote:
> Michal,
> 
> Can you ack this please?
> 
> -- Steve
> 
> 
> On Thu, 26 Jun 2014 12:52:27 -0400
> Steven Rostedt <rostedt@goodmis.org> wrote:
> 
>> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
>>
>> ftrace_stop() is going away as it disables parts of function tracing
>> that affects users that should not be affected. But ftrace_graph_stop()
>> is built on ftrace_stop(). Here's another example of killing all of
>> function tracing because something went wrong with function graph
>> tracing.
>>
>> Instead of disabling all users of function tracing on function graph
>> error, disable only function graph tracing. To do this, the arch code
>> must call ftrace_graph_is_dead() before it implements function graph.
>>
>> Cc: Michal Simek <monstr@monstr.eu>
>> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
>> ---
>>  arch/microblaze/kernel/ftrace.c | 3 +++
>>  1 file changed, 3 insertions(+)
>>
>> diff --git a/arch/microblaze/kernel/ftrace.c b/arch/microblaze/kernel/ftrace.c
>> index bbcd2533766c..fc7b48a52cd5 100644
>> --- a/arch/microblaze/kernel/ftrace.c
>> +++ b/arch/microblaze/kernel/ftrace.c
>> @@ -27,6 +27,9 @@ void prepare_ftrace_return(unsigned long *parent, unsigned long self_addr)
>>  	unsigned long return_hooker = (unsigned long)
>>  				&return_to_handler;
>>  
>> +	if (unlikely(ftrace_graph_is_dead()))
>> +		return;
>> +
>>  	if (unlikely(atomic_read(&current->tracing_graph_pause)))
>>  		return;
>>  
> 

sorry for delay. Here is mine.

Tested-by: Michal Simek <monstr@monstr.eu>

Thanks,
Michal

-- 
Michal Simek, Ing. (M.Eng), OpenPGP -> KeyID: FE3D1F91
w: www.monstr.eu p: +42-0-721842854
Maintainer of Linux kernel - Microblaze cpu - http://www.monstr.eu/fdt/
Maintainer of Linux kernel - Xilinx Zynq ARM architecture
Microblaze U-BOOT custodian and responsible for u-boot arm zynq platform



[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 263 bytes --]

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

end of thread, other threads:[~2014-07-18  8:19 UTC | newest]

Thread overview: 89+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-06-26 16:52 [RFA][PATCH 00/27] ftrace: Remove ftrace_start/stop() and friends Steven Rostedt
2014-06-26 16:52 ` Steven Rostedt
2014-06-26 16:52 ` [RFA][PATCH 01/27] x86, power, suspend: Annotate restore_processor_state() with notrace Steven Rostedt
2014-06-28  0:02   ` Rafael J. Wysocki
2014-06-26 16:52 ` [RFA][PATCH 02/27] PM / Sleep: Remove ftrace_stop/start() from suspend and hibernate Steven Rostedt
2014-06-28  0:02   ` Rafael J. Wysocki
2014-06-26 16:52 ` [RFA][PATCH 03/27] tracing: Remove ftrace_stop/start() from reading the trace file Steven Rostedt
2014-06-26 16:52 ` [RFA][PATCH 04/27] ftrace-graph: Remove dependency of ftrace_stop() from ftrace_graph_stop() Steven Rostedt
2014-06-26 16:52 ` [RFA][PATCH 05/27] ftrace/x86: Add call to ftrace_graph_is_dead() in function graph code Steven Rostedt
2014-07-15 15:47   ` H. Peter Anvin
2014-06-26 16:52 ` [RFA][PATCH 06/27] microblaze: ftrace: " Steven Rostedt
2014-07-03 16:34   ` Steven Rostedt
2014-07-09 14:03   ` Steven Rostedt
2014-07-18  8:19     ` Michal Simek
2014-06-26 16:52 ` [RFA][PATCH 07/27] MIPS: " Steven Rostedt
2014-07-02 14:31   ` Steven Rostedt
2014-07-09 15:48     ` James Hogan
2014-07-09 15:48       ` James Hogan
2014-07-03 16:36   ` Steven Rostedt
2014-06-26 16:52 ` [RFA][PATCH 08/27] parisc: " Steven Rostedt
2014-06-26 16:52 ` [RFA][PATCH 09/27] powerpc/ftrace: " Steven Rostedt
2014-07-09 14:04   ` Steven Rostedt
2014-06-26 16:52 ` [RFA][PATCH 10/27] sh: ftrace: " Steven Rostedt
2014-06-26 16:52 ` [RFA][PATCH 11/27] ftrace-graph: Remove usage of ftrace_stop() in ftrace_graph_stop() Steven Rostedt
2014-06-26 16:52 ` [RFA][PATCH 12/27] ftrace: Remove ftrace_start/stop() Steven Rostedt
2014-06-26 16:52 ` [RFA][PATCH 13/27] ftrace: Do no disable function tracing on enabling function tracing Steven Rostedt
2014-06-26 16:52 ` [RFA][PATCH 14/27] ftrace: Remove function_trace_stop check from list func Steven Rostedt
2014-06-26 16:52 ` [RFA][PATCH 15/27] ftrace: Remove check for HAVE_FUNCTION_TRACE_MCOUNT_TEST Steven Rostedt
2014-06-26 16:52 ` [RFA][PATCH 16/27] ftrace: x86: Remove check of obsolete variable function_trace_stop Steven Rostedt
2014-07-15 15:48   ` H. Peter Anvin
2014-06-26 16:52 ` [RFA][PATCH 17/27] tile: ftrace: " Steven Rostedt
2014-06-26 17:33   ` Steven Rostedt
2014-06-26 17:33     ` Steven Rostedt
2014-07-03 13:53   ` Chris Metcalf
2014-07-03 13:53     ` Chris Metcalf
2014-07-03 14:02     ` Steven Rostedt
2014-07-03 14:02       ` Steven Rostedt
2014-06-26 16:52 ` [RFA][PATCH 18/27] sparc64,ftrace: " Steven Rostedt
2014-06-26 17:34   ` Steven Rostedt
2014-06-26 17:34     ` Steven Rostedt
2014-07-03 16:41   ` Steven Rostedt
2014-07-03 16:41     ` Steven Rostedt
2014-07-04  4:18     ` David Miller
2014-07-04  4:18       ` David Miller
2014-06-26 16:52 ` [RFA][PATCH 19/27] sh: ftrace: " Steven Rostedt
2014-06-26 17:35   ` Steven Rostedt
2014-06-26 17:35     ` Steven Rostedt
2014-06-26 16:52 ` [RFA][PATCH 20/27] parisc: " Steven Rostedt
2014-06-26 17:35   ` Steven Rostedt
2014-06-26 17:35     ` Steven Rostedt
2014-06-29 21:20     ` Helge Deller
2014-06-30 14:11       ` Steven Rostedt
2014-06-26 16:52 ` [RFA][PATCH 21/27] MIPS: " Steven Rostedt
2014-06-26 17:37   ` Steven Rostedt
2014-06-26 17:37     ` Steven Rostedt
2014-07-02 14:32   ` Steven Rostedt
2014-07-09 14:15   ` Steven Rostedt
2014-07-15 21:58   ` Steven Rostedt
2014-06-26 16:52 ` [RFA][PATCH 22/27] microblaze: " Steven Rostedt
2014-06-26 17:38   ` Steven Rostedt
2014-06-26 17:38     ` Steven Rostedt
2014-07-09 14:16   ` Steven Rostedt
2014-07-15 21:51   ` Steven Rostedt
2014-07-18  8:17     ` Michal Simek
2014-06-26 16:52 ` [RFA][PATCH 23/27] metag: " Steven Rostedt
2014-06-26 17:38   ` Steven Rostedt
2014-06-26 17:38     ` Steven Rostedt
2014-07-02 13:34     ` James Hogan
2014-07-02 13:34       ` James Hogan
2014-07-02 14:22       ` Steven Rostedt
2014-07-02 14:22         ` Steven Rostedt
2014-06-26 16:52 ` [RFA][PATCH 24/27] Blackfin: " Steven Rostedt
2014-06-26 17:39   ` Steven Rostedt
2014-06-26 17:39     ` Steven Rostedt
2014-06-26 19:25   ` Mike Frysinger
2014-06-26 19:34     ` Steven Rostedt
2014-06-26 16:52 ` [RFA][PATCH 25/27] arm64, " Steven Rostedt
2014-06-26 17:40   ` Steven Rostedt
2014-06-26 17:40     ` Steven Rostedt
2014-06-27 12:44   ` Will Deacon
2014-07-01 11:33     ` AKASHI Takahiro
2014-06-26 16:52 ` [RFA][PATCH 26/27] s390/ftrace: remove " Steven Rostedt
2014-06-26 17:41   ` Steven Rostedt
2014-06-26 17:41     ` Steven Rostedt
2014-06-27  6:01     ` Heiko Carstens
2014-06-26 16:52 ` [RFA][PATCH 27/27] tracing: Remove function_trace_stop and HAVE_FUNCTION_TRACE_MCOUNT_TEST Steven Rostedt
2014-06-30  3:13 ` [RFA][PATCH 00/27] ftrace: Remove ftrace_start/stop() and friends Masami Hiramatsu
2014-06-30 14:16   ` Steven Rostedt
2014-07-01  0:58     ` Masami Hiramatsu

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.