diff options
author | Ingo Molnar <mingo@elte.hu> | 2011-06-04 12:28:05 +0200 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2011-06-04 12:28:05 +0200 |
commit | 3ce2a0bc9dfb6423491afe0afc9f099e24b8cba4 (patch) | |
tree | 58fbef582846fef0e777b1a552aca12e21a071b1 /kernel/events | |
parent | Merge branch 'perf/core' of ssh://k/pub/scm/linux/kernel/git/acme/linux into ... (diff) | |
parent | perf: Comment /proc/sys/kernel/perf_event_paranoid to be part of user ABI (diff) | |
download | linux-3ce2a0bc9dfb6423491afe0afc9f099e24b8cba4.tar.xz linux-3ce2a0bc9dfb6423491afe0afc9f099e24b8cba4.zip |
Merge branch 'perf/urgent' into perf/core
Conflicts:
tools/perf/util/python.c
Merge reason: resolve the conflict with perf/urgent.
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel/events')
-rw-r--r-- | kernel/events/core.c | 22 |
1 files changed, 4 insertions, 18 deletions
diff --git a/kernel/events/core.c b/kernel/events/core.c index cc5d57d1d0b6..ba89f40abe6a 100644 --- a/kernel/events/core.c +++ b/kernel/events/core.c @@ -7388,26 +7388,12 @@ static int __perf_cgroup_move(void *info) return 0; } -static void perf_cgroup_move(struct task_struct *task) +static void +perf_cgroup_attach_task(struct cgroup *cgrp, struct task_struct *task) { task_function_call(task, __perf_cgroup_move, task); } -static void perf_cgroup_attach(struct cgroup_subsys *ss, struct cgroup *cgrp, - struct cgroup *old_cgrp, struct task_struct *task, - bool threadgroup) -{ - perf_cgroup_move(task); - if (threadgroup) { - struct task_struct *c; - rcu_read_lock(); - list_for_each_entry_rcu(c, &task->thread_group, thread_group) { - perf_cgroup_move(c); - } - rcu_read_unlock(); - } -} - static void perf_cgroup_exit(struct cgroup_subsys *ss, struct cgroup *cgrp, struct cgroup *old_cgrp, struct task_struct *task) { @@ -7419,7 +7405,7 @@ static void perf_cgroup_exit(struct cgroup_subsys *ss, struct cgroup *cgrp, if (!(task->flags & PF_EXITING)) return; - perf_cgroup_move(task); + perf_cgroup_attach_task(cgrp, task); } struct cgroup_subsys perf_subsys = { @@ -7428,6 +7414,6 @@ struct cgroup_subsys perf_subsys = { .create = perf_cgroup_create, .destroy = perf_cgroup_destroy, .exit = perf_cgroup_exit, - .attach = perf_cgroup_attach, + .attach_task = perf_cgroup_attach_task, }; #endif /* CONFIG_CGROUP_PERF */ |