diff options
author | Jeff Mahoney <jeffm@suse.com> | 2009-03-30 14:02:18 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-03-30 15:16:35 -0400 |
commit | eba00305591714f1d85ccad1afbf58259c2197b4 (patch) | |
tree | 260912758e76c1add9e917d22a00544812562a75 /fs/reiserfs/do_balan.c | |
parent | 600ed41675d8c384519d8f0b3c76afed39ef2f4b (diff) |
reiserfs: use buffer_info for leaf_paste_entries
This patch makes leaf_paste_entries more consistent with respect to the
other leaf operations. Using buffer_info instead of buffer_head
directly allows us to get a superblock pointer for use in error
handling.
Signed-off-by: Jeff Mahoney <jeffm@suse.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs/reiserfs/do_balan.c')
-rw-r--r-- | fs/reiserfs/do_balan.c | 17 |
1 files changed, 7 insertions, 10 deletions
diff --git a/fs/reiserfs/do_balan.c b/fs/reiserfs/do_balan.c index 2f87f5b14630..99f80538c4bf 100644 --- a/fs/reiserfs/do_balan.c +++ b/fs/reiserfs/do_balan.c | |||
@@ -449,8 +449,7 @@ static int balance_leaf(struct tree_balance *tb, struct item_head *ih, /* item h | |||
449 | /* when we have merge directory item, pos_in_item has been changed too */ | 449 | /* when we have merge directory item, pos_in_item has been changed too */ |
450 | 450 | ||
451 | /* paste new directory entry. 1 is entry number */ | 451 | /* paste new directory entry. 1 is entry number */ |
452 | leaf_paste_entries(bi. | 452 | leaf_paste_entries(&bi, |
453 | bi_bh, | ||
454 | n + | 453 | n + |
455 | item_pos | 454 | item_pos |
456 | - | 455 | - |
@@ -699,7 +698,7 @@ static int balance_leaf(struct tree_balance *tb, struct item_head *ih, /* item h | |||
699 | n + item_pos - | 698 | n + item_pos - |
700 | ret_val); | 699 | ret_val); |
701 | if (is_direntry_le_ih(pasted)) | 700 | if (is_direntry_le_ih(pasted)) |
702 | leaf_paste_entries(bi.bi_bh, | 701 | leaf_paste_entries(&bi, |
703 | n + | 702 | n + |
704 | item_pos - | 703 | item_pos - |
705 | ret_val, | 704 | ret_val, |
@@ -894,8 +893,7 @@ static int balance_leaf(struct tree_balance *tb, struct item_head *ih, /* item h | |||
894 | tb->insert_size[0], | 893 | tb->insert_size[0], |
895 | body, zeros_num); | 894 | body, zeros_num); |
896 | /* paste entry */ | 895 | /* paste entry */ |
897 | leaf_paste_entries(bi. | 896 | leaf_paste_entries(&bi, |
898 | bi_bh, | ||
899 | 0, | 897 | 0, |
900 | paste_entry_position, | 898 | paste_entry_position, |
901 | 1, | 899 | 1, |
@@ -1096,7 +1094,7 @@ static int balance_leaf(struct tree_balance *tb, struct item_head *ih, /* item h | |||
1096 | tb->rnum[0]); | 1094 | tb->rnum[0]); |
1097 | if (is_direntry_le_ih(pasted) | 1095 | if (is_direntry_le_ih(pasted) |
1098 | && pos_in_item >= 0) { | 1096 | && pos_in_item >= 0) { |
1099 | leaf_paste_entries(bi.bi_bh, | 1097 | leaf_paste_entries(&bi, |
1100 | item_pos - | 1098 | item_pos - |
1101 | n + | 1099 | n + |
1102 | tb->rnum[0], | 1100 | tb->rnum[0], |
@@ -1339,8 +1337,7 @@ static int balance_leaf(struct tree_balance *tb, struct item_head *ih, /* item h | |||
1339 | tb->insert_size[0], | 1337 | tb->insert_size[0], |
1340 | body, zeros_num); | 1338 | body, zeros_num); |
1341 | /* paste new directory entry */ | 1339 | /* paste new directory entry */ |
1342 | leaf_paste_entries(bi. | 1340 | leaf_paste_entries(&bi, |
1343 | bi_bh, | ||
1344 | 0, | 1341 | 0, |
1345 | pos_in_item | 1342 | pos_in_item |
1346 | - | 1343 | - |
@@ -1505,7 +1502,7 @@ static int balance_leaf(struct tree_balance *tb, struct item_head *ih, /* item h | |||
1505 | item_pos - n + | 1502 | item_pos - n + |
1506 | snum[i]); | 1503 | snum[i]); |
1507 | if (is_direntry_le_ih(pasted)) { | 1504 | if (is_direntry_le_ih(pasted)) { |
1508 | leaf_paste_entries(bi.bi_bh, | 1505 | leaf_paste_entries(&bi, |
1509 | item_pos - | 1506 | item_pos - |
1510 | n + snum[i], | 1507 | n + snum[i], |
1511 | pos_in_item, | 1508 | pos_in_item, |
@@ -1606,7 +1603,7 @@ static int balance_leaf(struct tree_balance *tb, struct item_head *ih, /* item h | |||
1606 | zeros_num); | 1603 | zeros_num); |
1607 | 1604 | ||
1608 | /* paste entry */ | 1605 | /* paste entry */ |
1609 | leaf_paste_entries(bi.bi_bh, | 1606 | leaf_paste_entries(&bi, |
1610 | item_pos, | 1607 | item_pos, |
1611 | pos_in_item, | 1608 | pos_in_item, |
1612 | 1, | 1609 | 1, |