diff options
author | Li Zefan <lizefan@huawei.com> | 2013-01-24 01:31:11 -0500 |
---|---|---|
committer | Tejun Heo <tj@kernel.org> | 2013-01-24 15:05:18 -0500 |
commit | 2a73991b76cbd38c4a0c6704449ccc08c89c3ff3 (patch) | |
tree | cde2e683c5d2139dcde24c8c2c90467fa3d5b91a /kernel/sched/debug.c | |
parent | ace783b9bbfa2182b4a561498db3f09a0c56bc79 (diff) |
sched: remove redundant NULL cgroup check in task_group_path()
A task_group won't be online (thus no one can see it) until
cpu_cgroup_css_online(), and at that time tg->css.cgroup has
been initialized, so this NULL check is redundant.
Signed-off-by: Li Zefan <lizefan@huawei.com>
Signed-off-by: Tejun Heo <tj@kernel.org>
Diffstat (limited to 'kernel/sched/debug.c')
-rw-r--r-- | kernel/sched/debug.c | 7 |
1 files changed, 0 insertions, 7 deletions
diff --git a/kernel/sched/debug.c b/kernel/sched/debug.c index 2cd3c1b4e582..38df0db96608 100644 --- a/kernel/sched/debug.c +++ b/kernel/sched/debug.c | |||
@@ -110,13 +110,6 @@ static char *task_group_path(struct task_group *tg) | |||
110 | if (autogroup_path(tg, group_path, PATH_MAX)) | 110 | if (autogroup_path(tg, group_path, PATH_MAX)) |
111 | return group_path; | 111 | return group_path; |
112 | 112 | ||
113 | /* | ||
114 | * May be NULL if the underlying cgroup isn't fully-created yet | ||
115 | */ | ||
116 | if (!tg->css.cgroup) { | ||
117 | group_path[0] = '\0'; | ||
118 | return group_path; | ||
119 | } | ||
120 | cgroup_path(tg->css.cgroup, group_path, PATH_MAX); | 113 | cgroup_path(tg->css.cgroup, group_path, PATH_MAX); |
121 | return group_path; | 114 | return group_path; |
122 | } | 115 | } |