Signed-off-by: Carlos Maiolino <cmaiolino@xxxxxxxxxx> --- fs/xfs/libxfs/xfs_attr_leaf.c | 4 ++-- fs/xfs/libxfs/xfs_attr_sf.h | 14 +++++++------- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/fs/xfs/libxfs/xfs_attr_leaf.c b/fs/xfs/libxfs/xfs_attr_leaf.c index a8a4e21d19726..bcc76ff298646 100644 --- a/fs/xfs/libxfs/xfs_attr_leaf.c +++ b/fs/xfs/libxfs/xfs_attr_leaf.c @@ -736,7 +736,7 @@ xfs_attr_shortform_add( size = xfs_attr_sf_entsize_byname(args->namelen, args->valuelen); xfs_idata_realloc(dp, size, XFS_ATTR_FORK); sf = (xfs_attr_shortform_t *)ifp->if_u1.if_data; - sfe = (xfs_attr_sf_entry_t *)((char *)sf + offset); + sfe = (struct xfs_attr_sf_entry *)((char *)sf + offset); sfe->namelen = args->namelen; sfe->valuelen = args->valuelen; @@ -838,7 +838,7 @@ int xfs_attr_shortform_lookup(xfs_da_args_t *args) { xfs_attr_shortform_t *sf; - xfs_attr_sf_entry_t *sfe; + struct xfs_attr_sf_entry *sfe; int i; struct xfs_ifork *ifp; diff --git a/fs/xfs/libxfs/xfs_attr_sf.h b/fs/xfs/libxfs/xfs_attr_sf.h index 48906c5196505..6b09a010940ea 100644 --- a/fs/xfs/libxfs/xfs_attr_sf.h +++ b/fs/xfs/libxfs/xfs_attr_sf.h @@ -13,7 +13,6 @@ * to fit into the literal area of the inode. */ typedef struct xfs_attr_sf_hdr xfs_attr_sf_hdr_t; -typedef struct xfs_attr_sf_entry xfs_attr_sf_entry_t; /* * We generate this then sort it, attr_list() must return things in hash-order. @@ -31,17 +30,18 @@ typedef struct xfs_attr_sf_sort { (1 << (NBBY*(int)sizeof(uint8_t))) static inline int xfs_attr_sf_entsize_byname(uint8_t nlen, uint8_t vlen) { - return sizeof(xfs_attr_sf_entry_t) + nlen + vlen; + return sizeof(struct xfs_attr_sf_entry) + nlen + vlen; } /* space an entry uses */ -static inline int xfs_attr_sf_entsize(xfs_attr_sf_entry_t *sfep) { - return sizeof(xfs_attr_sf_entry_t) + sfep->namelen + sfep->valuelen; +static inline int xfs_attr_sf_entsize(struct xfs_attr_sf_entry *sfep) { + return sizeof(struct xfs_attr_sf_entry) + + sfep->namelen + sfep->valuelen; } -static inline xfs_attr_sf_entry_t * -xfs_attr_sf_nextentry(xfs_attr_sf_entry_t *sfep) { - return (xfs_attr_sf_entry_t *)((char *)(sfep) + +static inline struct xfs_attr_sf_entry * +xfs_attr_sf_nextentry(struct xfs_attr_sf_entry *sfep) { + return (struct xfs_attr_sf_entry *)((char *)(sfep) + xfs_attr_sf_entsize(sfep)); } #endif /* __XFS_ATTR_SF_H__ */ -- 2.26.2