aboutsummaryrefslogtreecommitdiffstats
path: root/kernel
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2010-09-10 00:59:51 -0400
committerDavid S. Miller <davem@davemloft.net>2010-09-10 00:59:51 -0400
commit053d8f6622701f849fda2ca2c9ae596c13599ba9 (patch)
treee5dd90cca3a69bc993b5aa860a9eeb8c9178450a /kernel
parentc9cedbba0fc591e1c0587f838932ca3f3c6fec57 (diff)
parent615cc2211c17ed05a2a5d94abdac6c340a8ea508 (diff)
Merge branch 'vhost-net' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost
Diffstat (limited to 'kernel')
-rw-r--r--kernel/cgroup.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/kernel/cgroup.c b/kernel/cgroup.c
index 192f88c5b0f..ed19afd9e3f 100644
--- a/kernel/cgroup.c
+++ b/kernel/cgroup.c
@@ -1791,10 +1791,11 @@ out:
1791} 1791}
1792 1792
1793/** 1793/**
1794 * cgroup_attach_task_current_cg - attach task 'tsk' to current task's cgroup 1794 * cgroup_attach_task_all - attach task 'tsk' to all cgroups of task 'from'
1795 * @from: attach to all cgroups of a given task
1795 * @tsk: the task to be attached 1796 * @tsk: the task to be attached
1796 */ 1797 */
1797int cgroup_attach_task_current_cg(struct task_struct *tsk) 1798int cgroup_attach_task_all(struct task_struct *from, struct task_struct *tsk)
1798{ 1799{
1799 struct cgroupfs_root *root; 1800 struct cgroupfs_root *root;
1800 struct cgroup *cur_cg; 1801 struct cgroup *cur_cg;
@@ -1802,7 +1803,7 @@ int cgroup_attach_task_current_cg(struct task_struct *tsk)
1802 1803
1803 cgroup_lock(); 1804 cgroup_lock();
1804 for_each_active_root(root) { 1805 for_each_active_root(root) {
1805 cur_cg = task_cgroup_from_root(current, root); 1806 cur_cg = task_cgroup_from_root(from, root);
1806 retval = cgroup_attach_task(cur_cg, tsk); 1807 retval = cgroup_attach_task(cur_cg, tsk);
1807 if (retval) 1808 if (retval)
1808 break; 1809 break;
@@ -1811,7 +1812,7 @@ int cgroup_attach_task_current_cg(struct task_struct *tsk)
1811 1812
1812 return retval; 1813 return retval;
1813} 1814}
1814EXPORT_SYMBOL_GPL(cgroup_attach_task_current_cg); 1815EXPORT_SYMBOL_GPL(cgroup_attach_task_all);
1815 1816
1816/* 1817/*
1817 * Attach task with pid 'pid' to cgroup 'cgrp'. Call with cgroup_mutex 1818 * Attach task with pid 'pid' to cgroup 'cgrp'. Call with cgroup_mutex