Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 5a52c2a5 authored by Chandra Seetharaman's avatar Chandra Seetharaman Committed by Alex Elder
Browse files

xfs: Remove the macro XFS_BUF_ERROR and family



Remove the definitions and usage of the macros XFS_BUF_ERROR,
XFS_BUF_GETERROR and XFS_BUF_ISERROR.

Signed-off-by: default avatarChandra Seetharaman <sekharan@us.ibm.com>
Reviewed-by: default avatarChristoph Hellwig <hch@lst.de>
Signed-off-by: default avatarAlex Elder <aelder@sgi.com>
parent ed43233b
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -596,7 +596,7 @@ _xfs_buf_read(
	bp->b_flags |= flags & (XBF_READ | XBF_ASYNC | XBF_READ_AHEAD);

	status = xfs_buf_iorequest(bp);
	if (status || XFS_BUF_ISERROR(bp) || (flags & XBF_ASYNC))
	if (status || bp->b_error || (flags & XBF_ASYNC))
		return status;
	return xfs_buf_iowait(bp);
}
@@ -1069,7 +1069,7 @@ xfs_bioerror(
	/*
	 * No need to wait until the buffer is unpinned, we aren't flushing it.
	 */
	XFS_BUF_ERROR(bp, EIO);
	xfs_buf_ioerror(bp, EIO);

	/*
	 * We're calling xfs_buf_ioend, so delete XBF_DONE flag.
@@ -1115,7 +1115,7 @@ xfs_bioerror_relse(
		 * There's no reason to mark error for
		 * ASYNC buffers.
		 */
		XFS_BUF_ERROR(bp, EIO);
		xfs_buf_ioerror(bp, EIO);
		XFS_BUF_FINISH_IOWAIT(bp);
	} else {
		xfs_buf_relse(bp);
+0 −4
Original line number Diff line number Diff line
@@ -250,10 +250,6 @@ void xfs_buf_stale(struct xfs_buf *bp);
#define XFS_BUF_UNDELAYWRITE(bp)	xfs_buf_delwri_dequeue(bp)
#define XFS_BUF_ISDELAYWRITE(bp)	((bp)->b_flags & XBF_DELWRI)

#define XFS_BUF_ERROR(bp,no)	xfs_buf_ioerror(bp,no)
#define XFS_BUF_GETERROR(bp)	xfs_buf_geterror(bp)
#define XFS_BUF_ISERROR(bp)	(xfs_buf_geterror(bp) ? 1 : 0)

#define XFS_BUF_DONE(bp)	((bp)->b_flags |= XBF_DONE)
#define XFS_BUF_UNDONE(bp)	((bp)->b_flags &= ~XBF_DONE)
#define XFS_BUF_ISDONE(bp)	((bp)->b_flags & XBF_DONE)
+1 −1
Original line number Diff line number Diff line
@@ -403,7 +403,7 @@ xfs_qm_dqalloc(
			       dqp->q_blkno,
			       mp->m_quotainfo->qi_dqchunklen,
			       0);
	if (!bp || (error = XFS_BUF_GETERROR(bp)))
	if (!bp || (error = xfs_buf_geterror(bp)))
		goto error1;
	/*
	 * Make a chunk of dquots out of this buffer and log
+3 −4
Original line number Diff line number Diff line
@@ -451,8 +451,7 @@ xfs_alloc_read_agfl(
			XFS_FSS_TO_BB(mp, 1), 0, &bp);
	if (error)
		return error;
	ASSERT(bp);
	ASSERT(!XFS_BUF_GETERROR(bp));
	ASSERT(!xfs_buf_geterror(bp));
	XFS_BUF_SET_VTYPE_REF(bp, B_FS_AGFL, XFS_AGFL_REF);
	*bpp = bp;
	return 0;
@@ -2116,7 +2115,7 @@ xfs_read_agf(
	if (!*bpp)
		return 0;

	ASSERT(!XFS_BUF_GETERROR(*bpp));
	ASSERT(!(*bpp)->b_error);
	agf = XFS_BUF_TO_AGF(*bpp);

	/*
@@ -2168,7 +2167,7 @@ xfs_alloc_read_agf(
		return error;
	if (!*bpp)
		return 0;
	ASSERT(!XFS_BUF_GETERROR(*bpp));
	ASSERT(!(*bpp)->b_error);

	agf = XFS_BUF_TO_AGF(*bpp);
	pag = xfs_perag_get(mp, agno);
+1 −2
Original line number Diff line number Diff line
@@ -2121,8 +2121,7 @@ xfs_attr_rmtval_set(xfs_da_args_t *args)

		bp = xfs_buf_get(mp->m_ddev_targp, dblkno, blkcnt,
				 XBF_LOCK | XBF_DONT_BLOCK);
		ASSERT(bp);
		ASSERT(!XFS_BUF_GETERROR(bp));
		ASSERT(!xfs_buf_geterror(bp));

		tmp = (valuelen < XFS_BUF_SIZE(bp)) ? valuelen :
							XFS_BUF_SIZE(bp);
Loading