Skip to content

Commit d2eee9f

Browse files
committed
Merge tag 'trace-v5.3-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace
Pull tracing fixes from Steven Rostedt: "Two minor fixes: - Fix trace event header include guards, as several did not match the #define to the #ifdef - Remove a redundant test to ftrace_graph_notrace_addr() that was accidentally added" * tag 'trace-v5.3-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace: fgraph: Remove redundant ftrace_graph_notrace_addr() test tracing: Fix header include guards in trace event headers
2 parents 52fde43 + 6c77221 commit d2eee9f

File tree

5 files changed

+14
-17
lines changed

5 files changed

+14
-17
lines changed

include/trace/events/dma_fence.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
#undef TRACE_SYSTEM
33
#define TRACE_SYSTEM dma_fence
44

5-
#if !defined(_TRACE_FENCE_H) || defined(TRACE_HEADER_MULTI_READ)
5+
#if !defined(_TRACE_DMA_FENCE_H) || defined(TRACE_HEADER_MULTI_READ)
66
#define _TRACE_DMA_FENCE_H
77

88
#include <linux/tracepoint.h>

include/trace/events/napi.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
#define TRACE_SYSTEM napi
44

55
#if !defined(_TRACE_NAPI_H) || defined(TRACE_HEADER_MULTI_READ)
6-
#define _TRACE_NAPI_H_
6+
#define _TRACE_NAPI_H
77

88
#include <linux/netdevice.h>
99
#include <linux/tracepoint.h>
@@ -38,7 +38,7 @@ TRACE_EVENT(napi_poll,
3838

3939
#undef NO_DEV
4040

41-
#endif /* _TRACE_NAPI_H_ */
41+
#endif /* _TRACE_NAPI_H */
4242

4343
/* This part must be outside protection */
4444
#include <trace/define_trace.h>

include/trace/events/qdisc.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
#define TRACE_SYSTEM qdisc
33

44
#if !defined(_TRACE_QDISC_H) || defined(TRACE_HEADER_MULTI_READ)
5-
#define _TRACE_QDISC_H_
5+
#define _TRACE_QDISC_H
66

77
#include <linux/skbuff.h>
88
#include <linux/netdevice.h>
@@ -44,7 +44,7 @@ TRACE_EVENT(qdisc_dequeue,
4444
__entry->txq_state, __entry->packets, __entry->skbaddr )
4545
);
4646

47-
#endif /* _TRACE_QDISC_H_ */
47+
#endif /* _TRACE_QDISC_H */
4848

4949
/* This part must be outside protection */
5050
#include <trace/define_trace.h>

include/trace/events/tegra_apb_dma.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#if !defined(_TRACE_TEGRA_APB_DMA_H) || defined(TRACE_HEADER_MULTI_READ)
2-
#define _TRACE_TEGRA_APM_DMA_H
2+
#define _TRACE_TEGRA_APB_DMA_H
33

44
#include <linux/tracepoint.h>
55
#include <linux/dmaengine.h>
@@ -55,7 +55,7 @@ TRACE_EVENT(tegra_dma_isr,
5555
TP_printk("%s: irq %d\n", __get_str(chan), __entry->irq)
5656
);
5757

58-
#endif /* _TRACE_TEGRADMA_H */
58+
#endif /* _TRACE_TEGRA_APB_DMA_H */
5959

6060
/* This part must be outside protection */
6161
#include <trace/define_trace.h>

kernel/trace/trace_functions_graph.c

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,13 @@ int trace_graph_entry(struct ftrace_graph_ent *trace)
137137
if (trace_recursion_test(TRACE_GRAPH_NOTRACE_BIT))
138138
return 0;
139139

140+
/*
141+
* Do not trace a function if it's filtered by set_graph_notrace.
142+
* Make the index of ret stack negative to indicate that it should
143+
* ignore further functions. But it needs its own ret stack entry
144+
* to recover the original index in order to continue tracing after
145+
* returning from the function.
146+
*/
140147
if (ftrace_graph_notrace_addr(trace->func)) {
141148
trace_recursion_set(TRACE_GRAPH_NOTRACE_BIT);
142149
/*
@@ -155,16 +162,6 @@ int trace_graph_entry(struct ftrace_graph_ent *trace)
155162
if (ftrace_graph_ignore_irqs())
156163
return 0;
157164

158-
/*
159-
* Do not trace a function if it's filtered by set_graph_notrace.
160-
* Make the index of ret stack negative to indicate that it should
161-
* ignore further functions. But it needs its own ret stack entry
162-
* to recover the original index in order to continue tracing after
163-
* returning from the function.
164-
*/
165-
if (ftrace_graph_notrace_addr(trace->func))
166-
return 1;
167-
168165
/*
169166
* Stop here if tracing_threshold is set. We only write function return
170167
* events to the ring buffer.

0 commit comments

Comments
 (0)