Commit-ID:  69e865c353b226dbedf319ae6d1ab8fb3510fa25
Gitweb:     http://git.kernel.org/tip/69e865c353b226dbedf319ae6d1ab8fb3510fa25
Author:     Namhyung Kim <[email protected]>
AuthorDate: Mon, 6 Oct 2014 09:46:02 +0900
Committer:  Arnaldo Carvalho de Melo <[email protected]>
CommitDate: Wed, 15 Oct 2014 17:39:01 -0300

perf kvm: Use thread_{,_set}_priv helpers

This is mechanical changes only for accounting access to thread->priv
properly in the source level.

Signed-off-by: Namhyung Kim <[email protected]>
Acked-by: Jiri Olsa <[email protected]>
Cc: David Ahern <[email protected]>
Cc: Frederic Weisbecker <[email protected]>
Cc: Ingo Molnar <[email protected]>
Cc: Jiri Olsa <[email protected]>
Cc: Namhyung Kim <[email protected]>
Cc: Paul Mackerras <[email protected]>
Cc: Peter Zijlstra <[email protected]>
Link: 
http://lkml.kernel.org/r/[email protected]
Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
---
 tools/perf/builtin-kvm.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/tools/perf/builtin-kvm.c b/tools/perf/builtin-kvm.c
index 460a4ce..ef9fc15 100644
--- a/tools/perf/builtin-kvm.c
+++ b/tools/perf/builtin-kvm.c
@@ -376,7 +376,7 @@ struct vcpu_event_record *per_vcpu_record(struct thread 
*thread,
                                          struct perf_sample *sample)
 {
        /* Only kvm_entry records vcpu id. */
-       if (!thread->priv && kvm_entry_event(evsel)) {
+       if (!thread__priv(thread) && kvm_entry_event(evsel)) {
                struct vcpu_event_record *vcpu_record;
 
                vcpu_record = zalloc(sizeof(*vcpu_record));
@@ -386,10 +386,10 @@ struct vcpu_event_record *per_vcpu_record(struct thread 
*thread,
                }
 
                vcpu_record->vcpu_id = perf_evsel__intval(evsel, sample, 
VCPU_ID);
-               thread->priv = vcpu_record;
+               thread__set_priv(thread, vcpu_record);
        }
 
-       return thread->priv;
+       return thread__priv(thread);
 }
 
 static bool handle_kvm_event(struct perf_kvm_stat *kvm,
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to