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

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
...@@ -596,7 +596,7 @@ _xfs_buf_read( ...@@ -596,7 +596,7 @@ _xfs_buf_read(
bp->b_flags |= flags & (XBF_READ | XBF_ASYNC | XBF_READ_AHEAD); bp->b_flags |= flags & (XBF_READ | XBF_ASYNC | XBF_READ_AHEAD);
status = xfs_buf_iorequest(bp); 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 status;
return xfs_buf_iowait(bp); return xfs_buf_iowait(bp);
} }
...@@ -1069,7 +1069,7 @@ xfs_bioerror( ...@@ -1069,7 +1069,7 @@ xfs_bioerror(
/* /*
* No need to wait until the buffer is unpinned, we aren't flushing it. * 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. * We're calling xfs_buf_ioend, so delete XBF_DONE flag.
...@@ -1115,7 +1115,7 @@ xfs_bioerror_relse( ...@@ -1115,7 +1115,7 @@ xfs_bioerror_relse(
* There's no reason to mark error for * There's no reason to mark error for
* ASYNC buffers. * ASYNC buffers.
*/ */
XFS_BUF_ERROR(bp, EIO); xfs_buf_ioerror(bp, EIO);
XFS_BUF_FINISH_IOWAIT(bp); XFS_BUF_FINISH_IOWAIT(bp);
} else { } else {
xfs_buf_relse(bp); xfs_buf_relse(bp);
......
...@@ -250,10 +250,6 @@ void xfs_buf_stale(struct xfs_buf *bp); ...@@ -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_UNDELAYWRITE(bp) xfs_buf_delwri_dequeue(bp)
#define XFS_BUF_ISDELAYWRITE(bp) ((bp)->b_flags & XBF_DELWRI) #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_DONE(bp) ((bp)->b_flags |= XBF_DONE)
#define XFS_BUF_UNDONE(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) #define XFS_BUF_ISDONE(bp) ((bp)->b_flags & XBF_DONE)
......
...@@ -403,7 +403,7 @@ xfs_qm_dqalloc( ...@@ -403,7 +403,7 @@ xfs_qm_dqalloc(
dqp->q_blkno, dqp->q_blkno,
mp->m_quotainfo->qi_dqchunklen, mp->m_quotainfo->qi_dqchunklen,
0); 0);
if (!bp || (error = XFS_BUF_GETERROR(bp))) if (!bp || (error = xfs_buf_geterror(bp)))
goto error1; goto error1;
/* /*
* Make a chunk of dquots out of this buffer and log * Make a chunk of dquots out of this buffer and log
......
...@@ -451,8 +451,7 @@ xfs_alloc_read_agfl( ...@@ -451,8 +451,7 @@ xfs_alloc_read_agfl(
XFS_FSS_TO_BB(mp, 1), 0, &bp); XFS_FSS_TO_BB(mp, 1), 0, &bp);
if (error) if (error)
return 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); XFS_BUF_SET_VTYPE_REF(bp, B_FS_AGFL, XFS_AGFL_REF);
*bpp = bp; *bpp = bp;
return 0; return 0;
...@@ -2116,7 +2115,7 @@ xfs_read_agf( ...@@ -2116,7 +2115,7 @@ xfs_read_agf(
if (!*bpp) if (!*bpp)
return 0; return 0;
ASSERT(!XFS_BUF_GETERROR(*bpp)); ASSERT(!(*bpp)->b_error);
agf = XFS_BUF_TO_AGF(*bpp); agf = XFS_BUF_TO_AGF(*bpp);
/* /*
...@@ -2168,7 +2167,7 @@ xfs_alloc_read_agf( ...@@ -2168,7 +2167,7 @@ xfs_alloc_read_agf(
return error; return error;
if (!*bpp) if (!*bpp)
return 0; return 0;
ASSERT(!XFS_BUF_GETERROR(*bpp)); ASSERT(!(*bpp)->b_error);
agf = XFS_BUF_TO_AGF(*bpp); agf = XFS_BUF_TO_AGF(*bpp);
pag = xfs_perag_get(mp, agno); pag = xfs_perag_get(mp, agno);
......
...@@ -2121,8 +2121,7 @@ xfs_attr_rmtval_set(xfs_da_args_t *args) ...@@ -2121,8 +2121,7 @@ xfs_attr_rmtval_set(xfs_da_args_t *args)
bp = xfs_buf_get(mp->m_ddev_targp, dblkno, blkcnt, bp = xfs_buf_get(mp->m_ddev_targp, dblkno, blkcnt,
XBF_LOCK | XBF_DONT_BLOCK); XBF_LOCK | XBF_DONT_BLOCK);
ASSERT(bp); ASSERT(!xfs_buf_geterror(bp));
ASSERT(!XFS_BUF_GETERROR(bp));
tmp = (valuelen < XFS_BUF_SIZE(bp)) ? valuelen : tmp = (valuelen < XFS_BUF_SIZE(bp)) ? valuelen :
XFS_BUF_SIZE(bp); XFS_BUF_SIZE(bp);
......
...@@ -275,8 +275,7 @@ xfs_btree_dup_cursor( ...@@ -275,8 +275,7 @@ xfs_btree_dup_cursor(
return error; return error;
} }
new->bc_bufs[i] = bp; new->bc_bufs[i] = bp;
ASSERT(bp); ASSERT(!xfs_buf_geterror(bp));
ASSERT(!XFS_BUF_GETERROR(bp));
} else } else
new->bc_bufs[i] = NULL; new->bc_bufs[i] = NULL;
} }
...@@ -467,8 +466,7 @@ xfs_btree_get_bufl( ...@@ -467,8 +466,7 @@ xfs_btree_get_bufl(
ASSERT(fsbno != NULLFSBLOCK); ASSERT(fsbno != NULLFSBLOCK);
d = XFS_FSB_TO_DADDR(mp, fsbno); d = XFS_FSB_TO_DADDR(mp, fsbno);
bp = xfs_trans_get_buf(tp, mp->m_ddev_targp, d, mp->m_bsize, lock); bp = xfs_trans_get_buf(tp, mp->m_ddev_targp, d, mp->m_bsize, lock);
ASSERT(bp); ASSERT(!xfs_buf_geterror(bp));
ASSERT(!XFS_BUF_GETERROR(bp));
return bp; return bp;
} }
...@@ -491,8 +489,7 @@ xfs_btree_get_bufs( ...@@ -491,8 +489,7 @@ xfs_btree_get_bufs(
ASSERT(agbno != NULLAGBLOCK); ASSERT(agbno != NULLAGBLOCK);
d = XFS_AGB_TO_DADDR(mp, agno, agbno); d = XFS_AGB_TO_DADDR(mp, agno, agbno);
bp = xfs_trans_get_buf(tp, mp->m_ddev_targp, d, mp->m_bsize, lock); bp = xfs_trans_get_buf(tp, mp->m_ddev_targp, d, mp->m_bsize, lock);
ASSERT(bp); ASSERT(!xfs_buf_geterror(bp));
ASSERT(!XFS_BUF_GETERROR(bp));
return bp; return bp;
} }
...@@ -632,7 +629,7 @@ xfs_btree_read_bufl( ...@@ -632,7 +629,7 @@ xfs_btree_read_bufl(
mp->m_bsize, lock, &bp))) { mp->m_bsize, lock, &bp))) {
return error; return error;
} }
ASSERT(!bp || !XFS_BUF_GETERROR(bp)); ASSERT(!xfs_buf_geterror(bp));
if (bp) if (bp)
XFS_BUF_SET_VTYPE_REF(bp, B_FS_MAP, refval); XFS_BUF_SET_VTYPE_REF(bp, B_FS_MAP, refval);
*bpp = bp; *bpp = bp;
...@@ -973,8 +970,7 @@ xfs_btree_get_buf_block( ...@@ -973,8 +970,7 @@ xfs_btree_get_buf_block(
*bpp = xfs_trans_get_buf(cur->bc_tp, mp->m_ddev_targp, d, *bpp = xfs_trans_get_buf(cur->bc_tp, mp->m_ddev_targp, d,
mp->m_bsize, flags); mp->m_bsize, flags);
ASSERT(*bpp); ASSERT(!xfs_buf_geterror(*bpp));
ASSERT(!XFS_BUF_GETERROR(*bpp));
*block = XFS_BUF_TO_BLOCK(*bpp); *block = XFS_BUF_TO_BLOCK(*bpp);
return 0; return 0;
...@@ -1006,8 +1002,7 @@ xfs_btree_read_buf_block( ...@@ -1006,8 +1002,7 @@ xfs_btree_read_buf_block(
if (error) if (error)
return error; return error;
ASSERT(*bpp != NULL); ASSERT(!xfs_buf_geterror(*bpp));
ASSERT(!XFS_BUF_GETERROR(*bpp));
xfs_btree_set_refs(cur, *bpp); xfs_btree_set_refs(cur, *bpp);
*block = XFS_BUF_TO_BLOCK(*bpp); *block = XFS_BUF_TO_BLOCK(*bpp);
......
...@@ -960,7 +960,7 @@ xfs_buf_iodone_callbacks( ...@@ -960,7 +960,7 @@ xfs_buf_iodone_callbacks(
static ulong lasttime; static ulong lasttime;
static xfs_buftarg_t *lasttarg; static xfs_buftarg_t *lasttarg;
if (likely(!XFS_BUF_GETERROR(bp))) if (likely(!xfs_buf_geterror(bp)))
goto do_callbacks; goto do_callbacks;
/* /*
...@@ -991,7 +991,7 @@ xfs_buf_iodone_callbacks( ...@@ -991,7 +991,7 @@ xfs_buf_iodone_callbacks(
* around. * around.
*/ */
if (XFS_BUF_ISASYNC(bp)) { if (XFS_BUF_ISASYNC(bp)) {
XFS_BUF_ERROR(bp, 0); /* errno of 0 unsets the flag */ xfs_buf_ioerror(bp, 0); /* errno of 0 unsets the flag */
if (!XFS_BUF_ISSTALE(bp)) { if (!XFS_BUF_ISSTALE(bp)) {
XFS_BUF_DELAYWRITE(bp); XFS_BUF_DELAYWRITE(bp);
......
...@@ -2040,7 +2040,7 @@ xfs_da_do_buf( ...@@ -2040,7 +2040,7 @@ xfs_da_do_buf(
case 0: case 0:
bp = xfs_trans_get_buf(trans, mp->m_ddev_targp, bp = xfs_trans_get_buf(trans, mp->m_ddev_targp,
mappedbno, nmapped, 0); mappedbno, nmapped, 0);
error = bp ? XFS_BUF_GETERROR(bp) : XFS_ERROR(EIO); error = bp ? bp->b_error : XFS_ERROR(EIO);
break; break;
case 1: case 1:
case 2: case 2:
......
...@@ -202,8 +202,7 @@ xfs_ialloc_inode_init( ...@@ -202,8 +202,7 @@ xfs_ialloc_inode_init(
fbuf = xfs_trans_get_buf(tp, mp->m_ddev_targp, d, fbuf = xfs_trans_get_buf(tp, mp->m_ddev_targp, d,
mp->m_bsize * blks_per_cluster, mp->m_bsize * blks_per_cluster,
XBF_LOCK); XBF_LOCK);
ASSERT(fbuf); ASSERT(!xfs_buf_geterror(fbuf));
ASSERT(!XFS_BUF_GETERROR(fbuf));
/* /*
* Initialize all inodes in this buffer and then log them. * Initialize all inodes in this buffer and then log them.
...@@ -1486,7 +1485,7 @@ xfs_read_agi( ...@@ -1486,7 +1485,7 @@ xfs_read_agi(
if (error) if (error)
return error; return error;
ASSERT(*bpp && !XFS_BUF_GETERROR(*bpp)); ASSERT(!xfs_buf_geterror(*bpp));
agi = XFS_BUF_TO_AGI(*bpp); agi = XFS_BUF_TO_AGI(*bpp);
/* /*
......
...@@ -2473,7 +2473,7 @@ xfs_iflush_cluster( ...@@ -2473,7 +2473,7 @@ xfs_iflush_cluster(
if (bp->b_iodone) { if (bp->b_iodone) {
XFS_BUF_UNDONE(bp); XFS_BUF_UNDONE(bp);
XFS_BUF_STALE(bp); XFS_BUF_STALE(bp);
XFS_BUF_ERROR(bp,EIO); xfs_buf_ioerror(bp, EIO);
xfs_buf_ioend(bp, 0); xfs_buf_ioend(bp, 0);
} else { } else {
XFS_BUF_STALE(bp); XFS_BUF_STALE(bp);
......
...@@ -878,7 +878,7 @@ xlog_iodone(xfs_buf_t *bp) ...@@ -878,7 +878,7 @@ xlog_iodone(xfs_buf_t *bp)
/* /*
* Race to shutdown the filesystem if we see an error. * Race to shutdown the filesystem if we see an error.
*/ */
if (XFS_TEST_ERROR((XFS_BUF_GETERROR(bp)), l->l_mp, if (XFS_TEST_ERROR((xfs_buf_geterror(bp)), l->l_mp,
XFS_ERRTAG_IODONE_IOERR, XFS_RANDOM_IODONE_IOERR)) { XFS_ERRTAG_IODONE_IOERR, XFS_RANDOM_IODONE_IOERR)) {
xfs_ioerror_alert("xlog_iodone", l->l_mp, bp, XFS_BUF_ADDR(bp)); xfs_ioerror_alert("xlog_iodone", l->l_mp, bp, XFS_BUF_ADDR(bp));
XFS_BUF_STALE(bp); XFS_BUF_STALE(bp);
...@@ -1248,7 +1248,7 @@ xlog_bdstrat( ...@@ -1248,7 +1248,7 @@ xlog_bdstrat(
struct xlog_in_core *iclog = bp->b_fspriv; struct xlog_in_core *iclog = bp->b_fspriv;
if (iclog->ic_state & XLOG_STATE_IOERROR) { if (iclog->ic_state & XLOG_STATE_IOERROR) {
XFS_BUF_ERROR(bp, EIO); xfs_buf_ioerror(bp, EIO);
XFS_BUF_STALE(bp); XFS_BUF_STALE(bp);
xfs_buf_ioend(bp, 0); xfs_buf_ioend(bp, 0);
/* /*
......
...@@ -360,7 +360,7 @@ STATIC void ...@@ -360,7 +360,7 @@ STATIC void
xlog_recover_iodone( xlog_recover_iodone(
struct xfs_buf *bp) struct xfs_buf *bp)
{ {
if (XFS_BUF_GETERROR(bp)) { if (bp->b_error) {
/* /*
* We're not going to bother about retrying * We're not going to bother about retrying
* this during recovery. One strike! * this during recovery. One strike!
...@@ -2135,15 +2135,14 @@ xlog_recover_buffer_pass2( ...@@ -2135,15 +2135,14 @@ xlog_recover_buffer_pass2(
bp = xfs_buf_read(mp->m_ddev_targp, buf_f->blf_blkno, buf_f->blf_len, bp = xfs_buf_read(mp->m_ddev_targp, buf_f->blf_blkno, buf_f->blf_len,
buf_flags); buf_flags);
if (XFS_BUF_ISERROR(bp)) { error = xfs_buf_geterror(bp);
if (error) {
xfs_ioerror_alert("xlog_recover_do..(read#1)", mp, xfs_ioerror_alert("xlog_recover_do..(read#1)", mp,
bp, buf_f->blf_blkno); bp, buf_f->blf_blkno);
error = XFS_BUF_GETERROR(bp);
xfs_buf_relse(bp); xfs_buf_relse(bp);
return error; return error;
} }
error = 0;
if (buf_f->blf_flags & XFS_BLF_INODE_BUF) { if (buf_f->blf_flags & XFS_BLF_INODE_BUF) {
error = xlog_recover_do_inode_buffer(mp, item, bp, buf_f); error = xlog_recover_do_inode_buffer(mp, item, bp, buf_f);
} else if (buf_f->blf_flags & } else if (buf_f->blf_flags &
...@@ -2227,14 +2226,13 @@ xlog_recover_inode_pass2( ...@@ -2227,14 +2226,13 @@ xlog_recover_inode_pass2(
bp = xfs_buf_read(mp->m_ddev_targp, in_f->ilf_blkno, in_f->ilf_len, bp = xfs_buf_read(mp->m_ddev_targp, in_f->ilf_blkno, in_f->ilf_len,
XBF_LOCK); XBF_LOCK);
if (XFS_BUF_ISERROR(bp)) { error = xfs_buf_geterror(bp);
if (error) {
xfs_ioerror_alert("xlog_recover_do..(read#2)", mp, xfs_ioerror_alert("xlog_recover_do..(read#2)", mp,
bp, in_f->ilf_blkno); bp, in_f->ilf_blkno);
error = XFS_BUF_GETERROR(bp);
xfs_buf_relse(bp); xfs_buf_relse(bp);
goto error; goto error;
} }
error = 0;
ASSERT(in_f->ilf_fields & XFS_ILOG_CORE); ASSERT(in_f->ilf_fields & XFS_ILOG_CORE);
dip = (xfs_dinode_t *)xfs_buf_offset(bp, in_f->ilf_boffset); dip = (xfs_dinode_t *)xfs_buf_offset(bp, in_f->ilf_boffset);
......
...@@ -883,7 +883,7 @@ xfs_rtbuf_get( ...@@ -883,7 +883,7 @@ xfs_rtbuf_get(
if (error) { if (error) {
return error; return error;
} }
ASSERT(bp && !XFS_BUF_GETERROR(bp)); ASSERT(!xfs_buf_geterror(bp));
*bpp = bp; *bpp = bp;
return 0; return 0;
} }
......
...@@ -106,7 +106,7 @@ xfs_ioerror_alert( ...@@ -106,7 +106,7 @@ xfs_ioerror_alert(
" (\"%s\") error %d buf count %zd", " (\"%s\") error %d buf count %zd",
XFS_BUFTARG_NAME(XFS_BUF_TARGET(bp)), XFS_BUFTARG_NAME(XFS_BUF_TARGET(bp)),
(__uint64_t)blkno, func, (__uint64_t)blkno, func,
XFS_BUF_GETERROR(bp), XFS_BUF_COUNT(bp)); bp->b_error, XFS_BUF_COUNT(bp));
} }
/* /*
...@@ -137,8 +137,8 @@ xfs_read_buf( ...@@ -137,8 +137,8 @@ xfs_read_buf(
bp = xfs_buf_read(target, blkno, len, flags); bp = xfs_buf_read(target, blkno, len, flags);
if (!bp) if (!bp)
return XFS_ERROR(EIO); return XFS_ERROR(EIO);
error = XFS_BUF_GETERROR(bp); error = bp->b_error;
if (bp && !error && !XFS_FORCED_SHUTDOWN(mp)) { if (!error && !XFS_FORCED_SHUTDOWN(mp)) {
*bpp = bp; *bpp = bp;
} else { } else {
*bpp = NULL; *bpp = NULL;
......
...@@ -194,7 +194,7 @@ xfs_trans_get_buf(xfs_trans_t *tp, ...@@ -194,7 +194,7 @@ xfs_trans_get_buf(xfs_trans_t *tp,
return NULL; return NULL;
} }
ASSERT(!XFS_BUF_GETERROR(bp)); ASSERT(!bp->b_error);
_xfs_trans_bjoin(tp, bp, 1); _xfs_trans_bjoin(tp, bp, 1);
trace_xfs_trans_get_buf(bp->b_fspriv); trace_xfs_trans_get_buf(bp->b_fspriv);
...@@ -293,10 +293,10 @@ xfs_trans_read_buf( ...@@ -293,10 +293,10 @@ xfs_trans_read_buf(
return (flags & XBF_TRYLOCK) ? return (flags & XBF_TRYLOCK) ?
EAGAIN : XFS_ERROR(ENOMEM); EAGAIN : XFS_ERROR(ENOMEM);
if (XFS_BUF_GETERROR(bp) != 0) { if (bp->b_error) {
error = bp->b_error;
xfs_ioerror_alert("xfs_trans_read_buf", mp, xfs_ioerror_alert("xfs_trans_read_buf", mp,
bp, blkno); bp, blkno);
error = XFS_BUF_GETERROR(bp);
xfs_buf_relse(bp); xfs_buf_relse(bp);
return error; return error;
} }
...@@ -330,7 +330,7 @@ xfs_trans_read_buf( ...@@ -330,7 +330,7 @@ xfs_trans_read_buf(
ASSERT(xfs_buf_islocked(bp)); ASSERT(xfs_buf_islocked(bp));
ASSERT(bp->b_transp == tp); ASSERT(bp->b_transp == tp);
ASSERT(bp->b_fspriv != NULL); ASSERT(bp->b_fspriv != NULL);
ASSERT((XFS_BUF_ISERROR(bp)) == 0); ASSERT(!bp->b_error);
if (!(XFS_BUF_ISDONE(bp))) { if (!(XFS_BUF_ISDONE(bp))) {
trace_xfs_trans_read_buf_io(bp, _RET_IP_); trace_xfs_trans_read_buf_io(bp, _RET_IP_);
ASSERT(!XFS_BUF_ISASYNC(bp)); ASSERT(!XFS_BUF_ISASYNC(bp));
...@@ -386,10 +386,9 @@ xfs_trans_read_buf( ...@@ -386,10 +386,9 @@ xfs_trans_read_buf(
return (flags & XBF_TRYLOCK) ? return (flags & XBF_TRYLOCK) ?
0 : XFS_ERROR(ENOMEM); 0 : XFS_ERROR(ENOMEM);
} }
if (XFS_BUF_GETERROR(bp) != 0) { if (bp->b_error) {
XFS_BUF_SUPER_STALE(bp); error = bp->b_error;
error = XFS_BUF_GETERROR(bp); XFS_BUF_SUPER_STALE(bp);
xfs_ioerror_alert("xfs_trans_read_buf", mp, xfs_ioerror_alert("xfs_trans_read_buf", mp,
bp, blkno); bp, blkno);
if (tp->t_flags & XFS_TRANS_DIRTY) if (tp->t_flags & XFS_TRANS_DIRTY)
......
...@@ -83,7 +83,7 @@ xfs_readlink_bmap( ...@@ -83,7 +83,7 @@ xfs_readlink_bmap(
bp = xfs_buf_read(mp->m_ddev_targp, d, BTOBB(byte_cnt), bp = xfs_buf_read(mp->m_ddev_targp, d, BTOBB(byte_cnt),
XBF_LOCK | XBF_MAPPED | XBF_DONT_BLOCK); XBF_LOCK | XBF_MAPPED | XBF_DONT_BLOCK);
error = XFS_BUF_GETERROR(bp); error = xfs_buf_geterror(bp);
if (error) { if (error) {
xfs_ioerror_alert("xfs_readlink", xfs_ioerror_alert("xfs_readlink",
ip->i_mount, bp, XFS_BUF_ADDR(bp)); ip->i_mount, bp, XFS_BUF_ADDR(bp));
...@@ -1648,7 +1648,7 @@ xfs_symlink( ...@@ -1648,7 +1648,7 @@ xfs_symlink(
byte_cnt = XFS_FSB_TO_B(mp, mval[n].br_blockcount); byte_cnt = XFS_FSB_TO_B(mp, mval[n].br_blockcount);
bp = xfs_trans_get_buf(tp, mp->m_ddev_targp, d, bp = xfs_trans_get_buf(tp, mp->m_ddev_targp, d,
BTOBB(byte_cnt), 0); BTOBB(byte_cnt), 0);
ASSERT(bp && !XFS_BUF_GETERROR(bp)); ASSERT(!xfs_buf_geterror(bp));
if (pathlen < byte_cnt) { if (pathlen < byte_cnt) {
byte_cnt = pathlen; byte_cnt = pathlen;
} }
......
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