Skip to content

Commit

Permalink
perf env: Remove env.h from other headers where just a fwd decl is ne…
Browse files Browse the repository at this point in the history
…eded

And fixup the fallout of c files not building due to now missing
headers.

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-sw8k3kpla98pr3rqypbjk9hf@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
  • Loading branch information
Arnaldo Carvalho de Melo committed Aug 31, 2019
1 parent 8520a98 commit b6b5574
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 3 deletions.
4 changes: 3 additions & 1 deletion tools/perf/arch/common.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@
#ifndef ARCH_PERF_COMMON_H
#define ARCH_PERF_COMMON_H

#include "../util/env.h"
#include <stdbool.h>

struct perf_env;

int perf_env__lookup_objdump(struct perf_env *env, const char **path);
bool perf_env__single_address_space(struct perf_env *env);
Expand Down
2 changes: 2 additions & 0 deletions tools/perf/tests/mem2node.c
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
// SPDX-License-Identifier: GPL-2.0
#include <linux/compiler.h>
#include <linux/bitmap.h>
#include <linux/kernel.h>
#include <linux/zalloc.h>
#include <perf/cpumap.h>
#include "cpumap.h"
#include "debug.h"
#include "env.h"
#include "mem2node.h"
#include "tests.h"

Expand Down
1 change: 0 additions & 1 deletion tools/perf/util/cputopo.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
#define __PERF_CPUTOPO_H

#include <linux/types.h>
#include "env.h"

struct cpu_topology {
u32 core_sib;
Expand Down
2 changes: 2 additions & 0 deletions tools/perf/util/mem2node.c
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
#include <errno.h>
#include <inttypes.h>
#include <linux/bitmap.h>
#include <linux/kernel.h>
#include <linux/zalloc.h>
#include "debug.h"
#include "env.h"
#include "mem2node.h"

struct phys_entry {
Expand Down
3 changes: 2 additions & 1 deletion tools/perf/util/mem2node.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,9 @@
#define __MEM2NODE_H

#include <linux/rbtree.h>
#include "env.h"
#include <linux/types.h>

struct perf_env;
struct phys_entry;

struct mem2node {
Expand Down

0 comments on commit b6b5574

Please sign in to comment.