Skip to content

Commit

Permalink
ftrace: Implement separate user function filtering
Browse files Browse the repository at this point in the history
ftrace_ops that are registered to trace functions can now be
agnostic to each other in respect to what functions they trace.
Each ops has their own hash of the functions they want to trace
and a hash to what they do not want to trace. A empty hash for
the functions they want to trace denotes all functions should
be traced that are not in the notrace hash.

Cc: Paul E. McKenney <[email protected]>
Signed-off-by: Steven Rostedt <[email protected]>
  • Loading branch information
Steven Rostedt authored and rostedt committed May 18, 2011
1 parent 07fd551 commit b848914
Show file tree
Hide file tree
Showing 6 changed files with 166 additions and 39 deletions.
7 changes: 6 additions & 1 deletion include/linux/ftrace.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,18 @@ typedef void (*ftrace_func_t)(unsigned long ip, unsigned long parent_ip);

struct ftrace_hash;

enum {
FTRACE_OPS_FL_ENABLED = 1 << 0,
FTRACE_OPS_FL_GLOBAL = 1 << 1,
};

struct ftrace_ops {
ftrace_func_t func;
struct ftrace_ops *next;
unsigned long flags;
#ifdef CONFIG_DYNAMIC_FTRACE
struct ftrace_hash *notrace_hash;
struct ftrace_hash *filter_hash;
unsigned long flags;
#endif
};

Expand Down
Loading

0 comments on commit b848914

Please sign in to comment.