diff options
author | Jiri Olsa <jolsa@kernel.org> | 2014-06-15 21:46:08 +0400 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2014-08-12 19:02:59 +0400 |
commit | fa4e5c67a2d169b9ef83f51b94e1d4a562ddfc0f (patch) | |
tree | 3ff9cddf909c599654782556a18dead7f0feffa7 /tools/perf/util/ordered-events.c | |
parent | 5f86b80b85f0dcd05fd1471eac6984181a707c4f (diff) | |
download | linux-fa4e5c67a2d169b9ef83f51b94e1d4a562ddfc0f.tar.xz |
perf tools: Use list_move in ordered_events_delete function
As Namhyung pointed out we can use list_move in ordered_events_delete.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Suggested-by: Namhyung Kim <namhyung@kernel.org>
Acked-by: David Ahern <dsahern@gmail.com>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Jean Pihet <jean.pihet@linaro.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Link: http://lkml.kernel.org/n/tip-m8ae5s5cuwyytitgb6iqilid@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 | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/tools/perf/util/ordered-events.c b/tools/perf/util/ordered-events.c index 95f8211ccdde..be6a48ce3eea 100644 --- a/tools/perf/util/ordered-events.c +++ b/tools/perf/util/ordered-events.c @@ -96,8 +96,7 @@ ordered_events__new(struct ordered_events *oe, u64 timestamp) void ordered_events__delete(struct ordered_events *oe, struct ordered_event *event) { - list_del(&event->list); - list_add(&event->list, &oe->cache); + list_move(&event->list, &oe->cache); oe->nr_events--; } |