xfs
[Top] [All Lists]

[PATCH 2/2] xfs: replace xfs_buf_geterror() with bp->b_error

To: xfs@xxxxxxxxxxx
Subject: [PATCH 2/2] xfs: replace xfs_buf_geterror() with bp->b_error
From: Chandra Seetharaman <sekharan@xxxxxxxxxx>
Date: Tue, 02 Aug 2011 19:18:34 -0700
Cc: Chandra Seetharaman <sekharan@xxxxxxxxxx>
In-reply-to: <20110803021823.29700.71553.sendpatchset@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx>
References: <20110803021823.29700.71553.sendpatchset@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx>
Since we just checked bp for NULL, it is ok to replace xfs_buf_geterror()
with bp->b_error in these places.

Signed-off-by: Chandra Seetharaman <sekharan@xxxxxxxxxx>
---
 fs/xfs/xfs_log_recover.c |    4 ++--
 fs/xfs/xfs_vnodeops.c    |    2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/fs/xfs/xfs_log_recover.c b/fs/xfs/xfs_log_recover.c
index 8478532..a9df667 100644
--- a/fs/xfs/xfs_log_recover.c
+++ b/fs/xfs/xfs_log_recover.c
@@ -2133,7 +2133,7 @@ xlog_recover_buffer_pass2(
                          buf_flags);
        if (!bp)
                return XFS_ERROR(ENOMEM);
-       error = xfs_buf_geterror(bp);
+       error = bp->b_error;
        if (error) {
                xfs_ioerror_alert("xlog_recover_do..(read#1)", mp,
                                  bp, buf_f->blf_blkno);
@@ -2228,7 +2228,7 @@ xlog_recover_inode_pass2(
                error = ENOMEM;
                goto error;
        }
-       error = xfs_buf_geterror(bp);
+       error = bp->b_error;
        if (error) {
                xfs_ioerror_alert("xlog_recover_do..(read#2)", mp,
                                  bp, in_f->ilf_blkno);
diff --git a/fs/xfs/xfs_vnodeops.c b/fs/xfs/xfs_vnodeops.c
index 64a5835..d465c94 100644
--- a/fs/xfs/xfs_vnodeops.c
+++ b/fs/xfs/xfs_vnodeops.c
@@ -85,7 +85,7 @@ xfs_readlink_bmap(
                                  XBF_LOCK | XBF_MAPPED | XBF_DONT_BLOCK);
                if (!bp)
                        return XFS_ERROR(ENOMEM);
-               error = xfs_buf_geterror(bp);
+               error = bp->b_error;
                if (error) {
                        xfs_ioerror_alert("xfs_readlink",
                                  ip->i_mount, bp, XFS_BUF_ADDR(bp));
-- 
1.7.1

<Prev in Thread] Current Thread [Next in Thread>