From: Li Zefan <lizefan-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>
To: Tejun Heo <tj-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
Cc: Peter Zijlstra <peterz-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org>,
Ingo Molnar <mingo-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>,
LKML <linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
Cgroups <cgroups-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>
Subject: [PATCH 3/6] sched: remove redundant NULL cgroup check in task_group_path()
Date: Thu, 17 Jan 2013 16:03:47 +0800 [thread overview]
Message-ID: <50F7B063.6040004@huawei.com> (raw)
In-Reply-To: <50F7B040.2020906-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>
cpu_cgroup_css_online() is called after cgroup is fully created,
and it makes this check redundant.
Signed-off-by: Li Zefan <lizefan-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>
---
kernel/sched/debug.c | 7 -------
1 file changed, 7 deletions(-)
diff --git a/kernel/sched/debug.c b/kernel/sched/debug.c
index 2cd3c1b..38df0db 100644
--- a/kernel/sched/debug.c
+++ b/kernel/sched/debug.c
@@ -110,13 +110,6 @@ static char *task_group_path(struct task_group *tg)
if (autogroup_path(tg, group_path, PATH_MAX))
return group_path;
- /*
- * May be NULL if the underlying cgroup isn't fully-created yet
- */
- if (!tg->css.cgroup) {
- group_path[0] = '\0';
- return group_path;
- }
cgroup_path(tg->css.cgroup, group_path, PATH_MAX);
return group_path;
}
--
1.8.0.2
next prev parent reply other threads:[~2013-01-17 8:03 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-01-17 8:03 [PATCH 1/6] cgroup: initialize cgrp->dentry before css_alloc() Li Zefan
2013-01-17 8:03 ` [PATCH 2/6] sched: split out tg creation/destruction to css_online/css_offline Li Zefan
2013-01-17 8:04 ` [PATCH 4/6] cgroup: remove duplicate RCU free on struct cgroup Li Zefan
2013-01-17 8:04 ` [PATCH 5/6] cgroup: remove synchronize_rcu() from cgroup_diput() Li Zefan
[not found] ` <50F7B040.2020906-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>
2013-01-17 8:03 ` Li Zefan [this message]
2013-01-17 8:05 ` [PATCH 6/6] cgroup: remove bogus comments in cgroup_diput() Li Zefan
2013-01-23 0:27 ` [PATCH 1/6] cgroup: initialize cgrp->dentry before css_alloc() Tejun Heo
[not found] ` <20130123002754.GB5359-Gd/HAXX7CRxy/B6EtB590w@public.gmane.org>
2013-01-23 0:35 ` Andrew Morton
2013-01-23 2:34 ` Li Zefan
[not found] ` <50FF4C4D.4020405-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>
2013-01-23 16:35 ` Tejun Heo
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=50F7B063.6040004@huawei.com \
--to=lizefan-hv44wf8li93qt0dzr+alfa@public.gmane.org \
--cc=cgroups-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=mingo-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
--cc=peterz-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org \
--cc=tj-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).