From e5bd12bfea60af455f4cbad494e4ac1082e3abd6 Mon Sep 17 00:00:00 2001 From: Eric Sandeen Date: Wed, 6 Apr 2016 07:57:32 +1000 Subject: xfs: don't pass value into attr ->put_listent The value is not used; only names and value lengths are returned. Remove the argument. Signed-off-by: Eric Sandeen Reviewed-by: Christoph Hellwig Signed-off-by: Dave Chinner --- fs/xfs/xfs_attr.h | 2 +- fs/xfs/xfs_attr_list.c | 18 ++++++------------ fs/xfs/xfs_xattr.c | 3 +-- 3 files changed, 8 insertions(+), 15 deletions(-) (limited to 'fs/xfs') diff --git a/fs/xfs/xfs_attr.h b/fs/xfs/xfs_attr.h index 2343312..dab4f41 100644 --- a/fs/xfs/xfs_attr.h +++ b/fs/xfs/xfs_attr.h @@ -114,7 +114,7 @@ typedef struct attrlist_cursor_kern { /* Return 0 on success, or -errno; other state communicated via *context */ typedef int (*put_listent_func_t)(struct xfs_attr_list_context *, int, - unsigned char *, int, int, unsigned char *); + unsigned char *, int, int); typedef struct xfs_attr_list_context { struct xfs_inode *dp; /* inode */ diff --git a/fs/xfs/xfs_attr_list.c b/fs/xfs/xfs_attr_list.c index c8be331..d30dbfa 100644 --- a/fs/xfs/xfs_attr_list.c +++ b/fs/xfs/xfs_attr_list.c @@ -106,8 +106,7 @@ xfs_attr_shortform_list(xfs_attr_list_context_t *context) sfe->flags, sfe->nameval, (int)sfe->namelen, - (int)sfe->valuelen, - &sfe->nameval[sfe->namelen]); + (int)sfe->valuelen); if (error) return error; /* @@ -198,8 +197,7 @@ xfs_attr_shortform_list(xfs_attr_list_context_t *context) sbp->flags, sbp->name, sbp->namelen, - sbp->valuelen, - &sbp->name[sbp->namelen]); + sbp->valuelen); if (error) { kmem_free(sbuf); return error; @@ -430,8 +428,7 @@ xfs_attr3_leaf_list_int( entry->flags, name_loc->nameval, (int)name_loc->namelen, - be16_to_cpu(name_loc->valuelen), - &name_loc->nameval[name_loc->namelen]); + be16_to_cpu(name_loc->valuelen)); if (retval) return retval; } else { @@ -459,16 +456,14 @@ xfs_attr3_leaf_list_int( entry->flags, name_rmt->name, (int)name_rmt->namelen, - valuelen, - args.value); + valuelen); kmem_free(args.value); } else { retval = context->put_listent(context, entry->flags, name_rmt->name, (int)name_rmt->namelen, - valuelen, - NULL); + valuelen); } if (retval) return retval; @@ -549,8 +544,7 @@ xfs_attr_put_listent( int flags, unsigned char *name, int namelen, - int valuelen, - unsigned char *value) + int valuelen) { struct attrlist *alist = (struct attrlist *)context->alist; attrlist_ent_t *aep; diff --git a/fs/xfs/xfs_xattr.c b/fs/xfs/xfs_xattr.c index f220129..7fdcf33 100644 --- a/fs/xfs/xfs_xattr.c +++ b/fs/xfs/xfs_xattr.c @@ -166,8 +166,7 @@ xfs_xattr_put_listent( int flags, unsigned char *name, int namelen, - int valuelen, - unsigned char *value) + int valuelen) { char *prefix; int prefix_len; -- cgit v1.1