diff options
author | Paulo Alcantara <pcacjr@zytor.com> | 2012-09-02 19:29:05 -0300 |
---|---|---|
committer | Paulo Alcantara <pcacjr@zytor.com> | 2012-09-02 19:29:05 -0300 |
commit | 76db6d47b5262b4e0ba0ce4175a0a0cedf4513b3 (patch) | |
tree | d90fca89a75e6cd520a850ac748ee52431f83b5e | |
parent | 65e257cafb44a8ec60ff171cfe4560a9106a15ec (diff) | |
download | syslinux-76db6d47b5262b4e0ba0ce4175a0a0cedf4513b3.tar.gz syslinux-76db6d47b5262b4e0ba0ce4175a0a0cedf4513b3.tar.xz syslinux-76db6d47b5262b4e0ba0ce4175a0a0cedf4513b3.zip |
xfs: Cleanup and remove some trailing whitespaces
This patch cleanups and removes some trailing whitespaces introduced in
the previous commit.
Signed-off-by: Paulo Alcantara <pcacjr@zytor.com>
-rw-r--r-- | core/fs/xfs/xfs.c | 16 | ||||
-rw-r--r-- | core/fs/xfs/xfs.h | 1 |
2 files changed, 9 insertions, 8 deletions
diff --git a/core/fs/xfs/xfs.c b/core/fs/xfs/xfs.c index 33a229af..8dfdf137 100644 --- a/core/fs/xfs/xfs.c +++ b/core/fs/xfs/xfs.c @@ -106,8 +106,6 @@ static int xfs_next_extent(struct inode *inode, uint32_t lstart) (void)lstart; - xfs_debug("in"); - core = xfs_dinode_get_core(fs, inode->ino); if (!core) { xfs_error("Failed to get dinode from disk (ino %llx)", inode->ino); @@ -142,6 +140,7 @@ static int xfs_next_extent(struct inode *inode, uint32_t lstart) blk = (xfs_btree_block_t *)get_cache(fs->fs_dev, bno); if (be16_to_cpu(blk->bb_level) == 0) break; + pp = XFS_BMBT_PTR_ADDR(fs, blk, 1, xfs_bmdr_maxrecs(XFS_INFO(fs)->blocksize, 0)); bno = fsblock_to_bytes(fs, be64_to_cpu(pp[0])) >> BLOCK_SHIFT(fs); @@ -154,19 +153,20 @@ static int xfs_next_extent(struct inode *inode, uint32_t lstart) if (nextents - index > 0) { bmbt_irec_get(&rec, XFS_BMDR_REC_ADDR(blk, index + 1)); - bno = fsblock_to_bytes(fs, rec.br_startblock) - >> BLOCK_SHIFT(fs); + bno = fsblock_to_bytes(fs, rec.br_startblock) + >> BLOCK_SHIFT(fs); XFS_PVT(inode)->i_offset = rec.br_startoff; - inode->next_extent.pstart = bno << BLOCK_SHIFT(fs) + inode->next_extent.pstart = bno << BLOCK_SHIFT(fs) >> SECTOR_SHIFT(fs); - inode->next_extent.len = ((rec.br_blockcount - << BLOCK_SHIFT(fs)) - + SECTOR_SIZE(fs) - 1) + inode->next_extent.len = ((rec.br_blockcount + << BLOCK_SHIFT(fs)) + + SECTOR_SIZE(fs) - 1) >> SECTOR_SHIFT(fs); break; } + index -= nextents; bno = fsblock_to_bytes(fs, nextbno) >> BLOCK_SHIFT(fs); blk = (xfs_btree_block_t *)get_cache(fs->fs_dev, bno); diff --git a/core/fs/xfs/xfs.h b/core/fs/xfs/xfs.h index 96bfbdb8..0043cec3 100644 --- a/core/fs/xfs/xfs.h +++ b/core/fs/xfs/xfs.h @@ -744,6 +744,7 @@ xfs_bmdr_maxrecs(int blocklen, int leaf) if (leaf) return blocklen / sizeof(xfs_bmdr_rec_t); + return blocklen / (sizeof(xfs_bmdr_key_t) + sizeof(xfs_bmdr_ptr_t)); } |