diff options
| author | Li Zefan <lizefan@huawei.com> | 2013-03-04 22:38:08 -0500 |
|---|---|---|
| committer | Ingo Molnar <mingo@kernel.org> | 2013-03-06 05:32:56 -0500 |
| commit | 877c685607925238e302cd3aa38788dca6c1b226 (patch) | |
| tree | 56159445dc66e409d5398a16c1ba01aad7e511e8 /kernel | |
| parent | 6dbe51c251a327e012439c4772097a13df43c5b8 (diff) | |
perf: Remove include of cgroup.h from perf_event.h
Move struct perf_cgroup_info and perf_cgroup to
kernel/perf/core.c, and then we can remove include of cgroup.h.
Signed-off-by: Li Zefan <lizefan@huawei.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
Cc: Tejun Heo <tj@kernel.org>
Link: http://lkml.kernel.org/r/513568A0.6020804@huawei.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'kernel')
| -rw-r--r-- | kernel/events/core.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/kernel/events/core.c b/kernel/events/core.c index b0cd86501c30..5976a2a6b4ce 100644 --- a/kernel/events/core.c +++ b/kernel/events/core.c | |||
| @@ -37,6 +37,7 @@ | |||
| 37 | #include <linux/ftrace_event.h> | 37 | #include <linux/ftrace_event.h> |
| 38 | #include <linux/hw_breakpoint.h> | 38 | #include <linux/hw_breakpoint.h> |
| 39 | #include <linux/mm_types.h> | 39 | #include <linux/mm_types.h> |
| 40 | #include <linux/cgroup.h> | ||
| 40 | 41 | ||
| 41 | #include "internal.h" | 42 | #include "internal.h" |
| 42 | 43 | ||
| @@ -234,6 +235,20 @@ static void perf_ctx_unlock(struct perf_cpu_context *cpuctx, | |||
| 234 | #ifdef CONFIG_CGROUP_PERF | 235 | #ifdef CONFIG_CGROUP_PERF |
| 235 | 236 | ||
| 236 | /* | 237 | /* |
| 238 | * perf_cgroup_info keeps track of time_enabled for a cgroup. | ||
| 239 | * This is a per-cpu dynamically allocated data structure. | ||
| 240 | */ | ||
| 241 | struct perf_cgroup_info { | ||
| 242 | u64 time; | ||
| 243 | u64 timestamp; | ||
| 244 | }; | ||
| 245 | |||
| 246 | struct perf_cgroup { | ||
| 247 | struct cgroup_subsys_state css; | ||
| 248 | struct perf_cgroup_info *info; | ||
| 249 | }; | ||
| 250 | |||
| 251 | /* | ||
| 237 | * Must ensure cgroup is pinned (css_get) before calling | 252 | * Must ensure cgroup is pinned (css_get) before calling |
| 238 | * this function. In other words, we cannot call this function | 253 | * this function. In other words, we cannot call this function |
| 239 | * if there is no cgroup event for the current CPU context. | 254 | * if there is no cgroup event for the current CPU context. |
