aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/builtin-script.c
diff options
context:
space:
mode:
Diffstat (limited to 'tools/perf/builtin-script.c')
-rw-r--r--tools/perf/builtin-script.c29
1 files changed, 15 insertions, 14 deletions
diff --git a/tools/perf/builtin-script.c b/tools/perf/builtin-script.c
index c350cfee3157..6d98a83d5a60 100644
--- a/tools/perf/builtin-script.c
+++ b/tools/perf/builtin-script.c
@@ -430,9 +430,9 @@ static void process_event(union perf_event *event, struct perf_sample *sample,
430 printf("\n"); 430 printf("\n");
431} 431}
432 432
433static int default_start_script(const char *script __unused, 433static int default_start_script(const char *script __maybe_unused,
434 int argc __unused, 434 int argc __maybe_unused,
435 const char **argv __unused) 435 const char **argv __maybe_unused)
436{ 436{
437 return 0; 437 return 0;
438} 438}
@@ -442,8 +442,8 @@ static int default_stop_script(void)
442 return 0; 442 return 0;
443} 443}
444 444
445static int default_generate_script(struct pevent *pevent __unused, 445static int default_generate_script(struct pevent *pevent __maybe_unused,
446 const char *outfile __unused) 446 const char *outfile __maybe_unused)
447{ 447{
448 return 0; 448 return 0;
449} 449}
@@ -474,7 +474,7 @@ static int cleanup_scripting(void)
474 474
475static const char *input_name; 475static const char *input_name;
476 476
477static int process_sample_event(struct perf_tool *tool __used, 477static int process_sample_event(struct perf_tool *tool __maybe_unused,
478 union perf_event *event, 478 union perf_event *event,
479 struct perf_sample *sample, 479 struct perf_sample *sample,
480 struct perf_evsel *evsel, 480 struct perf_evsel *evsel,
@@ -534,7 +534,7 @@ static struct perf_tool perf_script = {
534 534
535extern volatile int session_done; 535extern volatile int session_done;
536 536
537static void sig_handler(int sig __unused) 537static void sig_handler(int sig __maybe_unused)
538{ 538{
539 session_done = 1; 539 session_done = 1;
540} 540}
@@ -644,8 +644,8 @@ static void list_available_languages(void)
644 fprintf(stderr, "\n"); 644 fprintf(stderr, "\n");
645} 645}
646 646
647static int parse_scriptname(const struct option *opt __used, 647static int parse_scriptname(const struct option *opt __maybe_unused,
648 const char *str, int unset __used) 648 const char *str, int unset __maybe_unused)
649{ 649{
650 char spec[PATH_MAX]; 650 char spec[PATH_MAX];
651 const char *script, *ext; 651 const char *script, *ext;
@@ -690,8 +690,8 @@ static int parse_scriptname(const struct option *opt __used,
690 return 0; 690 return 0;
691} 691}
692 692
693static int parse_output_fields(const struct option *opt __used, 693static int parse_output_fields(const struct option *opt __maybe_unused,
694 const char *arg, int unset __used) 694 const char *arg, int unset __maybe_unused)
695{ 695{
696 char *tok; 696 char *tok;
697 int i, imax = sizeof(all_output_options) / sizeof(struct output_option); 697 int i, imax = sizeof(all_output_options) / sizeof(struct output_option);
@@ -982,8 +982,9 @@ static char *get_script_root(struct dirent *script_dirent, const char *suffix)
982 return script_root; 982 return script_root;
983} 983}
984 984
985static int list_available_scripts(const struct option *opt __used, 985static int list_available_scripts(const struct option *opt __maybe_unused,
986 const char *s __used, int unset __used) 986 const char *s __maybe_unused,
987 int unset __maybe_unused)
987{ 988{
988 struct dirent *script_next, *lang_next, script_dirent, lang_dirent; 989 struct dirent *script_next, *lang_next, script_dirent, lang_dirent;
989 char scripts_path[MAXPATHLEN]; 990 char scripts_path[MAXPATHLEN];
@@ -1172,7 +1173,7 @@ static int have_cmd(int argc, const char **argv)
1172 return 0; 1173 return 0;
1173} 1174}
1174 1175
1175int cmd_script(int argc, const char **argv, const char *prefix __used) 1176int cmd_script(int argc, const char **argv, const char *prefix __maybe_unused)
1176{ 1177{
1177 char *rec_script_path = NULL; 1178 char *rec_script_path = NULL;
1178 char *rep_script_path = NULL; 1179 char *rep_script_path = NULL;