aboutsummaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorJoel Becker <joel.becker@oracle.com>2009-02-13 06:07:09 -0500
committerJoel Becker <joel.becker@oracle.com>2009-09-04 19:08:05 -0400
commitb4a176515c715f0c6db1759a39cd9c4175e5a23a (patch)
treee929ed1a0acb1c16755d8584f11e186cf35bc1b4 /fs
parent3505bec01829a8f690259517add55c7941a4d3d5 (diff)
ocfs2: ocfs2_extent_contig() only requires the superblock.
Don't pass the inode in. We don't want it around for generic btree operations. Signed-off-by: Joel Becker <joel.becker@oracle.com>
Diffstat (limited to 'fs')
-rw-r--r--fs/ocfs2/alloc.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/fs/ocfs2/alloc.c b/fs/ocfs2/alloc.c
index cced1766a9ea..2431bbba6cd8 100644
--- a/fs/ocfs2/alloc.c
+++ b/fs/ocfs2/alloc.c
@@ -747,7 +747,7 @@ static int ocfs2_extents_adjacent(struct ocfs2_extent_rec *left,
747} 747}
748 748
749static enum ocfs2_contig_type 749static enum ocfs2_contig_type
750 ocfs2_extent_contig(struct inode *inode, 750 ocfs2_extent_contig(struct super_block *sb,
751 struct ocfs2_extent_rec *ext, 751 struct ocfs2_extent_rec *ext,
752 struct ocfs2_extent_rec *insert_rec) 752 struct ocfs2_extent_rec *insert_rec)
753{ 753{
@@ -762,12 +762,12 @@ static enum ocfs2_contig_type
762 return CONTIG_NONE; 762 return CONTIG_NONE;
763 763
764 if (ocfs2_extents_adjacent(ext, insert_rec) && 764 if (ocfs2_extents_adjacent(ext, insert_rec) &&
765 ocfs2_block_extent_contig(inode->i_sb, ext, blkno)) 765 ocfs2_block_extent_contig(sb, ext, blkno))
766 return CONTIG_RIGHT; 766 return CONTIG_RIGHT;
767 767
768 blkno = le64_to_cpu(ext->e_blkno); 768 blkno = le64_to_cpu(ext->e_blkno);
769 if (ocfs2_extents_adjacent(insert_rec, ext) && 769 if (ocfs2_extents_adjacent(insert_rec, ext) &&
770 ocfs2_block_extent_contig(inode->i_sb, insert_rec, blkno)) 770 ocfs2_block_extent_contig(sb, insert_rec, blkno))
771 return CONTIG_LEFT; 771 return CONTIG_LEFT;
772 772
773 return CONTIG_NONE; 773 return CONTIG_NONE;
@@ -4374,7 +4374,7 @@ ocfs2_figure_merge_contig_type(struct inode *inode, struct ocfs2_path *path,
4374 if (split_rec->e_cpos == el->l_recs[index].e_cpos) 4374 if (split_rec->e_cpos == el->l_recs[index].e_cpos)
4375 ret = CONTIG_RIGHT; 4375 ret = CONTIG_RIGHT;
4376 } else { 4376 } else {
4377 ret = ocfs2_extent_contig(inode, rec, split_rec); 4377 ret = ocfs2_extent_contig(inode->i_sb, rec, split_rec);
4378 } 4378 }
4379 } 4379 }
4380 4380
@@ -4420,7 +4420,7 @@ ocfs2_figure_merge_contig_type(struct inode *inode, struct ocfs2_path *path,
4420 if (rec) { 4420 if (rec) {
4421 enum ocfs2_contig_type contig_type; 4421 enum ocfs2_contig_type contig_type;
4422 4422
4423 contig_type = ocfs2_extent_contig(inode, rec, split_rec); 4423 contig_type = ocfs2_extent_contig(inode->i_sb, rec, split_rec);
4424 4424
4425 if (contig_type == CONTIG_LEFT && ret == CONTIG_RIGHT) 4425 if (contig_type == CONTIG_LEFT && ret == CONTIG_RIGHT)
4426 ret = CONTIG_LEFTRIGHT; 4426 ret = CONTIG_LEFTRIGHT;
@@ -4449,7 +4449,7 @@ static void ocfs2_figure_contig_type(struct inode *inode,
4449 BUG_ON(le16_to_cpu(el->l_tree_depth) != 0); 4449 BUG_ON(le16_to_cpu(el->l_tree_depth) != 0);
4450 4450
4451 for(i = 0; i < le16_to_cpu(el->l_next_free_rec); i++) { 4451 for(i = 0; i < le16_to_cpu(el->l_next_free_rec); i++) {
4452 contig_type = ocfs2_extent_contig(inode, &el->l_recs[i], 4452 contig_type = ocfs2_extent_contig(inode->i_sb, &el->l_recs[i],
4453 insert_rec); 4453 insert_rec);
4454 if (contig_type != CONTIG_NONE) { 4454 if (contig_type != CONTIG_NONE) {
4455 insert->ins_contig_index = i; 4455 insert->ins_contig_index = i;