Hi,
On Fri, 2006-02-24 at 16:05 -0500, James Morris wrote:
> On Fri, 24 Feb 2006, Steven Whitehouse wrote:
>
>
> > +/**
> > + * gfs2_ea_name2type - get the type of the ea, and truncate type from the name
> > + * @namep: ea name, possibly with type appended
> > + *
> > + * Returns: GFS2_EATYPE_XXX
> > + */
> > +
> > +unsigned int gfs2_ea_name2type(const char *name, char **truncated_name)
> > +{
> > + unsigned int type;
> > +
> > + if (strncmp(name, "system.", 7) == 0) {
> > + type = GFS2_EATYPE_SYS;
> > + if (truncated_name)
> > + *truncated_name = strchr(name, '.') + 1;
> > + } else if (strncmp(name, "user.", 5) == 0) {
> > + type = GFS2_EATYPE_USR;
> > + if (truncated_name)
> > + *truncated_name = strchr(name, '.') + 1;
> > + } else {
> > + type = GFS2_EATYPE_UNUSED;
> > + if (truncated_name)
> > + *truncated_name = NULL;
> > + }
> > +
> > + return type;
> > +}
>
>
> Consider using the generic xattr infrastructure in the kernel (xattr.c),
> e.g. generic_getxattr() and friends.
>
>
>
> - James
Yes, I've also had some similar feedback in private email. We will
certainly look into doing this at the same time as we look at the
selinux/xattr support so its high on our agenda now. Thanks for the
feedback,
Steve.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[Index of Archives]
[Kernel Newbies]
[Netfilter]
[Bugtraq]
[Photo]
[Stuff]
[Gimp]
[Yosemite News]
[MIPS Linux]
[ARM Linux]
[Linux Security]
[Linux RAID]
[Video 4 Linux]
[Linux for the blind]
[Linux Resources]