summaryrefslogtreecommitdiffstats
path: root/tools/lib/traceevent/event-parse.c
diff options
context:
space:
mode:
authorTzvetomir Stoyanov (VMware) <tz.stoyanov@gmail.com>2018-08-08 14:03:05 -0400
committerArnaldo Carvalho de Melo <acme@redhat.com>2018-08-13 15:31:28 -0300
commit610e1e4ff0431b3a86a0ebfcdb47828b8e082329 (patch)
tree07d6cc3e27d89fce8644b4409955be495a0888cb /tools/lib/traceevent/event-parse.c
parent8b3e08722ec8b288066eab66193736a65645c0a2 (diff)
downloadlinux-610e1e4ff0431b3a86a0ebfcdb47828b8e082329.tar.gz
linux-610e1e4ff0431b3a86a0ebfcdb47828b8e082329.tar.bz2
linux-610e1e4ff0431b3a86a0ebfcdb47828b8e082329.zip
tools lib traceevent: Rename pevent_find_* APIs
In order to make libtraceevent into a proper library, variables, data structures and functions require a unique prefix to prevent name space conflicts. That prefix will be "tep_" and not "pevent_". This changes APIs: pevent_find_function, pevent_find_function_address, pevent_find_event_by_name, pevent_find_event_by_record Signed-off-by: Tzvetomir Stoyanov (VMware) <tz.stoyanov@gmail.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Yordan Karadzhov (VMware) <y.karadz@gmail.com> Cc: linux-trace-devel@vger.kernel.org Link: http://lkml.kernel.org/r/20180808180702.966965051@goodmis.org Signed-off-by: Steven Rostedt <rostedt@goodmis.org> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/lib/traceevent/event-parse.c')
-rw-r--r--tools/lib/traceevent/event-parse.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/tools/lib/traceevent/event-parse.c b/tools/lib/traceevent/event-parse.c
index 652b8ef6f4c7..53d866434478 100644
--- a/tools/lib/traceevent/event-parse.c
+++ b/tools/lib/traceevent/event-parse.c
@@ -503,7 +503,7 @@ find_func(struct tep_handle *pevent, unsigned long long addr)
}
/**
- * pevent_find_function - find a function by a given address
+ * tep_find_function - find a function by a given address
* @pevent: handle for the pevent
* @addr: the address to find the function with
*
@@ -511,7 +511,7 @@ find_func(struct tep_handle *pevent, unsigned long long addr)
* address. Note, the address does not have to be exact, it
* will select the function that would contain the address.
*/
-const char *pevent_find_function(struct tep_handle *pevent, unsigned long long addr)
+const char *tep_find_function(struct tep_handle *pevent, unsigned long long addr)
{
struct func_map *map;
@@ -523,16 +523,16 @@ const char *pevent_find_function(struct tep_handle *pevent, unsigned long long a
}
/**
- * pevent_find_function_address - find a function address by a given address
+ * tep_find_function_address - find a function address by a given address
* @pevent: handle for the pevent
* @addr: the address to find the function with
*
* Returns the address the function starts at. This can be used in
- * conjunction with pevent_find_function to print both the function
+ * conjunction with tep_find_function to print both the function
* name and the function offset.
*/
unsigned long long
-pevent_find_function_address(struct tep_handle *pevent, unsigned long long addr)
+tep_find_function_address(struct tep_handle *pevent, unsigned long long addr)
{
struct func_map *map;
@@ -3498,7 +3498,7 @@ struct event_format *tep_find_event(struct tep_handle *pevent, int id)
}
/**
- * pevent_find_event_by_name - find an event by given name
+ * tep_find_event_by_name - find an event by given name
* @pevent: a handle to the pevent
* @sys: the system name to search for
* @name: the name of the event to search for
@@ -3507,8 +3507,8 @@ struct event_format *tep_find_event(struct tep_handle *pevent, int id)
* @sys. If @sys is NULL the first event with @name is returned.
*/
struct event_format *
-pevent_find_event_by_name(struct tep_handle *pevent,
- const char *sys, const char *name)
+tep_find_event_by_name(struct tep_handle *pevent,
+ const char *sys, const char *name)
{
struct event_format *event;
int i;
@@ -5433,7 +5433,7 @@ static bool is_timestamp_in_us(char *trace_clock, bool use_trace_clock)
}
/**
- * pevent_find_event_by_record - return the event from a given record
+ * tep_find_event_by_record - return the event from a given record
* @pevent: a handle to the pevent
* @record: The record to get the event from
*
@@ -5441,7 +5441,7 @@ static bool is_timestamp_in_us(char *trace_clock, bool use_trace_clock)
* is found.
*/
struct event_format *
-pevent_find_event_by_record(struct tep_handle *pevent, struct tep_record *record)
+tep_find_event_by_record(struct tep_handle *pevent, struct tep_record *record)
{
int type;
@@ -5564,7 +5564,7 @@ void tep_print_event(struct tep_handle *pevent, struct trace_seq *s,
{
struct event_format *event;
- event = pevent_find_event_by_record(pevent, record);
+ event = tep_find_event_by_record(pevent, record);
if (!event) {
int i;
int type = trace_parse_common_type(pevent, record->data);
@@ -6607,7 +6607,7 @@ static struct event_format *pevent_search_event(struct tep_handle *pevent, int i
if (sys_name && (strcmp(sys_name, event->system) != 0))
return NULL;
} else {
- event = pevent_find_event_by_name(pevent, sys_name, event_name);
+ event = tep_find_event_by_name(pevent, sys_name, event_name);
if (!event)
return NULL;
}