[lkml]   [2012]   [Jan]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH 2/2] cgroup: add xattr support
On Wed, 18.01.12 09:47, Tejun Heo ( wrote:

> Hello,
> On Wed, Jan 18, 2012 at 04:27:18PM +0800, Li Zefan wrote:
> > Furthermore, I noticed tmpfs also implemented xattr support, and we
> > should be able to share most of the code, which makes the cost for
> > having this feature smaller.
> Yes, maybe, but tmpfs doesn't have any special semantics attached to
> files. It's supposed to store opaque data from userland. Regardless
> of code complexity, I just don't think this is a good idea. What if
> we later want to attach certain config meaning to or export statistics
> via xattrs? That would be quite unusual and require strong rationale
> but at least fall in the similar usage as with the rest of the fs.

If you plan to export kernel data to userspace via xattrs, then you
should probably place that in the xattr namespace, not in
the or namespaces which are the only ones which can
be manipulated by userspace.

See attr(5) for more information about the four available xattr

In other words: kernel exported xattrs should never collide with xattrs
set by userspace.


Lennart Poettering - Red Hat, Inc.

 \ /
  Last update: 2012-01-19 02:51    [W:0.065 / U:5.128 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site