aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@redhat.com>2017-08-17 15:58:21 -0400
committerArnaldo Carvalho de Melo <acme@redhat.com>2017-08-17 15:58:21 -0400
commit9a57eaf1d2443d34cce0562f425228c37a8ec019 (patch)
tree1a34d2c6e0d65ca5c7e62c32084ff0a22fa1597a
parent4717e03cc7e826818c3f9bd60e9c304a3309c3ad (diff)
perf tools: Use default CPUINFO_PROC where it fits
Several architectures don't need to define it since the string is the same as the default one, so nuke them. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-v1e1jr1u474w9xcelpaoxamu@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
-rw-r--r--tools/perf/perf-sys.h19
-rw-r--r--tools/perf/util/header.c3
2 files changed, 2 insertions, 20 deletions
diff --git a/tools/perf/perf-sys.h b/tools/perf/perf-sys.h
index 2aaa7366cdc2..c11f0c76e90c 100644
--- a/tools/perf/perf-sys.h
+++ b/tools/perf/perf-sys.h
@@ -9,14 +9,6 @@
9#include <linux/perf_event.h> 9#include <linux/perf_event.h>
10#include <asm/barrier.h> 10#include <asm/barrier.h>
11 11
12#if defined(__i386__)
13#define CPUINFO_PROC {"model name"}
14#endif
15
16#if defined(__x86_64__)
17#define CPUINFO_PROC {"model name"}
18#endif
19
20#ifdef __powerpc__ 12#ifdef __powerpc__
21#define CPUINFO_PROC {"cpu"} 13#define CPUINFO_PROC {"cpu"}
22#endif 14#endif
@@ -41,17 +33,10 @@
41#define CPUINFO_PROC {"cpu model"} 33#define CPUINFO_PROC {"cpu model"}
42#endif 34#endif
43 35
44#ifdef __ia64__
45#define CPUINFO_PROC {"model name"}
46#endif
47
48#ifdef __arm__ 36#ifdef __arm__
49#define CPUINFO_PROC {"model name", "Processor"} 37#define CPUINFO_PROC {"model name", "Processor"}
50#endif 38#endif
51 39
52#ifdef __aarch64__
53#endif
54
55#ifdef __mips__ 40#ifdef __mips__
56#define CPUINFO_PROC {"cpu model"} 41#define CPUINFO_PROC {"cpu model"}
57#endif 42#endif
@@ -68,8 +53,8 @@
68#define CPUINFO_PROC {"core ID"} 53#define CPUINFO_PROC {"core ID"}
69#endif 54#endif
70 55
71#ifdef __tile__ 56#ifndef CPUINFO_PROC
72#define CPUINFO_PROC {"model name"} 57#define CPUINFO_PROC { "model name", }
73#endif 58#endif
74 59
75static inline int 60static inline int
diff --git a/tools/perf/util/header.c b/tools/perf/util/header.c
index 28bf4442d577..605bbd5404fb 100644
--- a/tools/perf/util/header.c
+++ b/tools/perf/util/header.c
@@ -380,9 +380,6 @@ done:
380static int write_cpudesc(struct feat_fd *ff, 380static int write_cpudesc(struct feat_fd *ff,
381 struct perf_evlist *evlist __maybe_unused) 381 struct perf_evlist *evlist __maybe_unused)
382{ 382{
383#ifndef CPUINFO_PROC
384#define CPUINFO_PROC {"model name", }
385#endif
386 const char *cpuinfo_procs[] = CPUINFO_PROC; 383 const char *cpuinfo_procs[] = CPUINFO_PROC;
387 unsigned int i; 384 unsigned int i;
388 385