Loading Documentation/trace/kprobetrace.txt +3 −1 Original line number Original line Diff line number Diff line Loading @@ -41,6 +41,8 @@ Synopsis of kprobe_events $retval : Fetch return value.(*) $retval : Fetch return value.(*) +|-offs(FETCHARG) : Fetch memory at FETCHARG +|- offs address.(**) +|-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. (*) only for return probe. (**) this is useful for fetching a field of data structures. (**) this is useful for fetching a field of data structures. Loading kernel/trace/trace.h +2 −14 Original line number Original line Diff line number Diff line Loading @@ -102,29 +102,17 @@ struct syscall_trace_exit { long ret; long ret; }; }; struct kprobe_trace_entry { struct kprobe_trace_entry_head { struct trace_entry ent; struct trace_entry ent; unsigned long ip; unsigned long ip; int nargs; unsigned long args[]; }; }; #define SIZEOF_KPROBE_TRACE_ENTRY(n) \ struct kretprobe_trace_entry_head { (offsetof(struct kprobe_trace_entry, args) + \ (sizeof(unsigned long) * (n))) struct kretprobe_trace_entry { struct trace_entry ent; struct trace_entry ent; unsigned long func; unsigned long func; unsigned long ret_ip; 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 * trace_flag_type is an enumeration that holds different * states when a trace occurs. These are: * states when a trace occurs. These are: Loading Loading
Documentation/trace/kprobetrace.txt +3 −1 Original line number Original line Diff line number Diff line Loading @@ -41,6 +41,8 @@ Synopsis of kprobe_events $retval : Fetch return value.(*) $retval : Fetch return value.(*) +|-offs(FETCHARG) : Fetch memory at FETCHARG +|- offs address.(**) +|-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. (*) only for return probe. (**) this is useful for fetching a field of data structures. (**) this is useful for fetching a field of data structures. Loading
kernel/trace/trace.h +2 −14 Original line number Original line Diff line number Diff line Loading @@ -102,29 +102,17 @@ struct syscall_trace_exit { long ret; long ret; }; }; struct kprobe_trace_entry { struct kprobe_trace_entry_head { struct trace_entry ent; struct trace_entry ent; unsigned long ip; unsigned long ip; int nargs; unsigned long args[]; }; }; #define SIZEOF_KPROBE_TRACE_ENTRY(n) \ struct kretprobe_trace_entry_head { (offsetof(struct kprobe_trace_entry, args) + \ (sizeof(unsigned long) * (n))) struct kretprobe_trace_entry { struct trace_entry ent; struct trace_entry ent; unsigned long func; unsigned long func; unsigned long ret_ip; 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 * trace_flag_type is an enumeration that holds different * states when a trace occurs. These are: * states when a trace occurs. These are: Loading