Skip to content

Commit

Permalink
perf tools: Use default CPUINFO_PROC where it fits
Browse files Browse the repository at this point in the history
Several architectures don't need to define it since the string is the
same as the default one, so nuke them.

Cc: Adrian Hunter <[email protected]>
Cc: David Ahern <[email protected]>
Cc: Jiri Olsa <[email protected]>
Cc: Namhyung Kim <[email protected]>
Cc: Wang Nan <[email protected]>
Link: http://lkml.kernel.org/n/[email protected]
Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
  • Loading branch information
acmel committed Aug 17, 2017
1 parent 4717e03 commit 9a57eaf
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 20 deletions.
19 changes: 2 additions & 17 deletions tools/perf/perf-sys.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,6 @@
#include <linux/perf_event.h>
#include <asm/barrier.h>

#if defined(__i386__)
#define CPUINFO_PROC {"model name"}
#endif

#if defined(__x86_64__)
#define CPUINFO_PROC {"model name"}
#endif

#ifdef __powerpc__
#define CPUINFO_PROC {"cpu"}
#endif
Expand All @@ -41,17 +33,10 @@
#define CPUINFO_PROC {"cpu model"}
#endif

#ifdef __ia64__
#define CPUINFO_PROC {"model name"}
#endif

#ifdef __arm__
#define CPUINFO_PROC {"model name", "Processor"}
#endif

#ifdef __aarch64__
#endif

#ifdef __mips__
#define CPUINFO_PROC {"cpu model"}
#endif
Expand All @@ -68,8 +53,8 @@
#define CPUINFO_PROC {"core ID"}
#endif

#ifdef __tile__
#define CPUINFO_PROC {"model name"}
#ifndef CPUINFO_PROC
#define CPUINFO_PROC { "model name", }
#endif

static inline int
Expand Down
3 changes: 0 additions & 3 deletions tools/perf/util/header.c
Original file line number Diff line number Diff line change
Expand Up @@ -380,9 +380,6 @@ static int __write_cpudesc(struct feat_fd *ff, const char *cpuinfo_proc)
static int write_cpudesc(struct feat_fd *ff,
struct perf_evlist *evlist __maybe_unused)
{
#ifndef CPUINFO_PROC
#define CPUINFO_PROC {"model name", }
#endif
const char *cpuinfo_procs[] = CPUINFO_PROC;
unsigned int i;

Expand Down

0 comments on commit 9a57eaf

Please sign in to comment.