diff options
author | Arnaldo Carvalho de Melo <acme@redhat.com> | 2015-02-22 13:52:47 -0800 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2015-02-23 11:39:38 -0300 |
commit | 280836812f5f821d26393268010f211160874810 (patch) | |
tree | 97b9123cb6fa346fbd8fb32e129a6b058fcc7a08 /tools/perf/util/ordered-events.c | |
parent | 9fa8727aa4d98d35ca50ef9cd8a50c6468af921d (diff) | |
download | op-kernel-dev-280836812f5f821d26393268010f211160874810.zip op-kernel-dev-280836812f5f821d26393268010f211160874810.tar.gz |
perf ordered_events: Stop using tool->ordered_events
To figure out if ordered_events are being used when doing a flush
operation, it is enough to check if there were in fact some events
queued, i.e. look at oe->nr_events.
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Borislav Petkov <bp@suse.de>
Cc: David Ahern <dsahern@gmail.com>
Cc: Don Zickus <dzickus@redhat.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
Link: http://lkml.kernel.org/n/tip-1c5r404vy766kt5nflv88uag@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/util/ordered-events.c')
-rw-r--r-- | tools/perf/util/ordered-events.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/tools/perf/util/ordered-events.c b/tools/perf/util/ordered-events.c index fd4be94..077ddd2 100644 --- a/tools/perf/util/ordered-events.c +++ b/tools/perf/util/ordered-events.c @@ -166,7 +166,7 @@ static int __ordered_events__flush(struct perf_session *s, struct ui_progress prog; int ret; - if (!tool->ordered_events || !limit) + if (!limit) return 0; if (show_progress) @@ -216,6 +216,9 @@ int ordered_events__flush(struct perf_session *s, struct perf_tool *tool, }; int err; + if (oe->nr_events == 0) + return 0; + switch (how) { case OE_FLUSH__FINAL: oe->next_flush = ULLONG_MAX; |