Commit 5cfd28b6 authored by Dave Chinner's avatar Dave Chinner Committed by Dave Chinner

xfs: remove XBF_STALE flag wrapper macros

They only set/clear/check a flag, no need for obfuscating this
with a macro.
Signed-off-by: default avatarDave Chinner <dchinner@redhat.com>
Reviewed-by: default avatarChristoph Hellwig <hch@lst.de>
Signed-off-by: default avatarDave Chinner <david@fromorbit.com>
parent b68c0821
...@@ -302,6 +302,7 @@ extern void xfs_buf_iomove(xfs_buf_t *, size_t, size_t, void *, ...@@ -302,6 +302,7 @@ extern void xfs_buf_iomove(xfs_buf_t *, size_t, size_t, void *,
/* Buffer Utility Routines */ /* Buffer Utility Routines */
extern void *xfs_buf_offset(struct xfs_buf *, size_t); extern void *xfs_buf_offset(struct xfs_buf *, size_t);
extern void xfs_buf_stale(struct xfs_buf *bp);
/* Delayed Write Buffer Routines */ /* Delayed Write Buffer Routines */
extern bool xfs_buf_delwri_queue(struct xfs_buf *, struct list_head *); extern bool xfs_buf_delwri_queue(struct xfs_buf *, struct list_head *);
...@@ -317,9 +318,6 @@ extern void xfs_buf_terminate(void); ...@@ -317,9 +318,6 @@ extern void xfs_buf_terminate(void);
XBF_SYNCIO|XBF_FUA|XBF_FLUSH| \ XBF_SYNCIO|XBF_FUA|XBF_FLUSH| \
XBF_WRITE_FAIL)) XBF_WRITE_FAIL))
void xfs_buf_stale(struct xfs_buf *bp);
#define XFS_BUF_UNSTALE(bp) ((bp)->b_flags &= ~XBF_STALE)
#define XFS_BUF_ISSTALE(bp) ((bp)->b_flags & XBF_STALE)
/* /*
* These macros use the IO block map rather than b_bn. b_bn is now really * These macros use the IO block map rather than b_bn. b_bn is now really
......
...@@ -431,7 +431,7 @@ xfs_buf_item_unpin( ...@@ -431,7 +431,7 @@ xfs_buf_item_unpin(
if (freed && stale) { if (freed && stale) {
ASSERT(bip->bli_flags & XFS_BLI_STALE); ASSERT(bip->bli_flags & XFS_BLI_STALE);
ASSERT(xfs_buf_islocked(bp)); ASSERT(xfs_buf_islocked(bp));
ASSERT(XFS_BUF_ISSTALE(bp)); ASSERT(bp->b_flags & XBF_STALE);
ASSERT(bip->__bli_format.blf_flags & XFS_BLF_CANCEL); ASSERT(bip->__bli_format.blf_flags & XFS_BLF_CANCEL);
trace_xfs_buf_item_unpin_stale(bip); trace_xfs_buf_item_unpin_stale(bip);
......
...@@ -534,8 +534,8 @@ xfs_trans_log_buf(xfs_trans_t *tp, ...@@ -534,8 +534,8 @@ xfs_trans_log_buf(xfs_trans_t *tp,
*/ */
if (bip->bli_flags & XFS_BLI_STALE) { if (bip->bli_flags & XFS_BLI_STALE) {
bip->bli_flags &= ~XFS_BLI_STALE; bip->bli_flags &= ~XFS_BLI_STALE;
ASSERT(XFS_BUF_ISSTALE(bp)); ASSERT(bp->b_flags & XBF_STALE);
XFS_BUF_UNSTALE(bp); bp->b_flags &= ~XBF_STALE;
bip->__bli_format.blf_flags &= ~XFS_BLF_CANCEL; bip->__bli_format.blf_flags &= ~XFS_BLF_CANCEL;
} }
...@@ -600,7 +600,7 @@ xfs_trans_binval( ...@@ -600,7 +600,7 @@ xfs_trans_binval(
* If the buffer is already invalidated, then * If the buffer is already invalidated, then
* just return. * just return.
*/ */
ASSERT(XFS_BUF_ISSTALE(bp)); ASSERT(bp->b_flags & XBF_STALE);
ASSERT(!(bip->bli_flags & (XFS_BLI_LOGGED | XFS_BLI_DIRTY))); ASSERT(!(bip->bli_flags & (XFS_BLI_LOGGED | XFS_BLI_DIRTY)));
ASSERT(!(bip->__bli_format.blf_flags & XFS_BLF_INODE_BUF)); ASSERT(!(bip->__bli_format.blf_flags & XFS_BLF_INODE_BUF));
ASSERT(!(bip->__bli_format.blf_flags & XFS_BLFT_MASK)); ASSERT(!(bip->__bli_format.blf_flags & XFS_BLFT_MASK));
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment