diff options
author | Alex Van Brunt <avanbrunt@nvidia.com> | 2014-05-07 09:15:18 -0700 |
---|---|---|
committer | Riham Haidar <rhaidar@nvidia.com> | 2014-05-14 15:28:32 -0700 |
commit | c8db10bb4d3b36d5b230e02bf05ce5605cbd689a (patch) | |
tree | d7d4f73092813ab9e3fca488aff53b3c7a0b600f /include/trace | |
parent | 6a3202ea03cba8b987a77ed4ec0010121c01dc03 (diff) |
arm64: mm: add a trace event for page faults
Create a trace event for the entry and exit of the page fault handler
so that it is possible to account for the time in the page fault
handler using frace logs.
Change-Id: Iff3af99812c5fd18386cca9f0e59cc8238d92be0
Signed-off-by: Alex Van Brunt <avanbrunt@nvidia.com>
Reviewed-on: http://git-master/r/407687
Reviewed-by: Riham Haidar <rhaidar@nvidia.com>
Tested-by: Riham Haidar <rhaidar@nvidia.com>
Diffstat (limited to 'include/trace')
-rw-r--r-- | include/trace/events/pagefault.h | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/include/trace/events/pagefault.h b/include/trace/events/pagefault.h new file mode 100644 index 000000000000..bc64f88bf7e3 --- /dev/null +++ b/include/trace/events/pagefault.h @@ -0,0 +1,47 @@ +#undef TRACE_SYSTEM +#define TRACE_SYSTEM pagefault + +#if !defined(_TRACE_IDLE_H) || defined(TRACE_HEADER_MULTI_READ) +#define _TRACE_IDLE_H + +#include <linux/tracepoint.h> + +TRACE_EVENT(pagefault_entry, + + TP_PROTO(u64 address), + + TP_ARGS(address), + + TP_STRUCT__entry( + __field( u64, address) + ), + + TP_fast_assign( + __entry->address = address; + ), + + TP_printk("addr=%llx", __entry->address) +); + +TRACE_EVENT(pagefault_exit, + + TP_PROTO(u64 address), + + TP_ARGS(address), + + TP_STRUCT__entry( + __field( u64, address) + ), + + TP_fast_assign( + __entry->address = address; + ), + + TP_printk("addr=%llx", __entry->address) +); + + +#endif /* _TRACE_IDLE_H */ + +/* This part must be outside protection */ +#include <trace/define_trace.h> |