Skip to content

Commit 69e865c

Browse files
namhyungacmel
authored andcommitted
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]>
1 parent 66f066d commit 69e865c

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

tools/perf/builtin-kvm.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -376,7 +376,7 @@ struct vcpu_event_record *per_vcpu_record(struct thread *thread,
376376
struct perf_sample *sample)
377377
{
378378
/* Only kvm_entry records vcpu id. */
379-
if (!thread->priv && kvm_entry_event(evsel)) {
379+
if (!thread__priv(thread) && kvm_entry_event(evsel)) {
380380
struct vcpu_event_record *vcpu_record;
381381

382382
vcpu_record = zalloc(sizeof(*vcpu_record));
@@ -386,10 +386,10 @@ struct vcpu_event_record *per_vcpu_record(struct thread *thread,
386386
}
387387

388388
vcpu_record->vcpu_id = perf_evsel__intval(evsel, sample, VCPU_ID);
389-
thread->priv = vcpu_record;
389+
thread__set_priv(thread, vcpu_record);
390390
}
391391

392-
return thread->priv;
392+
return thread__priv(thread);
393393
}
394394

395395
static bool handle_kvm_event(struct perf_kvm_stat *kvm,

0 commit comments

Comments
 (0)