summaryrefslogtreecommitdiffstats
path: root/tools/perf/util/env.h
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@redhat.com>2019-09-30 11:50:15 -0300
committerArnaldo Carvalho de Melo <acme@redhat.com>2019-10-07 12:22:17 -0300
commitf1cedfb82858c8a7ec21e45d0ce7b6e2ce9edea0 (patch)
tree4755fd25c223485e743ee9d4150522616348f282 /tools/perf/util/env.h
parentf733c6b508bcaa3441ba1eacf16efb9abd47489f (diff)
downloadlinux-stable-f1cedfb82858c8a7ec21e45d0ce7b6e2ce9edea0.tar.gz
linux-stable-f1cedfb82858c8a7ec21e45d0ce7b6e2ce9edea0.tar.bz2
linux-stable-f1cedfb82858c8a7ec21e45d0ce7b6e2ce9edea0.zip
perf env: Add routine to read the env->cpuid from the running machine
In 'perf top' we use that cpuid when initializing the per arch annotation init routines (e.g. x86__annotate_init()) and in that case (live mode, 'perf top') we need to obtain it from the running machine, not from a perf.data file header. Provide a means to do that. Will be used by 'perf top' in a followup patch. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Link: https://lkml.kernel.org/n/tip-h2wb3sx7u7znx6lqfezrh7ca@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/util/env.h')
-rw-r--r--tools/perf/util/env.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/tools/perf/util/env.h b/tools/perf/util/env.h
index db40906e2937..a3059dc1abe5 100644
--- a/tools/perf/util/env.h
+++ b/tools/perf/util/env.h
@@ -104,6 +104,7 @@ void perf_env__exit(struct perf_env *env);
int perf_env__set_cmdline(struct perf_env *env, int argc, const char *argv[]);
+int perf_env__read_cpuid(struct perf_env *env);
int perf_env__read_cpu_topology_map(struct perf_env *env);
void cpu_cache_level__free(struct cpu_cache_level *cache);