diff options
| -rw-r--r-- | fs/xfs/xfs_aops.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/xfs/xfs_aops.c b/fs/xfs/xfs_aops.c index a3eeaba156c5..b0cccf8a81a8 100644 --- a/fs/xfs/xfs_aops.c +++ b/fs/xfs/xfs_aops.c | |||
| @@ -399,7 +399,7 @@ xfs_map_blocks( | |||
| 399 | (ip->i_df.if_flags & XFS_IFEXTENTS)); | 399 | (ip->i_df.if_flags & XFS_IFEXTENTS)); |
| 400 | ASSERT(offset <= mp->m_super->s_maxbytes); | 400 | ASSERT(offset <= mp->m_super->s_maxbytes); |
| 401 | 401 | ||
| 402 | if (offset + count > mp->m_super->s_maxbytes) | 402 | if ((xfs_ufsize_t)offset + count > mp->m_super->s_maxbytes) |
| 403 | count = mp->m_super->s_maxbytes - offset; | 403 | count = mp->m_super->s_maxbytes - offset; |
| 404 | end_fsb = XFS_B_TO_FSB(mp, (xfs_ufsize_t)offset + count); | 404 | end_fsb = XFS_B_TO_FSB(mp, (xfs_ufsize_t)offset + count); |
| 405 | offset_fsb = XFS_B_TO_FSBT(mp, offset); | 405 | offset_fsb = XFS_B_TO_FSBT(mp, offset); |
| @@ -1265,7 +1265,7 @@ xfs_map_trim_size( | |||
| 1265 | if (mapping_size > size) | 1265 | if (mapping_size > size) |
| 1266 | mapping_size = size; | 1266 | mapping_size = size; |
| 1267 | if (offset < i_size_read(inode) && | 1267 | if (offset < i_size_read(inode) && |
| 1268 | offset + mapping_size >= i_size_read(inode)) { | 1268 | (xfs_ufsize_t)offset + mapping_size >= i_size_read(inode)) { |
| 1269 | /* limit mapping to block that spans EOF */ | 1269 | /* limit mapping to block that spans EOF */ |
| 1270 | mapping_size = roundup_64(i_size_read(inode) - offset, | 1270 | mapping_size = roundup_64(i_size_read(inode) - offset, |
| 1271 | i_blocksize(inode)); | 1271 | i_blocksize(inode)); |
| @@ -1312,7 +1312,7 @@ xfs_get_blocks( | |||
| 1312 | lockmode = xfs_ilock_data_map_shared(ip); | 1312 | lockmode = xfs_ilock_data_map_shared(ip); |
| 1313 | 1313 | ||
| 1314 | ASSERT(offset <= mp->m_super->s_maxbytes); | 1314 | ASSERT(offset <= mp->m_super->s_maxbytes); |
| 1315 | if (offset + size > mp->m_super->s_maxbytes) | 1315 | if ((xfs_ufsize_t)offset + size > mp->m_super->s_maxbytes) |
| 1316 | size = mp->m_super->s_maxbytes - offset; | 1316 | size = mp->m_super->s_maxbytes - offset; |
| 1317 | end_fsb = XFS_B_TO_FSB(mp, (xfs_ufsize_t)offset + size); | 1317 | end_fsb = XFS_B_TO_FSB(mp, (xfs_ufsize_t)offset + size); |
| 1318 | offset_fsb = XFS_B_TO_FSBT(mp, offset); | 1318 | offset_fsb = XFS_B_TO_FSBT(mp, offset); |
