X-Git-Url: https://git.camperquake.de/gitweb.cgi?a=blobdiff_plain;f=module%2Fzfs%2Fzpl_xattr.c;h=7a1ecec8f14bb442cad2f2c7c1a9e3d307bc7aef;hb=f9637c6c8b9c452c440a366aa937b363f027d95e;hp=910500a722d0a0f0ecc3c55e034c661ed92587d3;hpb=cc5f931cfd623c50f283fa5cf1bc21cfd7e5c703;p=zfs.git diff --git a/module/zfs/zpl_xattr.c b/module/zfs/zpl_xattr.c index 910500a..7a1ecec 100644 --- a/module/zfs/zpl_xattr.c +++ b/module/zfs/zpl_xattr.c @@ -266,7 +266,7 @@ out: } static int -zpl_xattr_user_get(struct inode *ip, const char *name, +__zpl_xattr_user_get(struct inode *ip, const char *name, void *buffer, size_t size) { char *xattr_name; @@ -284,9 +284,10 @@ zpl_xattr_user_get(struct inode *ip, const char *name, return (error); } +ZPL_XATTR_GET_WRAPPER(zpl_xattr_user_get); static int -zpl_xattr_user_set(struct inode *ip, const char *name, +__zpl_xattr_user_set(struct inode *ip, const char *name, const void *value, size_t size, int flags) { char *xattr_name; @@ -304,15 +305,16 @@ zpl_xattr_user_set(struct inode *ip, const char *name, return (error); } +ZPL_XATTR_SET_WRAPPER(zpl_xattr_user_set); -struct xattr_handler zpl_xattr_user_handler = { +xattr_handler_t zpl_xattr_user_handler = { .prefix = XATTR_USER_PREFIX, .get = zpl_xattr_user_get, .set = zpl_xattr_user_set, }; static int -zpl_xattr_trusted_get(struct inode *ip, const char *name, +__zpl_xattr_trusted_get(struct inode *ip, const char *name, void *buffer, size_t size) { char *xattr_name; @@ -330,9 +332,10 @@ zpl_xattr_trusted_get(struct inode *ip, const char *name, return (error); } +ZPL_XATTR_GET_WRAPPER(zpl_xattr_trusted_get); static int -zpl_xattr_trusted_set(struct inode *ip, const char *name, +__zpl_xattr_trusted_set(struct inode *ip, const char *name, const void *value, size_t size, int flags) { char *xattr_name; @@ -350,15 +353,16 @@ zpl_xattr_trusted_set(struct inode *ip, const char *name, return (error); } +ZPL_XATTR_SET_WRAPPER(zpl_xattr_trusted_set); -struct xattr_handler zpl_xattr_trusted_handler = { +xattr_handler_t zpl_xattr_trusted_handler = { .prefix = XATTR_TRUSTED_PREFIX, .get = zpl_xattr_trusted_get, .set = zpl_xattr_trusted_set, }; static int -zpl_xattr_security_get(struct inode *ip, const char *name, +__zpl_xattr_security_get(struct inode *ip, const char *name, void *buffer, size_t size) { char *xattr_name; @@ -373,9 +377,10 @@ zpl_xattr_security_get(struct inode *ip, const char *name, return (error); } +ZPL_XATTR_GET_WRAPPER(zpl_xattr_security_get); static int -zpl_xattr_security_set(struct inode *ip, const char *name, +__zpl_xattr_security_set(struct inode *ip, const char *name, const void *value, size_t size, int flags) { char *xattr_name; @@ -390,6 +395,7 @@ zpl_xattr_security_set(struct inode *ip, const char *name, return (error); } +ZPL_XATTR_SET_WRAPPER(zpl_xattr_security_set); int zpl_xattr_security_init(struct inode *ip, struct inode *dip) @@ -407,7 +413,7 @@ zpl_xattr_security_init(struct inode *ip, struct inode *dip) return (error); } - error = zpl_xattr_security_set(ip, name, value, len, 0); + error = __zpl_xattr_security_set(ip, name, value, len, 0); kfree(name); kfree(value); @@ -415,13 +421,13 @@ zpl_xattr_security_init(struct inode *ip, struct inode *dip) return (error); } -struct xattr_handler zpl_xattr_security_handler = { +xattr_handler_t zpl_xattr_security_handler = { .prefix = XATTR_SECURITY_PREFIX, .get = zpl_xattr_security_get, .set = zpl_xattr_security_set, }; -struct xattr_handler *zpl_xattr_handlers[] = { +xattr_handler_t *zpl_xattr_handlers[] = { &zpl_xattr_security_handler, &zpl_xattr_trusted_handler, &zpl_xattr_user_handler,