]> git.ipfire.org Git - ipfire-2.x.git/blame - src/patches/suse-2.6.27.39/patches.trace/tracepoints-documentation-fix-teardown.patch
Imported linux-2.6.27.39 suse/xen patches.
[ipfire-2.x.git] / src / patches / suse-2.6.27.39 / patches.trace / tracepoints-documentation-fix-teardown.patch
CommitLineData
2cb7cef9
BS
1From: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
2Subject: Tracepoints : documentation fix teardown
3
4Need a tracepoint_synchronize_unregister() before the end of exit() to make sure
5every probe callers have exited the non preemptible section and thus are not
6executing the probe code anymore.
7
8Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
9CC: Rusty Russell <rusty@rustcorp.com.au>
10CC: "Frank Ch. Eigler" <fche@redhat.com>
11CC: Ingo Molnar <mingo@elte.hu>
12CC: Peter Zijlstra <peterz@infradead.org>
13CC: Steven Rostedt <rostedt@goodmis.org>
14Acked-by: Jan Blunck <jblunck@suse.de>
15---
16 Documentation/tracepoints.txt | 10 ++++++----
17 1 file changed, 6 insertions(+), 4 deletions(-)
18
19Index: linux-2.6-lttng/Documentation/tracepoints.txt
20===================================================================
21--- linux-2.6-lttng.orig/Documentation/tracepoints.txt 2008-07-31 09:22:56.000000000 -0400
22+++ linux-2.6-lttng/Documentation/tracepoints.txt 2008-07-31 09:24:54.000000000 -0400
23@@ -68,10 +68,12 @@ Where :
24 Connecting a function (probe) to a tracepoint is done by providing a probe
25 (function to call) for the specific tracepoint through
26 register_trace_subsys_eventname(). Removing a probe is done through
27-unregister_trace_subsys_eventname(); it will remove the probe sure there is no
28-caller left using the probe when it returns. Probe removal is preempt-safe
29-because preemption is disabled around the probe call. See the "Probe example"
30-section below for a sample probe module.
31+unregister_trace_subsys_eventname(); it will remove the probe.
32+marker_synchronize_unregister() must be called before the end of the module exit
33+function to make sure there is no caller left using the probe. This, and the
34+fact that preemption is disabled around the probe call, make sure that probe
35+removal and module unload are safe. See the "Probe example" section below for a
36+sample probe module.
37
38 The tracepoint mechanism supports inserting multiple instances of the same
39 tracepoint, but a single definition must be made of a given tracepoint name over