diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2012-04-13 12:22:00 -0400 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2012-04-13 12:31:37 -0400 |
commit | 3a251f04fe97c3d335b745c98e4b377e3c3899f2 (patch) | |
tree | b5835ebf3639fe4e8bc9d71abbb36891080e777e /fs | |
parent | 6ed3cf2cdfce4c9f1d73171bd3f27d9cb77b734e (diff) |
ocfs2: ->l_next_free_req breakage on big-endian
It's le16, not le32...
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs')
-rw-r--r-- | fs/ocfs2/alloc.c | 2 | ||||
-rw-r--r-- | fs/ocfs2/refcounttree.c | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/fs/ocfs2/alloc.c b/fs/ocfs2/alloc.c index 3165aebb43c8..31b9463fba1f 100644 --- a/fs/ocfs2/alloc.c +++ b/fs/ocfs2/alloc.c | |||
@@ -1134,7 +1134,7 @@ static int ocfs2_adjust_rightmost_branch(handle_t *handle, | |||
1134 | } | 1134 | } |
1135 | 1135 | ||
1136 | el = path_leaf_el(path); | 1136 | el = path_leaf_el(path); |
1137 | rec = &el->l_recs[le32_to_cpu(el->l_next_free_rec) - 1]; | 1137 | rec = &el->l_recs[le16_to_cpu(el->l_next_free_rec) - 1]; |
1138 | 1138 | ||
1139 | ocfs2_adjust_rightmost_records(handle, et, path, rec); | 1139 | ocfs2_adjust_rightmost_records(handle, et, path, rec); |
1140 | 1140 | ||
diff --git a/fs/ocfs2/refcounttree.c b/fs/ocfs2/refcounttree.c index cf7823382664..a7b7217062b7 100644 --- a/fs/ocfs2/refcounttree.c +++ b/fs/ocfs2/refcounttree.c | |||
@@ -1036,14 +1036,14 @@ static int ocfs2_get_refcount_cpos_end(struct ocfs2_caching_info *ci, | |||
1036 | 1036 | ||
1037 | tmp_el = left_path->p_node[subtree_root].el; | 1037 | tmp_el = left_path->p_node[subtree_root].el; |
1038 | blkno = left_path->p_node[subtree_root+1].bh->b_blocknr; | 1038 | blkno = left_path->p_node[subtree_root+1].bh->b_blocknr; |
1039 | for (i = 0; i < le32_to_cpu(tmp_el->l_next_free_rec); i++) { | 1039 | for (i = 0; i < le16_to_cpu(tmp_el->l_next_free_rec); i++) { |
1040 | if (le64_to_cpu(tmp_el->l_recs[i].e_blkno) == blkno) { | 1040 | if (le64_to_cpu(tmp_el->l_recs[i].e_blkno) == blkno) { |
1041 | *cpos_end = le32_to_cpu(tmp_el->l_recs[i+1].e_cpos); | 1041 | *cpos_end = le32_to_cpu(tmp_el->l_recs[i+1].e_cpos); |
1042 | break; | 1042 | break; |
1043 | } | 1043 | } |
1044 | } | 1044 | } |
1045 | 1045 | ||
1046 | BUG_ON(i == le32_to_cpu(tmp_el->l_next_free_rec)); | 1046 | BUG_ON(i == le16_to_cpu(tmp_el->l_next_free_rec)); |
1047 | 1047 | ||
1048 | out: | 1048 | out: |
1049 | ocfs2_free_path(left_path); | 1049 | ocfs2_free_path(left_path); |