aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs/xfs_rtalloc.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/xfs/xfs_rtalloc.c')
-rw-r--r--fs/xfs/xfs_rtalloc.c29
1 files changed, 14 insertions, 15 deletions
diff --git a/fs/xfs/xfs_rtalloc.c b/fs/xfs/xfs_rtalloc.c
index 06fc061c50fc..5b413946b1c5 100644
--- a/fs/xfs/xfs_rtalloc.c
+++ b/fs/xfs/xfs_rtalloc.c
@@ -130,7 +130,8 @@ xfs_growfs_rt_alloc(
130 /* 130 /*
131 * Lock the inode. 131 * Lock the inode.
132 */ 132 */
133 if ((error = xfs_trans_iget(mp, tp, ino, 0, XFS_ILOCK_EXCL, &ip))) 133 if ((error = xfs_trans_iget(mp, tp, ino, 0,
134 XFS_ILOCK_EXCL, &ip)))
134 goto error_exit; 135 goto error_exit;
135 XFS_BMAP_INIT(&flist, &firstblock); 136 XFS_BMAP_INIT(&flist, &firstblock);
136 /* 137 /*
@@ -170,8 +171,8 @@ xfs_growfs_rt_alloc(
170 /* 171 /*
171 * Lock the bitmap inode. 172 * Lock the bitmap inode.
172 */ 173 */
173 if ((error = xfs_trans_iget(mp, tp, ino, 0, XFS_ILOCK_EXCL, 174 if ((error = xfs_trans_iget(mp, tp, ino, 0,
174 &ip))) 175 XFS_ILOCK_EXCL, &ip)))
175 goto error_exit; 176 goto error_exit;
176 /* 177 /*
177 * Get a buffer for the block. 178 * Get a buffer for the block.
@@ -2023,8 +2024,8 @@ xfs_growfs_rt(
2023 /* 2024 /*
2024 * Lock out other callers by grabbing the bitmap inode lock. 2025 * Lock out other callers by grabbing the bitmap inode lock.
2025 */ 2026 */
2026 if ((error = xfs_trans_iget(mp, tp, 0, mp->m_sb.sb_rbmino, 2027 if ((error = xfs_trans_iget(mp, tp, mp->m_sb.sb_rbmino, 0,
2027 XFS_ILOCK_EXCL, &ip))) 2028 XFS_ILOCK_EXCL, &ip)))
2028 goto error_exit; 2029 goto error_exit;
2029 ASSERT(ip == mp->m_rbmip); 2030 ASSERT(ip == mp->m_rbmip);
2030 /* 2031 /*
@@ -2037,8 +2038,8 @@ xfs_growfs_rt(
2037 /* 2038 /*
2038 * Get the summary inode into the transaction. 2039 * Get the summary inode into the transaction.
2039 */ 2040 */
2040 if ((error = xfs_trans_iget(mp, tp, mp->m_sb.sb_rsumino, 2041 if ((error = xfs_trans_iget(mp, tp, mp->m_sb.sb_rsumino, 0,
2041 0, XFS_ILOCK_EXCL, &ip))) 2042 XFS_ILOCK_EXCL, &ip)))
2042 goto error_exit; 2043 goto error_exit;
2043 ASSERT(ip == mp->m_rsumip); 2044 ASSERT(ip == mp->m_rsumip);
2044 /* 2045 /*
@@ -2158,10 +2159,9 @@ xfs_rtallocate_extent(
2158 /* 2159 /*
2159 * Lock out other callers by grabbing the bitmap inode lock. 2160 * Lock out other callers by grabbing the bitmap inode lock.
2160 */ 2161 */
2161 error = xfs_trans_iget(mp, tp, mp->m_sb.sb_rbmino, 0, XFS_ILOCK_EXCL, &ip); 2162 if ((error = xfs_trans_iget(mp, tp, mp->m_sb.sb_rbmino, 0,
2162 if (error) { 2163 XFS_ILOCK_EXCL, &ip)))
2163 return error; 2164 return error;
2164 }
2165 sumbp = NULL; 2165 sumbp = NULL;
2166 /* 2166 /*
2167 * Allocate by size, or near another block, or exactly at some block. 2167 * Allocate by size, or near another block, or exactly at some block.
@@ -2221,10 +2221,9 @@ xfs_rtfree_extent(
2221 /* 2221 /*
2222 * Synchronize by locking the bitmap inode. 2222 * Synchronize by locking the bitmap inode.
2223 */ 2223 */
2224 error = xfs_trans_iget(mp, tp, mp->m_sb.sb_rbmino, 0, XFS_ILOCK_EXCL, &ip); 2224 if ((error = xfs_trans_iget(mp, tp, mp->m_sb.sb_rbmino, 0,
2225 if (error) { 2225 XFS_ILOCK_EXCL, &ip)))
2226 return error; 2226 return error;
2227 }
2228#if defined(__KERNEL__) && defined(DEBUG) 2227#if defined(__KERNEL__) && defined(DEBUG)
2229 /* 2228 /*
2230 * Check to see that this whole range is currently allocated. 2229 * Check to see that this whole range is currently allocated.
@@ -2365,8 +2364,8 @@ xfs_rtpick_extent(
2365 __uint64_t seq; /* sequence number of file creation */ 2364 __uint64_t seq; /* sequence number of file creation */
2366 __uint64_t *seqp; /* pointer to seqno in inode */ 2365 __uint64_t *seqp; /* pointer to seqno in inode */
2367 2366
2368 error = xfs_trans_iget(mp, tp, mp->m_sb.sb_rbmino, 0, XFS_ILOCK_EXCL, &ip); 2367 if ((error = xfs_trans_iget(mp, tp, mp->m_sb.sb_rbmino, 0,
2369 if (error) 2368 XFS_ILOCK_EXCL, &ip)))
2370 return error; 2369 return error;
2371 ASSERT(ip == mp->m_rbmip); 2370 ASSERT(ip == mp->m_rbmip);
2372 seqp = (__uint64_t *)&ip->i_d.di_atime; 2371 seqp = (__uint64_t *)&ip->i_d.di_atime;