Commit d0b2fdd2a51203f04ea0a5d716e033c15e0231af

Authored by Tao Ma
Committed by Tejun Heo
1 parent 0a950f65e1

cgroup: remove obsolete guarantee from cgroup_task_migrate.

'guarantee' is already removed from cgroup_task_migrate, so remove
the corresponding comments. Some other typos in cgroup are also
changed.

Cc: Tejun Heo <tj@kernel.org>
Cc: Li Zefan <lizefan@huawei.com>
Signed-off-by: Tao Ma <boyu.mt@taobao.com>
Signed-off-by: Tejun Heo <tj@kernel.org>

Showing 2 changed files with 5 additions and 7 deletions Side-by-side Diff

include/linux/cgroup.h
... ... @@ -66,7 +66,7 @@
66 66 /*
67 67 * State maintained by the cgroup system to allow subsystems
68 68 * to be "busy". Should be accessed via css_get(),
69   - * css_tryget() and and css_put().
  69 + * css_tryget() and css_put().
70 70 */
71 71  
72 72 atomic_t refcnt;
... ... @@ -276,7 +276,7 @@
276 276  
277 277 /* cftype->flags */
278 278 #define CFTYPE_ONLY_ON_ROOT (1U << 0) /* only create on root cg */
279   -#define CFTYPE_NOT_ON_ROOT (1U << 1) /* don't create onp root cg */
  279 +#define CFTYPE_NOT_ON_ROOT (1U << 1) /* don't create on root cg */
280 280  
281 281 #define MAX_CFTYPE_NAME 64
282 282  
... ... @@ -782,12 +782,12 @@
782 782 * The task_lock() exception
783 783 *
784 784 * The need for this exception arises from the action of
785   - * cgroup_attach_task(), which overwrites one tasks cgroup pointer with
  785 + * cgroup_attach_task(), which overwrites one task's cgroup pointer with
786 786 * another. It does so using cgroup_mutex, however there are
787 787 * several performance critical places that need to reference
788 788 * task->cgroup without the expense of grabbing a system global
789 789 * mutex. Therefore except as noted below, when dereferencing or, as
790   - * in cgroup_attach_task(), modifying a task'ss cgroup pointer we use
  790 + * in cgroup_attach_task(), modifying a task's cgroup pointer we use
791 791 * task_lock(), which acts on a spinlock (task->alloc_lock) already in
792 792 * the task_struct routinely used for such matters.
793 793 *
... ... @@ -1882,9 +1882,7 @@
1882 1882 /*
1883 1883 * cgroup_task_migrate - move a task from one cgroup to another.
1884 1884 *
1885   - * 'guarantee' is set if the caller promises that a new css_set for the task
1886   - * will already exist. If not set, this function might sleep, and can fail with
1887   - * -ENOMEM. Must be called with cgroup_mutex and threadgroup locked.
  1885 + * Must be called with cgroup_mutex and threadgroup locked.
1888 1886 */
1889 1887 static void cgroup_task_migrate(struct cgroup *cgrp, struct cgroup *oldcgrp,
1890 1888 struct task_struct *tsk, struct css_set *newcg)