From: Jiri Olsa Date: Fri, 16 Oct 2015 10:41:14 +0000 (+0200) Subject: perf cpu_map: Make cpu_map__build_map global X-Git-Tag: v4.4-rc1~155^2~11^2~3 X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=commitdiff_plain;h=f1cbb8f35719e36803f226d1bbf08ac12cedcd76;p=linux.git perf cpu_map: Make cpu_map__build_map global We'll need to call it from perf stat in the stat_script patchkit Signed-off-by: Jiri Olsa Tested-by: Kan Liang Cc: David Ahern Cc: Namhyung Kim Cc: Peter Zijlstra Link: http://lkml.kernel.org/r/1444992092-17897-40-git-send-email-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo --- diff --git a/tools/perf/util/cpumap.c b/tools/perf/util/cpumap.c index c51c29fd0732..70ec8d031f9d 100644 --- a/tools/perf/util/cpumap.c +++ b/tools/perf/util/cpumap.c @@ -258,8 +258,8 @@ static int cmp_ids(const void *a, const void *b) return *(int *)a - *(int *)b; } -static int cpu_map__build_map(struct cpu_map *cpus, struct cpu_map **res, - int (*f)(struct cpu_map *map, int cpu)) +int cpu_map__build_map(struct cpu_map *cpus, struct cpu_map **res, + int (*f)(struct cpu_map *map, int cpu)) { struct cpu_map *c; int nr = cpus->nr; diff --git a/tools/perf/util/cpumap.h b/tools/perf/util/cpumap.h index 8982d538da83..6e36fc35eca6 100644 --- a/tools/perf/util/cpumap.h +++ b/tools/perf/util/cpumap.h @@ -87,4 +87,6 @@ static inline int cpu__get_node(int cpu) return cpunode_map[cpu]; } +int cpu_map__build_map(struct cpu_map *cpus, struct cpu_map **res, + int (*f)(struct cpu_map *map, int cpu)); #endif /* __PERF_CPUMAP_H */