From 1e7ed5ec54e3998bda6ea625599a0644404cb421 Mon Sep 17 00:00:00 2001 From: Adrian Hunter Date: Fri, 1 Nov 2013 15:51:35 +0200 Subject: perf evsel: Always use perf_evsel__set_sample_bit() Always use perf_evsel__set_sample_bit() rather than just setting the bit. Signed-off-by: Adrian Hunter Cc: David Ahern Cc: Frederic Weisbecker Cc: Ingo Molnar Cc: Jiri Olsa Cc: Mike Galbraith Cc: Namhyung Kim Cc: Paul Mackerras Cc: Peter Zijlstra Cc: Stephane Eranian Link: http://lkml.kernel.org/r/1383313899-15987-8-git-send-email-adrian.hunter@intel.com [ Cope with 3090ffb "perf: Disable PERF_RECORD_MMAP2 support" ] Signed-off-by: Arnaldo Carvalho de Melo diff --git a/tools/perf/util/evsel.c b/tools/perf/util/evsel.c index f0e65de..47bbf03 100644 --- a/tools/perf/util/evsel.c +++ b/tools/perf/util/evsel.c @@ -663,7 +663,7 @@ void perf_evsel__config(struct perf_evsel *evsel, } if (opts->sample_address) - attr->sample_type |= PERF_SAMPLE_DATA_SRC; + perf_evsel__set_sample_bit(evsel, DATA_SRC); if (opts->no_delay) { attr->watermark = 0; @@ -675,13 +675,13 @@ void perf_evsel__config(struct perf_evsel *evsel, } if (opts->sample_weight) - attr->sample_type |= PERF_SAMPLE_WEIGHT; + perf_evsel__set_sample_bit(evsel, WEIGHT); attr->mmap = track; attr->comm = track; if (opts->sample_transaction) - attr->sample_type |= PERF_SAMPLE_TRANSACTION; + perf_evsel__set_sample_bit(evsel, TRANSACTION); /* * XXX see the function comment above -- cgit v0.10.2