Re: [RFC][PATCH 2/3] memcg:: seq_ops support for cgroup
From: KAMEZAWA Hiroyuki
Date: Tue May 20 2008 - 20:23:47 EST
On Tue, 20 May 2008 11:46:46 -0700
"Paul Menage" <menage@xxxxxxxxxx> wrote:
> On Tue, May 20, 2008 at 2:08 AM, KAMEZAWA Hiroyuki
> <kamezawa.hiroyu@xxxxxxxxxxxxxx> wrote:
> > Does anyone have a better idea ?
> As a way of printing plain text files, it seems fine.
> My concern is that it means that cgroups no longer has any idea about
> the typing of the data being returned, which will make it harder to
> integrate with a binary stats API. You'd end up having to have a
> separate reporting method for the same data to use it. That's why the
> "read_map" function specifically doesn't take a seq_file, but instead
> takes a key/value callback abstraction, which currently maps into a
> seq_file. For the binary stats API, we can use the same reporting
> functions, and just map into the binary API output.
With current interface, my concern is hotplug.
File-per-node method requires delete/add files at hotplug.
A file for all nodes with _maps_ method cannot be used because
maps file says
The key/value pairs (and their ordering) should not
* change between reboots.
And (*read) method isn't useful ;)
Can we add new stat file dynamically ?
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/