mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-13 15:53:56 +08:00
tracing: Introduce TRACE_EVENT_FN_COND macro
TRACE_EVENT_FN can't be used in some circumstances like invoking trace functions from offlined CPU due to RCU usage. This patch adds the TRACE_EVENT_FN_COND macro to make such trace points conditional. Link: http://lkml.kernel.org/r/1450124286-4822-1-git-send-email-kda@linux-powerpc.org Signed-off-by: Denis Kirjanov <kda@linux-powerpc.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
This commit is contained in:
parent
ff078d8fc6
commit
2701121b8f
@ -493,6 +493,10 @@ extern void syscall_unregfunc(void);
|
||||
#define TRACE_EVENT_FN(name, proto, args, struct, \
|
||||
assign, print, reg, unreg) \
|
||||
DECLARE_TRACE(name, PARAMS(proto), PARAMS(args))
|
||||
#define TRACE_EVENT_FN_COND(name, proto, args, cond, struct, \
|
||||
assign, print, reg, unreg) \
|
||||
DECLARE_TRACE_CONDITION(name, PARAMS(proto), \
|
||||
PARAMS(args), PARAMS(cond))
|
||||
#define TRACE_EVENT_CONDITION(name, proto, args, cond, \
|
||||
struct, assign, print) \
|
||||
DECLARE_TRACE_CONDITION(name, PARAMS(proto), \
|
||||
|
@ -40,6 +40,11 @@
|
||||
assign, print, reg, unreg) \
|
||||
DEFINE_TRACE_FN(name, reg, unreg)
|
||||
|
||||
#undef TRACE_EVENT_FN_COND
|
||||
#define TRACE_EVENT_FN_COND(name, proto, args, cond, tstruct, \
|
||||
assign, print, reg, unreg) \
|
||||
DEFINE_TRACE_FN(name, reg, unreg)
|
||||
|
||||
#undef DEFINE_EVENT
|
||||
#define DEFINE_EVENT(template, name, proto, args) \
|
||||
DEFINE_TRACE(name)
|
||||
@ -93,6 +98,7 @@
|
||||
|
||||
#undef TRACE_EVENT
|
||||
#undef TRACE_EVENT_FN
|
||||
#undef TRACE_EVENT_FN_COND
|
||||
#undef TRACE_EVENT_CONDITION
|
||||
#undef DECLARE_EVENT_CLASS
|
||||
#undef DEFINE_EVENT
|
||||
|
@ -123,6 +123,12 @@ TRACE_MAKE_SYSTEM_STR();
|
||||
TRACE_EVENT(name, PARAMS(proto), PARAMS(args), \
|
||||
PARAMS(tstruct), PARAMS(assign), PARAMS(print)) \
|
||||
|
||||
#undef TRACE_EVENT_FN_COND
|
||||
#define TRACE_EVENT_FN_COND(name, proto, args, cond, tstruct, \
|
||||
assign, print, reg, unreg) \
|
||||
TRACE_EVENT_CONDITION(name, PARAMS(proto), PARAMS(args), PARAMS(cond), \
|
||||
PARAMS(tstruct), PARAMS(assign), PARAMS(print)) \
|
||||
|
||||
#undef TRACE_EVENT_FLAGS
|
||||
#define TRACE_EVENT_FLAGS(name, value) \
|
||||
__TRACE_EVENT_FLAGS(name, value)
|
||||
|
Loading…
Reference in New Issue
Block a user