diff options
Diffstat (limited to 'fs/xfs/xfs_inode.c')
-rw-r--r-- | fs/xfs/xfs_inode.c | 25 |
1 files changed, 2 insertions, 23 deletions
diff --git a/fs/xfs/xfs_inode.c b/fs/xfs/xfs_inode.c index 0fa987dea242..acd846d808b2 100644 --- a/fs/xfs/xfs_inode.c +++ b/fs/xfs/xfs_inode.c | |||
@@ -2347,11 +2347,11 @@ cluster_corrupt_out: | |||
2347 | */ | 2347 | */ |
2348 | rcu_read_unlock(); | 2348 | rcu_read_unlock(); |
2349 | /* | 2349 | /* |
2350 | * Clean up the buffer. If it was B_DELWRI, just release it -- | 2350 | * Clean up the buffer. If it was delwri, just release it -- |
2351 | * brelse can handle it with no problems. If not, shut down the | 2351 | * brelse can handle it with no problems. If not, shut down the |
2352 | * filesystem before releasing the buffer. | 2352 | * filesystem before releasing the buffer. |
2353 | */ | 2353 | */ |
2354 | bufwasdelwri = XFS_BUF_ISDELAYWRITE(bp); | 2354 | bufwasdelwri = (bp->b_flags & _XBF_DELWRI_Q); |
2355 | if (bufwasdelwri) | 2355 | if (bufwasdelwri) |
2356 | xfs_buf_relse(bp); | 2356 | xfs_buf_relse(bp); |
2357 | 2357 | ||
@@ -2685,27 +2685,6 @@ corrupt_out: | |||
2685 | return XFS_ERROR(EFSCORRUPTED); | 2685 | return XFS_ERROR(EFSCORRUPTED); |
2686 | } | 2686 | } |
2687 | 2687 | ||
2688 | void | ||
2689 | xfs_promote_inode( | ||
2690 | struct xfs_inode *ip) | ||
2691 | { | ||
2692 | struct xfs_buf *bp; | ||
2693 | |||
2694 | ASSERT(xfs_isilocked(ip, XFS_ILOCK_EXCL|XFS_ILOCK_SHARED)); | ||
2695 | |||
2696 | bp = xfs_incore(ip->i_mount->m_ddev_targp, ip->i_imap.im_blkno, | ||
2697 | ip->i_imap.im_len, XBF_TRYLOCK); | ||
2698 | if (!bp) | ||
2699 | return; | ||
2700 | |||
2701 | if (XFS_BUF_ISDELAYWRITE(bp)) { | ||
2702 | xfs_buf_delwri_promote(bp); | ||
2703 | wake_up_process(ip->i_mount->m_ddev_targp->bt_task); | ||
2704 | } | ||
2705 | |||
2706 | xfs_buf_relse(bp); | ||
2707 | } | ||
2708 | |||
2709 | /* | 2688 | /* |
2710 | * Return a pointer to the extent record at file index idx. | 2689 | * Return a pointer to the extent record at file index idx. |
2711 | */ | 2690 | */ |