diff options
author | Alex Elder <aelder@sgi.com> | 2011-08-08 08:06:24 -0400 |
---|---|---|
committer | Alex Elder <aelder@sgi.com> | 2011-08-08 08:06:24 -0400 |
commit | 2ddb4e94065470828e131351566102274ea9e83f (patch) | |
tree | 3eb237d28e10d7735d57c051880e8173113acef8 /fs/xfs/xfs_bmap.c | |
parent | c35a549c8b9e85bdff7e531a410d10e36b4b4f32 (diff) | |
parent | 322a8b034003c0d46d39af85bf24fee27b902f48 (diff) |
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux
Diffstat (limited to 'fs/xfs/xfs_bmap.c')
-rw-r--r-- | fs/xfs/xfs_bmap.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/fs/xfs/xfs_bmap.c b/fs/xfs/xfs_bmap.c index 25cb2b2c427a..452a291383ab 100644 --- a/fs/xfs/xfs_bmap.c +++ b/fs/xfs/xfs_bmap.c | |||
@@ -414,7 +414,7 @@ xfs_bmap_add_attrfork_local( | |||
414 | 414 | ||
415 | if (ip->i_df.if_bytes <= XFS_IFORK_DSIZE(ip)) | 415 | if (ip->i_df.if_bytes <= XFS_IFORK_DSIZE(ip)) |
416 | return 0; | 416 | return 0; |
417 | if ((ip->i_d.di_mode & S_IFMT) == S_IFDIR) { | 417 | if (S_ISDIR(ip->i_d.di_mode)) { |
418 | mp = ip->i_mount; | 418 | mp = ip->i_mount; |
419 | memset(&dargs, 0, sizeof(dargs)); | 419 | memset(&dargs, 0, sizeof(dargs)); |
420 | dargs.dp = ip; | 420 | dargs.dp = ip; |
@@ -3344,8 +3344,7 @@ xfs_bmap_local_to_extents( | |||
3344 | * We don't want to deal with the case of keeping inode data inline yet. | 3344 | * We don't want to deal with the case of keeping inode data inline yet. |
3345 | * So sending the data fork of a regular inode is invalid. | 3345 | * So sending the data fork of a regular inode is invalid. |
3346 | */ | 3346 | */ |
3347 | ASSERT(!((ip->i_d.di_mode & S_IFMT) == S_IFREG && | 3347 | ASSERT(!(S_ISREG(ip->i_d.di_mode) && whichfork == XFS_DATA_FORK)); |
3348 | whichfork == XFS_DATA_FORK)); | ||
3349 | ifp = XFS_IFORK_PTR(ip, whichfork); | 3348 | ifp = XFS_IFORK_PTR(ip, whichfork); |
3350 | ASSERT(XFS_IFORK_FORMAT(ip, whichfork) == XFS_DINODE_FMT_LOCAL); | 3349 | ASSERT(XFS_IFORK_FORMAT(ip, whichfork) == XFS_DINODE_FMT_LOCAL); |
3351 | flags = 0; | 3350 | flags = 0; |
@@ -4051,7 +4050,7 @@ xfs_bmap_one_block( | |||
4051 | 4050 | ||
4052 | #ifndef DEBUG | 4051 | #ifndef DEBUG |
4053 | if (whichfork == XFS_DATA_FORK) { | 4052 | if (whichfork == XFS_DATA_FORK) { |
4054 | return ((ip->i_d.di_mode & S_IFMT) == S_IFREG) ? | 4053 | return S_ISREG(ip->i_d.di_mode) ? |
4055 | (ip->i_size == ip->i_mount->m_sb.sb_blocksize) : | 4054 | (ip->i_size == ip->i_mount->m_sb.sb_blocksize) : |
4056 | (ip->i_d.di_size == ip->i_mount->m_sb.sb_blocksize); | 4055 | (ip->i_d.di_size == ip->i_mount->m_sb.sb_blocksize); |
4057 | } | 4056 | } |