perf trace: Do not show syscall tracepoint filter in the --no-syscalls case
authorArnaldo Carvalho de Melo <acme@redhat.com>
Mon, 3 Aug 2015 20:12:29 +0000 (17:12 -0300)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Wed, 5 Aug 2015 13:52:19 +0000 (10:52 -0300)
We were accessing trace->syscalls.events members even when that struct
wasn't initialized, i.e. --no-syscalls was specified on the command
line, fix it to show that, still in debug mode, when we have an event
qualifier list, i.e. when we actually are doing subset syscall tracing.

Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Borislav Petkov <bp@suse.de>
Cc: David Ahern <dsahern@gmail.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Milian Wolff <mail@milianw.de>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Stephane Eranian <eranian@google.com>
Fixes: 19867b6186f3 ("perf trace: Use event filters for the event qualifier list")
Link: http://lkml.kernel.org/n/tip-7980ym6vujgh3yiai0cqzc88@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/builtin-trace.c

index 06cfa93c0305f303be45e3fd9c648e218a95ce10..3cfca93309ee7fc229b77cd961f02609f390f3f6 100644 (file)
@@ -2394,9 +2394,10 @@ static int trace__run(struct trace *trace, int argc, const char **argv)
                err = trace__set_ev_qualifier_filter(trace);
                if (err < 0)
                        goto out_errno;
-       }
 
-       pr_debug("%s\n", trace->syscalls.events.sys_exit->filter);
+               pr_debug("event qualifier tracepoint filter: %s\n",
+                        trace->syscalls.events.sys_exit->filter);
+       }
 
        err = perf_evlist__apply_filters(evlist, &evsel);
        if (err < 0)