summaryrefslogtreecommitdiff
path: root/include/linux/xattr.h
diff options
context:
space:
mode:
authorMimi Zohar <zohar@linux.vnet.ibm.com>2011-03-09 22:23:34 +0300
committerMimi Zohar <zohar@linux.vnet.ibm.com>2011-07-18 20:29:39 +0400
commit1601fbad2b14e0b8d4dbb55e749bfe31e972818a (patch)
treeca9271af43fc7b0edaaa9e5464a82d3b427db8b2 /include/linux/xattr.h
parentf381c272224f5f158f5cff64f8f3481fa0eee8b3 (diff)
downloadlinux-1601fbad2b14e0b8d4dbb55e749bfe31e972818a.tar.xz
xattr: define vfs_getxattr_alloc and vfs_xattr_cmp
vfs_getxattr_alloc() and vfs_xattr_cmp() are two new kernel xattr helper functions. vfs_getxattr_alloc() first allocates memory for the requested xattr and then retrieves it. vfs_xattr_cmp() compares a given value with the contents of an extended attribute. Signed-off-by: Mimi Zohar <zohar@us.ibm.com> Acked-by: Serge Hallyn <serge.hallyn@ubuntu.com>
Diffstat (limited to 'include/linux/xattr.h')
-rw-r--r--include/linux/xattr.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/include/linux/xattr.h b/include/linux/xattr.h
index 7a378662ddff..4703f6bd1f53 100644
--- a/include/linux/xattr.h
+++ b/include/linux/xattr.h
@@ -84,7 +84,10 @@ ssize_t generic_getxattr(struct dentry *dentry, const char *name, void *buffer,
ssize_t generic_listxattr(struct dentry *dentry, char *buffer, size_t buffer_size);
int generic_setxattr(struct dentry *dentry, const char *name, const void *value, size_t size, int flags);
int generic_removexattr(struct dentry *dentry, const char *name);
-
+ssize_t vfs_getxattr_alloc(struct dentry *dentry, const char *name,
+ char **xattr_value, size_t size, gfp_t flags);
+int vfs_xattr_cmp(struct dentry *dentry, const char *xattr_name,
+ const char *value, size_t size, gfp_t flags);
#endif /* __KERNEL__ */
#endif /* _LINUX_XATTR_H */