Building the trace clock without CONFIG_TRACING enabled is useful for the ring
buffer library sample client.

Signed-off-by: Mathieu Desnoyers <[email protected]>
---
 kernel/Makefile            |    1 +
 kernel/trace/Kconfig       |    3 +++
 kernel/trace/trace_clock.c |    3 +++
 3 files changed, 7 insertions(+)

Index: linux.trees.git/kernel/trace/trace_clock.c
===================================================================
--- linux.trees.git.orig/kernel/trace/trace_clock.c     2010-08-17 
16:32:53.000000000 -0400
+++ linux.trees.git/kernel/trace/trace_clock.c  2010-08-17 16:33:20.000000000 
-0400
@@ -44,6 +44,7 @@ u64 notrace trace_clock_local(void)
 
        return clock;
 }
+EXPORT_SYMBOL_GPL(trace_clock_local);
 
 /*
  * trace_clock(): 'inbetween' trace clock. Not completely serialized,
@@ -57,6 +58,7 @@ u64 notrace trace_clock(void)
 {
        return local_clock();
 }
+EXPORT_SYMBOL_GPL(trace_clock);
 
 
 /*
@@ -113,3 +115,4 @@ u64 notrace trace_clock_global(void)
 
        return now;
 }
+EXPORT_SYMBOL_GPL(trace_clock_global);
Index: linux.trees.git/kernel/trace/Kconfig
===================================================================
--- linux.trees.git.orig/kernel/trace/Kconfig   2010-08-17 16:32:53.000000000 
-0400
+++ linux.trees.git/kernel/trace/Kconfig        2010-08-17 16:33:20.000000000 
-0400
@@ -73,6 +73,9 @@ config RING_BUFFER_ALLOW_SWAP
         Allow the use of ring_buffer_swap_cpu.
         Adds a very slight overhead to tracing when enabled.
 
+config TRACE_CLOCK_STANDALONE
+       bool
+
 # All tracer options should select GENERIC_TRACER. For those options that are
 # enabled by all tracers (context switch and event tracer) they select TRACING.
 # This allows those options to appear when no other tracer is selected. But the
Index: linux.trees.git/kernel/Makefile
===================================================================
--- linux.trees.git.orig/kernel/Makefile        2010-08-17 16:32:53.000000000 
-0400
+++ linux.trees.git/kernel/Makefile     2010-08-17 16:33:20.000000000 -0400
@@ -99,6 +99,7 @@ obj-$(CONFIG_FUNCTION_TRACER) += trace/
 obj-$(CONFIG_TRACING) += trace/
 obj-$(CONFIG_X86_DS) += trace/
 obj-$(CONFIG_RING_BUFFER) += trace/
+obj-$(CONFIG_TRACE_CLOCK_STANDALONE) += trace/
 obj-$(CONFIG_SMP) += sched_cpupri.o
 obj-$(CONFIG_PERF_EVENTS) += perf_event.o
 obj-$(CONFIG_HAVE_HW_BREAKPOINT) += hw_breakpoint.o


_______________________________________________
ltt-dev mailing list
[email protected]
http://lists.casi.polymtl.ca/cgi-bin/mailman/listinfo/ltt-dev

Reply via email to