diff options
author | Namhyung Kim <namhyung.kim@lge.com> | 2013-06-04 01:20:18 -0400 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2013-07-12 12:52:11 -0400 |
commit | 79d5adf06dd530fe6a9ab3d086b2d23eb7560491 (patch) | |
tree | a0a28b2b31a842a1a059a15f19fe22a10f85dcf9 /tools/lib/traceevent/event-parse.c | |
parent | 4ccdf57d46843f5c03e390bdb652c9744e30ee20 (diff) |
tools lib traceevent: Add const qualifier to string arguments
If pevent_register_event_handler() received a string literal as
@sys_name or @event_name parameter, it emitted a warning about const
qualifier removal. Since they're not modified in the function we can
make it have const qualifier.
Signed-off-by: Namhyung Kim <namhyung@kernel.org>
Acked-by: Steven Rostedt <rostedt@goodmis.org>
Cc: David Ahern <dsahern@gmail.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Steven Rostedt <rostedt@goodmis.org>
Link: http://lkml.kernel.org/r/1370323231-14022-4-git-send-email-namhyung@kernel.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.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/tools/lib/traceevent/event-parse.c b/tools/lib/traceevent/event-parse.c index 82b0606dcb8a..d1c2a6a4cd32 100644 --- a/tools/lib/traceevent/event-parse.c +++ b/tools/lib/traceevent/event-parse.c | |||
@@ -5450,10 +5450,9 @@ int pevent_register_print_function(struct pevent *pevent, | |||
5450 | * If @id is >= 0, then it is used to find the event. | 5450 | * If @id is >= 0, then it is used to find the event. |
5451 | * else @sys_name and @event_name are used. | 5451 | * else @sys_name and @event_name are used. |
5452 | */ | 5452 | */ |
5453 | int pevent_register_event_handler(struct pevent *pevent, | 5453 | int pevent_register_event_handler(struct pevent *pevent, int id, |
5454 | int id, char *sys_name, char *event_name, | 5454 | const char *sys_name, const char *event_name, |
5455 | pevent_event_handler_func func, | 5455 | pevent_event_handler_func func, void *context) |
5456 | void *context) | ||
5457 | { | 5456 | { |
5458 | struct event_format *event; | 5457 | struct event_format *event; |
5459 | struct event_handler *handle; | 5458 | struct event_handler *handle; |