diff options
Diffstat (limited to 'fs/xfs/xfs_attr_leaf.h')
-rw-r--r-- | fs/xfs/xfs_attr_leaf.h | 12 |
1 files changed, 0 insertions, 12 deletions
diff --git a/fs/xfs/xfs_attr_leaf.h b/fs/xfs/xfs_attr_leaf.h index 83e9af417ca2..9c7d22fdcf4d 100644 --- a/fs/xfs/xfs_attr_leaf.h +++ b/fs/xfs/xfs_attr_leaf.h | |||
@@ -151,8 +151,6 @@ typedef struct xfs_attr_leafblock { | |||
151 | /* | 151 | /* |
152 | * Cast typed pointers for "local" and "remote" name/value structs. | 152 | * Cast typed pointers for "local" and "remote" name/value structs. |
153 | */ | 153 | */ |
154 | #define XFS_ATTR_LEAF_NAME_REMOTE(leafp,idx) \ | ||
155 | xfs_attr_leaf_name_remote(leafp,idx) | ||
156 | static inline xfs_attr_leaf_name_remote_t * | 154 | static inline xfs_attr_leaf_name_remote_t * |
157 | xfs_attr_leaf_name_remote(xfs_attr_leafblock_t *leafp, int idx) | 155 | xfs_attr_leaf_name_remote(xfs_attr_leafblock_t *leafp, int idx) |
158 | { | 156 | { |
@@ -160,8 +158,6 @@ xfs_attr_leaf_name_remote(xfs_attr_leafblock_t *leafp, int idx) | |||
160 | &((char *)leafp)[be16_to_cpu(leafp->entries[idx].nameidx)]; | 158 | &((char *)leafp)[be16_to_cpu(leafp->entries[idx].nameidx)]; |
161 | } | 159 | } |
162 | 160 | ||
163 | #define XFS_ATTR_LEAF_NAME_LOCAL(leafp,idx) \ | ||
164 | xfs_attr_leaf_name_local(leafp,idx) | ||
165 | static inline xfs_attr_leaf_name_local_t * | 161 | static inline xfs_attr_leaf_name_local_t * |
166 | xfs_attr_leaf_name_local(xfs_attr_leafblock_t *leafp, int idx) | 162 | xfs_attr_leaf_name_local(xfs_attr_leafblock_t *leafp, int idx) |
167 | { | 163 | { |
@@ -169,8 +165,6 @@ xfs_attr_leaf_name_local(xfs_attr_leafblock_t *leafp, int idx) | |||
169 | &((char *)leafp)[be16_to_cpu(leafp->entries[idx].nameidx)]; | 165 | &((char *)leafp)[be16_to_cpu(leafp->entries[idx].nameidx)]; |
170 | } | 166 | } |
171 | 167 | ||
172 | #define XFS_ATTR_LEAF_NAME(leafp,idx) \ | ||
173 | xfs_attr_leaf_name(leafp,idx) | ||
174 | static inline char *xfs_attr_leaf_name(xfs_attr_leafblock_t *leafp, int idx) | 168 | static inline char *xfs_attr_leaf_name(xfs_attr_leafblock_t *leafp, int idx) |
175 | { | 169 | { |
176 | return &((char *)leafp)[be16_to_cpu(leafp->entries[idx].nameidx)]; | 170 | return &((char *)leafp)[be16_to_cpu(leafp->entries[idx].nameidx)]; |
@@ -181,24 +175,18 @@ static inline char *xfs_attr_leaf_name(xfs_attr_leafblock_t *leafp, int idx) | |||
181 | * a "local" name/value structure, a "remote" name/value structure, and | 175 | * a "local" name/value structure, a "remote" name/value structure, and |
182 | * a pointer which might be either. | 176 | * a pointer which might be either. |
183 | */ | 177 | */ |
184 | #define XFS_ATTR_LEAF_ENTSIZE_REMOTE(nlen) \ | ||
185 | xfs_attr_leaf_entsize_remote(nlen) | ||
186 | static inline int xfs_attr_leaf_entsize_remote(int nlen) | 178 | static inline int xfs_attr_leaf_entsize_remote(int nlen) |
187 | { | 179 | { |
188 | return ((uint)sizeof(xfs_attr_leaf_name_remote_t) - 1 + (nlen) + \ | 180 | return ((uint)sizeof(xfs_attr_leaf_name_remote_t) - 1 + (nlen) + \ |
189 | XFS_ATTR_LEAF_NAME_ALIGN - 1) & ~(XFS_ATTR_LEAF_NAME_ALIGN - 1); | 181 | XFS_ATTR_LEAF_NAME_ALIGN - 1) & ~(XFS_ATTR_LEAF_NAME_ALIGN - 1); |
190 | } | 182 | } |
191 | 183 | ||
192 | #define XFS_ATTR_LEAF_ENTSIZE_LOCAL(nlen,vlen) \ | ||
193 | xfs_attr_leaf_entsize_local(nlen,vlen) | ||
194 | static inline int xfs_attr_leaf_entsize_local(int nlen, int vlen) | 184 | static inline int xfs_attr_leaf_entsize_local(int nlen, int vlen) |
195 | { | 185 | { |
196 | return ((uint)sizeof(xfs_attr_leaf_name_local_t) - 1 + (nlen) + (vlen) + | 186 | return ((uint)sizeof(xfs_attr_leaf_name_local_t) - 1 + (nlen) + (vlen) + |
197 | XFS_ATTR_LEAF_NAME_ALIGN - 1) & ~(XFS_ATTR_LEAF_NAME_ALIGN - 1); | 187 | XFS_ATTR_LEAF_NAME_ALIGN - 1) & ~(XFS_ATTR_LEAF_NAME_ALIGN - 1); |
198 | } | 188 | } |
199 | 189 | ||
200 | #define XFS_ATTR_LEAF_ENTSIZE_LOCAL_MAX(bsize) \ | ||
201 | xfs_attr_leaf_entsize_local_max(bsize) | ||
202 | static inline int xfs_attr_leaf_entsize_local_max(int bsize) | 190 | static inline int xfs_attr_leaf_entsize_local_max(int bsize) |
203 | { | 191 | { |
204 | return (((bsize) >> 1) + ((bsize) >> 2)); | 192 | return (((bsize) >> 1) + ((bsize) >> 2)); |