alistair23-linux/tools
Stephane Eranian cc2d86b04d perf evlist: Fix missing event name init for default event
When no event is given to perf record, perf top, a default event is
initialized (cycles). However, perf_evlist__add_default() was not
setting the symbolic name for the event. Perf top worked simply because
it was reconstructing the name from the event code. But it should not
have to do this. This patch initializes the evsel->name field properly.

This second version improves the code flow on the non error path.

Cc: Ingo Molnar <mingo@elte.hu>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/r/20110607161936.GA8163@quad
Signed-off-by: Stephane Eranian <eranian@google.com>
[committer note: Use perf_evsel__delete() instead of plain free()]
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
2011-08-18 07:20:31 -03:00
..
firewire
perf perf evlist: Fix missing event name init for default event 2011-08-18 07:20:31 -03:00
power Merge branch 'tools-release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-idle-2.6 2011-08-02 21:17:39 -10:00
slub slub: slabinfo update for cmpxchg handling 2011-07-02 13:26:57 +03:00
testing/ktest ktest: Fix bug when ADD_CONFIG is set but MIN_CONFIG is not 2011-07-15 22:05:59 -04:00
usb USB: ffs-test: fix header path 2011-02-28 19:27:12 -08:00
virtio virtio_test: support event index 2011-05-30 11:14:15 +09:30