Skip to content

Commit

Permalink
xfs: remove delwri buffer handling from xfs_buf_iorequest
Browse files Browse the repository at this point in the history
We cannot ever reach xfs_buf_iorequest for a buffer with XBF_DELWRI set,
given that all write handlers make sure that the buffer is remove from
the delwri queue before, and we never do reads with the XBF_DELWRI flag
set (which the code would not handle correctly anyway).

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Signed-off-by: Alex Elder <aelder@sgi.com>
  • Loading branch information
Christoph Hellwig authored and Alex Elder committed Oct 12, 2011
1 parent 7271d24 commit 375ec69
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions fs/xfs/xfs_buf.c
Original file line number Diff line number Diff line change
Expand Up @@ -1275,15 +1275,10 @@ xfs_buf_iorequest(
{
trace_xfs_buf_iorequest(bp, _RET_IP_);

if (bp->b_flags & XBF_DELWRI) {
xfs_buf_delwri_queue(bp, 1);
return 0;
}
ASSERT(!(bp->b_flags & XBF_DELWRI));

if (bp->b_flags & XBF_WRITE) {
if (bp->b_flags & XBF_WRITE)
xfs_buf_wait_unpin(bp);
}

xfs_buf_hold(bp);

/* Set the count to 1 initially, this will stop an I/O
Expand Down

0 comments on commit 375ec69

Please sign in to comment.