diff options
author | Christoph Hellwig <hch@infradead.org> | 2010-01-19 04:56:44 -0500 |
---|---|---|
committer | Alex Elder <aelder@sgi.com> | 2010-01-21 14:44:36 -0500 |
commit | 0cadda1c5f194f98a05d252ff4385d86d2ed0862 (patch) | |
tree | a299a7a976f1478f9024f1d3aff9a2351a8397fe /fs/xfs/xfs_inode.c | |
parent | a210c1aa7f6c90b729cc3a72d03e789b13cb6c47 (diff) |
xfs: remove duplicate buffer flags
Currently we define aliases for the buffer flags in various
namespaces, which only adds confusion. Remove all but the XBF_
flags to clean this up a bit.
Note that we still abuse XFS_B_ASYNC/XBF_ASYNC for some non-buffer
uses, but I'll clean that up later.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Dave Chinner <david@fromorbit.com>
Signed-off-by: Alex Elder <aelder@sgi.com>
Diffstat (limited to 'fs/xfs/xfs_inode.c')
-rw-r--r-- | fs/xfs/xfs_inode.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/fs/xfs/xfs_inode.c b/fs/xfs/xfs_inode.c index 0317b000ab44..bbb3bee8e936 100644 --- a/fs/xfs/xfs_inode.c +++ b/fs/xfs/xfs_inode.c | |||
@@ -151,7 +151,7 @@ xfs_imap_to_bp( | |||
151 | "an error %d on %s. Returning error.", | 151 | "an error %d on %s. Returning error.", |
152 | error, mp->m_fsname); | 152 | error, mp->m_fsname); |
153 | } else { | 153 | } else { |
154 | ASSERT(buf_flags & XFS_BUF_TRYLOCK); | 154 | ASSERT(buf_flags & XBF_TRYLOCK); |
155 | } | 155 | } |
156 | return error; | 156 | return error; |
157 | } | 157 | } |
@@ -239,7 +239,7 @@ xfs_inotobp( | |||
239 | if (error) | 239 | if (error) |
240 | return error; | 240 | return error; |
241 | 241 | ||
242 | error = xfs_imap_to_bp(mp, tp, &imap, &bp, XFS_BUF_LOCK, imap_flags); | 242 | error = xfs_imap_to_bp(mp, tp, &imap, &bp, XBF_LOCK, imap_flags); |
243 | if (error) | 243 | if (error) |
244 | return error; | 244 | return error; |
245 | 245 | ||
@@ -285,7 +285,7 @@ xfs_itobp( | |||
285 | return error; | 285 | return error; |
286 | 286 | ||
287 | if (!bp) { | 287 | if (!bp) { |
288 | ASSERT(buf_flags & XFS_BUF_TRYLOCK); | 288 | ASSERT(buf_flags & XBF_TRYLOCK); |
289 | ASSERT(tp == NULL); | 289 | ASSERT(tp == NULL); |
290 | *bpp = NULL; | 290 | *bpp = NULL; |
291 | return EAGAIN; | 291 | return EAGAIN; |
@@ -807,7 +807,7 @@ xfs_iread( | |||
807 | * Get pointers to the on-disk inode and the buffer containing it. | 807 | * Get pointers to the on-disk inode and the buffer containing it. |
808 | */ | 808 | */ |
809 | error = xfs_imap_to_bp(mp, tp, &ip->i_imap, &bp, | 809 | error = xfs_imap_to_bp(mp, tp, &ip->i_imap, &bp, |
810 | XFS_BUF_LOCK, iget_flags); | 810 | XBF_LOCK, iget_flags); |
811 | if (error) | 811 | if (error) |
812 | return error; | 812 | return error; |
813 | dip = (xfs_dinode_t *)xfs_buf_offset(bp, ip->i_imap.im_boffset); | 813 | dip = (xfs_dinode_t *)xfs_buf_offset(bp, ip->i_imap.im_boffset); |
@@ -1751,7 +1751,7 @@ xfs_iunlink( | |||
1751 | * Here we put the head pointer into our next pointer, | 1751 | * Here we put the head pointer into our next pointer, |
1752 | * and then we fall through to point the head at us. | 1752 | * and then we fall through to point the head at us. |
1753 | */ | 1753 | */ |
1754 | error = xfs_itobp(mp, tp, ip, &dip, &ibp, XFS_BUF_LOCK); | 1754 | error = xfs_itobp(mp, tp, ip, &dip, &ibp, XBF_LOCK); |
1755 | if (error) | 1755 | if (error) |
1756 | return error; | 1756 | return error; |
1757 | 1757 | ||
@@ -1833,7 +1833,7 @@ xfs_iunlink_remove( | |||
1833 | * of dealing with the buffer when there is no need to | 1833 | * of dealing with the buffer when there is no need to |
1834 | * change it. | 1834 | * change it. |
1835 | */ | 1835 | */ |
1836 | error = xfs_itobp(mp, tp, ip, &dip, &ibp, XFS_BUF_LOCK); | 1836 | error = xfs_itobp(mp, tp, ip, &dip, &ibp, XBF_LOCK); |
1837 | if (error) { | 1837 | if (error) { |
1838 | cmn_err(CE_WARN, | 1838 | cmn_err(CE_WARN, |
1839 | "xfs_iunlink_remove: xfs_itobp() returned an error %d on %s. Returning error.", | 1839 | "xfs_iunlink_remove: xfs_itobp() returned an error %d on %s. Returning error.", |
@@ -1895,7 +1895,7 @@ xfs_iunlink_remove( | |||
1895 | * Now last_ibp points to the buffer previous to us on | 1895 | * Now last_ibp points to the buffer previous to us on |
1896 | * the unlinked list. Pull us from the list. | 1896 | * the unlinked list. Pull us from the list. |
1897 | */ | 1897 | */ |
1898 | error = xfs_itobp(mp, tp, ip, &dip, &ibp, XFS_BUF_LOCK); | 1898 | error = xfs_itobp(mp, tp, ip, &dip, &ibp, XBF_LOCK); |
1899 | if (error) { | 1899 | if (error) { |
1900 | cmn_err(CE_WARN, | 1900 | cmn_err(CE_WARN, |
1901 | "xfs_iunlink_remove: xfs_itobp() returned an error %d on %s. Returning error.", | 1901 | "xfs_iunlink_remove: xfs_itobp() returned an error %d on %s. Returning error.", |
@@ -2040,7 +2040,7 @@ xfs_ifree_cluster( | |||
2040 | 2040 | ||
2041 | bp = xfs_trans_get_buf(tp, mp->m_ddev_targp, blkno, | 2041 | bp = xfs_trans_get_buf(tp, mp->m_ddev_targp, blkno, |
2042 | mp->m_bsize * blks_per_cluster, | 2042 | mp->m_bsize * blks_per_cluster, |
2043 | XFS_BUF_LOCK); | 2043 | XBF_LOCK); |
2044 | 2044 | ||
2045 | pre_flushed = 0; | 2045 | pre_flushed = 0; |
2046 | lip = XFS_BUF_FSPRIVATE(bp, xfs_log_item_t *); | 2046 | lip = XFS_BUF_FSPRIVATE(bp, xfs_log_item_t *); |
@@ -2151,7 +2151,7 @@ xfs_ifree( | |||
2151 | 2151 | ||
2152 | xfs_trans_log_inode(tp, ip, XFS_ILOG_CORE); | 2152 | xfs_trans_log_inode(tp, ip, XFS_ILOG_CORE); |
2153 | 2153 | ||
2154 | error = xfs_itobp(ip->i_mount, tp, ip, &dip, &ibp, XFS_BUF_LOCK); | 2154 | error = xfs_itobp(ip->i_mount, tp, ip, &dip, &ibp, XBF_LOCK); |
2155 | if (error) | 2155 | if (error) |
2156 | return error; | 2156 | return error; |
2157 | 2157 | ||
@@ -2952,7 +2952,7 @@ xfs_iflush( | |||
2952 | * Get the buffer containing the on-disk inode. | 2952 | * Get the buffer containing the on-disk inode. |
2953 | */ | 2953 | */ |
2954 | error = xfs_itobp(mp, NULL, ip, &dip, &bp, | 2954 | error = xfs_itobp(mp, NULL, ip, &dip, &bp, |
2955 | noblock ? XFS_BUF_TRYLOCK : XFS_BUF_LOCK); | 2955 | noblock ? XBF_TRYLOCK : XBF_LOCK); |
2956 | if (error || !bp) { | 2956 | if (error || !bp) { |
2957 | xfs_ifunlock(ip); | 2957 | xfs_ifunlock(ip); |
2958 | return error; | 2958 | return error; |