From: Tejun Heo <tj@kernel.org>
To: Li Zefan <lizf@cn.fujitsu.com>
Cc: LKML <linux-kernel@vger.kernel.org>, Cgroups <cgroups@vger.kernel.org>
Subject: Re: [RFC] splitting cgroup.c
Date: Wed, 18 Jan 2012 18:24:01 -0800 [thread overview]
Message-ID: <20120119022401.GH21533@google.com> (raw)
In-Reply-To: <4F177C67.6070907@cn.fujitsu.com>
Hello,
On Thu, Jan 19, 2012 at 10:13:59AM +0800, Li Zefan wrote:
> While working on cgroup xattr, it appeared to me it's better to
> create a cgroup_xattr.c instead of stuffing things into cgroup.c.
>
> Then I took a look at how big it is.
>
> $ ls -l -S kernel/*.c
> -rw-rw-r-- 1 lizf lizf 142717 Jan 18 10:15 cgroup.c
> -rw-rw-r-- 1 lizf lizf 106498 Jan 18 10:15 workqueue.c
> -rw-rw-r-- 1 lizf lizf 105206 Jan 18 10:15 lockdep.c
> -rw-rw-r-- 1 lizf lizf 91321 Jan 18 10:16 module.c
>
> $ wc -l kernel/*.c | sort -n -r
> 90397 total
> 5289 cgroup.c
> 4206 lockdep.c
> 3840 workqueue.c
> 3507 module.c
Yeah, cgroup.c one giant file.
> So I think for the sake of readability and maintainability, we'd
> better split cgroup.c into smaller pieces:
I agree that splitting is necessary but IMHO splitting usually tends
to go too far. Maybe we can split it into two and think about further
splitting later on? e.g. internal logic vs. userland interfacing.
Thanks.
--
tejun
next prev parent reply other threads:[~2012-01-19 2:24 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-01-19 2:13 [RFC] splitting cgroup.c Li Zefan
2012-01-19 2:24 ` Tejun Heo [this message]
2012-01-19 7:26 ` Li Zefan
2012-01-19 12:30 ` 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=20120119022401.GH21533@google.com \
--to=tj@kernel.org \
--cc=cgroups@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lizf@cn.fujitsu.com \
/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