All of lore.kernel.org
 help / color / mirror / Atom feed
* [RFC][PATCH] CGroups: Include hierarchy ids in /proc/<pid>/cgroup
@ 2008-04-09  0:05 Paul Menage
  0 siblings, 0 replies; 2+ messages in thread
From: Paul Menage @ 2008-04-09  0:05 UTC (permalink / raw)
  To: containers; +Cc: Andrew Morton, linux-kernel

[ The RFC associated with this patch is whether there's a better way to export such information in a way that's simultaneously extensible, human-readable and machine-parsable ]

CGroups: Include hierarchy ids in /proc/<pid>/cgroup

This patch extends the /proc/<pid>/cgroup file to include the
appropriate hierarchy ID on each line. Currently this ID isn't really
needed since a hierarchy can be completely identified by the set of
subsystems bound to it, but this is likely to change in the near
future in order to support stateless subsystems and merging/rebinding
of subsystems. Getting this change into 2.6.25 reduces the need for
an API change later.

Signed-off-by: Paul Menage <menage@google.com>

---
 kernel/cgroup.c |    1 +
 1 file changed, 1 insertion(+)

Index: cgroup-2.6.25-rc8-mm1/kernel/cgroup.c
===================================================================
--- cgroup-2.6.25-rc8-mm1.orig/kernel/cgroup.c
+++ cgroup-2.6.25-rc8-mm1/kernel/cgroup.c
@@ -2613,6 +2613,7 @@ static int proc_cgroup_show(struct seq_f
 		/* Skip this hierarchy if it has no active subsystems */
 		if (!root->actual_subsys_bits)
 			continue;
+		seq_printf(m, "%lu:", root->subsys_bits);
 		for_each_subsys(root, ss)
 			seq_printf(m, "%s%s", count++ ? "," : "", ss->name);
 		seq_putc(m, ':');

^ permalink raw reply	[flat|nested] 2+ messages in thread

* [RFC][PATCH] CGroups: Include hierarchy ids in /proc/<pid>/cgroup
@ 2008-04-09  0:05 Paul Menage
  0 siblings, 0 replies; 2+ messages in thread
From: Paul Menage @ 2008-04-09  0:05 UTC (permalink / raw)
  To: containers-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA
  Cc: Andrew Morton, linux-kernel-u79uwXL29TY76Z2rM5mHXA

[ The RFC associated with this patch is whether there's a better way to export such information in a way that's simultaneously extensible, human-readable and machine-parsable ]

CGroups: Include hierarchy ids in /proc/<pid>/cgroup

This patch extends the /proc/<pid>/cgroup file to include the
appropriate hierarchy ID on each line. Currently this ID isn't really
needed since a hierarchy can be completely identified by the set of
subsystems bound to it, but this is likely to change in the near
future in order to support stateless subsystems and merging/rebinding
of subsystems. Getting this change into 2.6.25 reduces the need for
an API change later.

Signed-off-by: Paul Menage <menage-hpIqsD4AKlfQT0dZR+AlfA@public.gmane.org>

---
 kernel/cgroup.c |    1 +
 1 file changed, 1 insertion(+)

Index: cgroup-2.6.25-rc8-mm1/kernel/cgroup.c
===================================================================
--- cgroup-2.6.25-rc8-mm1.orig/kernel/cgroup.c
+++ cgroup-2.6.25-rc8-mm1/kernel/cgroup.c
@@ -2613,6 +2613,7 @@ static int proc_cgroup_show(struct seq_f
 		/* Skip this hierarchy if it has no active subsystems */
 		if (!root->actual_subsys_bits)
 			continue;
+		seq_printf(m, "%lu:", root->subsys_bits);
 		for_each_subsys(root, ss)
 			seq_printf(m, "%s%s", count++ ? "," : "", ss->name);
 		seq_putc(m, ':');

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2008-04-09  0:06 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-04-09  0:05 [RFC][PATCH] CGroups: Include hierarchy ids in /proc/<pid>/cgroup Paul Menage
  -- strict thread matches above, loose matches on Subject: below --
2008-04-09  0:05 Paul Menage

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.