Skip to content

Commit

Permalink
Merge branch 'perf' of git://git.kernel.org/pub/scm/linux/kernel/git/…
Browse files Browse the repository at this point in the history
…acme/linux-2.6 into perf/core
  • Loading branch information
Ingo Molnar committed Apr 15, 2010
2 parents 84b13fd + f6c903f commit b5a80b7
Show file tree
Hide file tree
Showing 12 changed files with 1,634 additions and 777 deletions.
4 changes: 3 additions & 1 deletion Documentation/trace/kprobetrace.txt
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,9 @@ Synopsis of kprobe_events
$stack : Fetch stack address.
$retval : Fetch return value.(*)
+|-offs(FETCHARG) : Fetch memory at FETCHARG +|- offs address.(**)
NAME=FETCHARG: Set NAME as the argument name of FETCHARG.
NAME=FETCHARG : Set NAME as the argument name of FETCHARG.
FETCHARG:TYPE : Set TYPE as the type of FETCHARG. Currently, basic types
(u8/u16/u32/u64/s8/s16/s32/s64) are supported.

(*) only for return probe.
(**) this is useful for fetching a field of data structures.
Expand Down
16 changes: 2 additions & 14 deletions kernel/trace/trace.h
Original file line number Diff line number Diff line change
Expand Up @@ -102,29 +102,17 @@ struct syscall_trace_exit {
long ret;
};

struct kprobe_trace_entry {
struct kprobe_trace_entry_head {
struct trace_entry ent;
unsigned long ip;
int nargs;
unsigned long args[];
};

#define SIZEOF_KPROBE_TRACE_ENTRY(n) \
(offsetof(struct kprobe_trace_entry, args) + \
(sizeof(unsigned long) * (n)))

struct kretprobe_trace_entry {
struct kretprobe_trace_entry_head {
struct trace_entry ent;
unsigned long func;
unsigned long ret_ip;
int nargs;
unsigned long args[];
};

#define SIZEOF_KRETPROBE_TRACE_ENTRY(n) \
(offsetof(struct kretprobe_trace_entry, args) + \
(sizeof(unsigned long) * (n)))

/*
* trace_flag_type is an enumeration that holds different
* states when a trace occurs. These are:
Expand Down
Loading

0 comments on commit b5a80b7

Please sign in to comment.