From 18a13a60f6f50f2fb1f7354f6d0b2ded01995443 Mon Sep 17 00:00:00 2001 From: Jiri Olsa Date: Wed, 28 Aug 2019 15:57:10 +0200 Subject: libperf: Add PERF_RECORD_STAT 'struct stat_event' to perf/event.h Move the PERF_RECORD_STAT event definition to libperf's event.h. In order to keep libperf simple, we switch 'u64/u32/u16/u8' types used events to their generic '__u*' versions. Signed-off-by: Jiri Olsa Cc: Alexander Shishkin Cc: Michael Petlan Cc: Namhyung Kim Cc: Peter Zijlstra Link: http://lkml.kernel.org/r/20190828135717.7245-17-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo --- tools/perf/util/stat.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'tools/perf/util/stat.c') diff --git a/tools/perf/util/stat.c b/tools/perf/util/stat.c index f985336b3a22..c0cd9f9bb0ea 100644 --- a/tools/perf/util/stat.c +++ b/tools/perf/util/stat.c @@ -405,9 +405,9 @@ size_t perf_event__fprintf_stat(union perf_event *event, FILE *fp) struct stat_event *st = (struct stat_event *) event; size_t ret; - ret = fprintf(fp, "\n... id %" PRIu64 ", cpu %d, thread %d\n", + ret = fprintf(fp, "\n... id %" PRI_lu64 ", cpu %d, thread %d\n", st->id, st->cpu, st->thread); - ret += fprintf(fp, "... value %" PRIu64 ", enabled %" PRIu64 ", running %" PRIu64 "\n", + ret += fprintf(fp, "... value %" PRI_lu64 ", enabled %" PRI_lu64 ", running %" PRI_lu64 "\n", st->val, st->ena, st->run); return ret; -- cgit v1.2.3-59-g8ed1b