Hottest Free Downloads - DownloadPipe.com Over 197,000 downloads! Bookmark Now!
DownloadPipe.com - New Downloads Every Minute
 SEARCH:
FAQFAQ    SearchSearch      ProfileProfile    Private MessagesPrivate Messages   Log inLog in

[PATCH] cgroup: Fix indent for /proc/cgroups

 
   Linux (Home) -> Kernel RSS
Next:  [GIT]: parisc for 2.6.31  
Author Message
Gui Jianfeng

External


Since: Jul 03, 2009
Posts: 11



(Msg. 1) Posted: Fri Jul 03, 2009 10:10 am
Post subject: [PATCH] cgroup: Fix indent for /proc/cgroups
Archived from groups: linux>kernel (more info?)

Currently, /proc/cgroups outputs is fairly ugly as following,
#subsys_name hierarchy num_cgroups enabled
cpuset 0 1 1
debug 0 1 1
ns 0 1 1

indent it in a good-looking way.
#subsys_name hierarchy num_cgroups enabled
cpuset 0 1 1
debug 0 1 1
ns 0 1 1


Signed-off-by: Gui Jianfeng <guijianfeng DeleteThis @cn.fujitsu.com>
---
kernel/cgroup.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/kernel/cgroup.c b/kernel/cgroup.c
index 3737a68..99fc160 100644
--- a/kernel/cgroup.c
+++ b/kernel/cgroup.c
@@ -2963,7 +2963,7 @@ static int proc_cgroupstats_show(struct seq_file *m, void *v)
mutex_lock(&cgroup_mutex);
for (i = 0; i < CGROUP_SUBSYS_COUNT; i++) {
struct cgroup_subsys *ss = subsys[i];
- seq_printf(m, "%s\t%lu\t%d\t%d\n",
+ seq_printf(m, "%s\t\t%lu\t\t%d\t\t%d\n",
ss->name, ss->root->subsys_bits,
ss->root->number_of_cgroups, !ss->disabled);
}
--
1.5.4.rc3

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo DeleteThis @vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Back to top
Login to vote
Li Zefan

External


Since: Jul 03, 2009
Posts: 18



(Msg. 2) Posted: Fri Jul 03, 2009 10:20 am
Post subject: Re: [PATCH] cgroup: Fix indent for /proc/cgroups [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

CC: container list

Gui Jianfeng wrote:
> Currently, /proc/cgroups outputs is fairly ugly as following,
> #subsys_name hierarchy num_cgroups enabled
> cpuset 0 1 1
> debug 0 1 1
> ns 0 1 1
>
> indent it in a good-looking way.
> #subsys_name hierarchy num_cgroups enabled
> cpuset 0 1 1
> debug 0 1 1
> ns 0 1 1
>

But if there's a subsystem with name length >= 8,
it won't be aligned properly..

>
> Signed-off-by: Gui Jianfeng <guijianfeng DeleteThis @cn.fujitsu.com>
> ---
> kernel/cgroup.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/kernel/cgroup.c b/kernel/cgroup.c
> index 3737a68..99fc160 100644
> --- a/kernel/cgroup.c
> +++ b/kernel/cgroup.c
> @@ -2963,7 +2963,7 @@ static int proc_cgroupstats_show(struct seq_file *m, void *v)
> mutex_lock(&cgroup_mutex);
> for (i = 0; i < CGROUP_SUBSYS_COUNT; i++) {
> struct cgroup_subsys *ss = subsys[i];
> - seq_printf(m, "%s\t%lu\t%d\t%d\n",
> + seq_printf(m, "%s\t\t%lu\t\t%d\t\t%d\n",
> ss->name, ss->root->subsys_bits,
> ss->root->number_of_cgroups, !ss->disabled);
> }

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo DeleteThis @vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Back to top
Login to vote
Gui Jianfeng

External


Since: Jul 03, 2009
Posts: 11



(Msg. 3) Posted: Fri Jul 03, 2009 10:40 am
Post subject: Re: [PATCH] cgroup: Fix indent for /proc/cgroups [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

Li Zefan wrote:
> CC: container list
>
> Gui Jianfeng wrote:
>> Currently, /proc/cgroups outputs is fairly ugly as following,
>> #subsys_name hierarchy num_cgroups enabled
>> cpuset 0 1 1
>> debug 0 1 1
>> ns 0 1 1
>>
>> indent it in a good-looking way.
>> #subsys_name hierarchy num_cgroups enabled
>> cpuset 0 1 1
>> debug 0 1 1
>> ns 0 1 1
>>
>
> But if there's a subsystem with name length >= 8,
> it won't be aligned properly..

Yeap, but there isn't such a case at least by now.

>
>> Signed-off-by: Gui Jianfeng <guijianfeng.DeleteThis@cn.fujitsu.com>
>> ---
>> kernel/cgroup.c | 2 +-
>> 1 files changed, 1 insertions(+), 1 deletions(-)
>>
>> diff --git a/kernel/cgroup.c b/kernel/cgroup.c
>> index 3737a68..99fc160 100644
>> --- a/kernel/cgroup.c
>> +++ b/kernel/cgroup.c
>> @@ -2963,7 +2963,7 @@ static int proc_cgroupstats_show(struct seq_file *m, void *v)
>> mutex_lock(&cgroup_mutex);
>> for (i = 0; i < CGROUP_SUBSYS_COUNT; i++) {
>> struct cgroup_subsys *ss = subsys[i];
>> - seq_printf(m, "%s\t%lu\t%d\t%d\n",
>> + seq_printf(m, "%s\t\t%lu\t\t%d\t\t%d\n",
>> ss->name, ss->root->subsys_bits,
>> ss->root->number_of_cgroups, !ss->disabled);
>> }
>
>
>
>

--
Regards
Gui Jianfeng

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo.DeleteThis@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Back to top
Login to vote
Li Zefan

External


Since: Jul 03, 2009
Posts: 18



(Msg. 4) Posted: Fri Jul 03, 2009 10:50 am
Post subject: Re: [PATCH] cgroup: Fix indent for /proc/cgroups [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

Gui Jianfeng wrote:
> Li Zefan wrote:
>> CC: container list
>>
>> Gui Jianfeng wrote:
>>> Currently, /proc/cgroups outputs is fairly ugly as following,
>>> #subsys_name hierarchy num_cgroups enabled
>>> cpuset 0 1 1
>>> debug 0 1 1
>>> ns 0 1 1
>>>
>>> indent it in a good-looking way.
>>> #subsys_name hierarchy num_cgroups enabled
>>> cpuset 0 1 1
>>> debug 0 1 1
>>> ns 0 1 1
>>>
>> But if there's a subsystem with name length >= 8,
>> it won't be aligned properly..
>
> Yeap, but there isn't such a case at least by now.
>

This is not a good reason.

We'll probably have such a subsystem. Actually there's a
proposed subsystem named "maxdepth" which is of length 8.

See:
http://lkml.org/lkml/2009/7/1/581

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo RemoveThis @vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Back to top
Login to vote
Gui Jianfeng

External


Since: Jul 03, 2009
Posts: 11



(Msg. 5) Posted: Fri Jul 03, 2009 11:10 am
Post subject: Re: [PATCH] cgroup: Fix indent for /proc/cgroups [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

Li Zefan wrote:
> Gui Jianfeng wrote:
>> Li Zefan wrote:
>>> CC: container list
>>>
>>> Gui Jianfeng wrote:
>>>> Currently, /proc/cgroups outputs is fairly ugly as following,
>>>> #subsys_name hierarchy num_cgroups enabled
>>>> cpuset 0 1 1
>>>> debug 0 1 1
>>>> ns 0 1 1
>>>>
>>>> indent it in a good-looking way.
>>>> #subsys_name hierarchy num_cgroups enabled
>>>> cpuset 0 1 1
>>>> debug 0 1 1
>>>> ns 0 1 1
>>>>
>>> But if there's a subsystem with name length >= 8,
>>> it won't be aligned properly..
>> Yeap, but there isn't such a case at least by now.
>>
>
> This is not a good reason.
>
> We'll probably have such a subsystem. Actually there's a
> proposed subsystem named "maxdepth" which is of length 8.
>
> See:
> http://lkml.org/lkml/2009/7/1/581

yes, this is a case. But at least others can be aligned
properly, right? Anyway, please ignore it if you don't
like this change.

>
>
>
>

--
Regards
Gui Jianfeng

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo.TakeThisOut@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Back to top
Login to vote
Paul Menage

External


Since: Jul 03, 2009
Posts: 2



(Msg. 6) Posted: Fri Jul 03, 2009 3:26 pm
Post subject: Re: [PATCH] cgroup: Fix indent for /proc/cgroups [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

On Fri, Jul 3, 2009 at 1:05 AM, Gui Jianfeng<guijianfeng.TakeThisOut@cn.fujitsu.com> wrote:
> Currently, /proc/cgroups outputs is fairly ugly as following,

Yes, I agree it's somewhat ugly. But it's at least very easily machine
parseable, and fairly easily human parseable, which are the important
points.

Paul
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo.TakeThisOut@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Back to top
Login to vote
Display posts from previous:   
Related Topics:
[PATCH][5/8] proc: export mlocked pages info through "/pro.. - Export mlock(wired) info through file /proc/meminfo. Signed-off-by: Shaoping Wang <pwstone@gmail.com> -- fs/proc/proc_misc.c | 5 ++++- include/linux/mm.h | 4 ++++ include/linux/mmzone.h | 4 ++-- mm/page_alloc.c | 26..

[PATCH] reiserfs: fix up case where indent misreads the code - indent(1) doesn't know how to handle the "do not compile" error. It results in the item_ops array declaration being indented a tab stop in when it should not be. This patch replaces it with a #error that describes why it's failing. Signed-of...

[PATCH 0/2] Conversion of /proc/sysvipc/* to seq_file - The following two patches convert /proc/sysvipc/* to use seq_file. This gives us the following: - Self-consistent IPC records in proc. - O(n) reading of the files themselves. Please consider applying. Thanks, Mike Waychison - To unsubscribe from..

[PATCH] Fix sparse warning in proc/task_mmu.c. - Hi, The patch below fixes this sparse warning: fs/proc/task_mmu.c:198:33: warning: Using plain integer as NULL pointer Signed-off-by: Luiz Capitulino <lcapitulino@mandriva.com.br> fs/proc/task_mmu.c | 2 +- 1 files changed, 1 insertion(+), ...

[PATCH] disable per cpu intr in /proc/stat - (No bugzilla or benchmark) From: schwab@suse.de Subject: Reading /proc/stat is slooow Don't compute and display the per-irq sums on ia64 either, too much overhead for mostly useless figures. --- linux-2.6.14/fs/proc/proc_misc.c.~1~ 2005-12-06..
       Linux (Home) -> Kernel All times are: Pacific Time (US & Canada) (change)
Page 1 of 1

 
You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Categories:
 Windows Forums
 Game Forums
  Linux Forums
 Mac Forums
 PDA Forums
 Mobile Forums
  Top  |  Store  |  RSS Feeds RSS  |  Data Feeds  |  Advertise  |  Submit  |  Bookmark  |  Newsletter  |  Contact