diff options
author | Joel Becker <joel.becker@oracle.com> | 2009-02-13 06:12:33 -0500 |
---|---|---|
committer | Joel Becker <joel.becker@oracle.com> | 2009-09-04 19:08:07 -0400 |
commit | 1ef61b33148a6b32b6d28383cd72ceeddfc7054d (patch) | |
tree | 8e0c3e6131fc72847f37f1ac963b7ba7efe9be3c | |
parent | a29702914ad36443d83b5250b3bfa1bf91e6b239 (diff) |
ocfs2: Remove inode from ocfs2_figure_extent_contig().
It already has an ocfs2_extent_tree and doesn't need the inode.
Signed-off-by: Joel Becker <joel.becker@oracle.com>
-rw-r--r-- | fs/ocfs2/alloc.c | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/fs/ocfs2/alloc.c b/fs/ocfs2/alloc.c index 9b79150e478f..38b1fea9af67 100644 --- a/fs/ocfs2/alloc.c +++ b/fs/ocfs2/alloc.c | |||
@@ -4437,11 +4437,10 @@ out: | |||
4437 | return ret; | 4437 | return ret; |
4438 | } | 4438 | } |
4439 | 4439 | ||
4440 | static void ocfs2_figure_contig_type(struct inode *inode, | 4440 | static void ocfs2_figure_contig_type(struct ocfs2_extent_tree *et, |
4441 | struct ocfs2_insert_type *insert, | 4441 | struct ocfs2_insert_type *insert, |
4442 | struct ocfs2_extent_list *el, | 4442 | struct ocfs2_extent_list *el, |
4443 | struct ocfs2_extent_rec *insert_rec, | 4443 | struct ocfs2_extent_rec *insert_rec) |
4444 | struct ocfs2_extent_tree *et) | ||
4445 | { | 4444 | { |
4446 | int i; | 4445 | int i; |
4447 | enum ocfs2_contig_type contig_type = CONTIG_NONE; | 4446 | enum ocfs2_contig_type contig_type = CONTIG_NONE; |
@@ -4449,8 +4448,8 @@ static void ocfs2_figure_contig_type(struct inode *inode, | |||
4449 | BUG_ON(le16_to_cpu(el->l_tree_depth) != 0); | 4448 | BUG_ON(le16_to_cpu(el->l_tree_depth) != 0); |
4450 | 4449 | ||
4451 | for(i = 0; i < le16_to_cpu(el->l_next_free_rec); i++) { | 4450 | for(i = 0; i < le16_to_cpu(el->l_next_free_rec); i++) { |
4452 | contig_type = ocfs2_extent_contig(inode->i_sb, &el->l_recs[i], | 4451 | contig_type = ocfs2_extent_contig(ocfs2_metadata_cache_get_super(et->et_ci), |
4453 | insert_rec); | 4452 | &el->l_recs[i], insert_rec); |
4454 | if (contig_type != CONTIG_NONE) { | 4453 | if (contig_type != CONTIG_NONE) { |
4455 | insert->ins_contig_index = i; | 4454 | insert->ins_contig_index = i; |
4456 | break; | 4455 | break; |
@@ -4579,7 +4578,7 @@ static int ocfs2_figure_insert_type(struct inode *inode, | |||
4579 | le16_to_cpu(el->l_next_free_rec); | 4578 | le16_to_cpu(el->l_next_free_rec); |
4580 | 4579 | ||
4581 | if (!insert->ins_tree_depth) { | 4580 | if (!insert->ins_tree_depth) { |
4582 | ocfs2_figure_contig_type(inode, insert, el, insert_rec, et); | 4581 | ocfs2_figure_contig_type(et, insert, el, insert_rec); |
4583 | ocfs2_figure_appending_type(insert, el, insert_rec); | 4582 | ocfs2_figure_appending_type(insert, el, insert_rec); |
4584 | return 0; | 4583 | return 0; |
4585 | } | 4584 | } |
@@ -4613,7 +4612,7 @@ static int ocfs2_figure_insert_type(struct inode *inode, | |||
4613 | * into two types of appends: simple record append, or a | 4612 | * into two types of appends: simple record append, or a |
4614 | * rotate inside the tail leaf. | 4613 | * rotate inside the tail leaf. |
4615 | */ | 4614 | */ |
4616 | ocfs2_figure_contig_type(inode, insert, el, insert_rec, et); | 4615 | ocfs2_figure_contig_type(et, insert, el, insert_rec); |
4617 | 4616 | ||
4618 | /* | 4617 | /* |
4619 | * The insert code isn't quite ready to deal with all cases of | 4618 | * The insert code isn't quite ready to deal with all cases of |