diff options
author | Mark Fasheh <mark.fasheh@oracle.com> | 2007-01-16 19:32:23 (GMT) |
---|---|---|
committer | Mark Fasheh <mark.fasheh@oracle.com> | 2007-04-26 21:44:03 (GMT) |
commit | dcd0538ff4e854fa9d7f4630b359ca8fdb5cb5a8 (patch) | |
tree | 226d725f8199907cea2433d1d183b01e51d9bc55 /fs/ocfs2/dir.c | |
parent | 6f16bf655c5795586dd2ac96a7c70e0b9a378746 (diff) | |
download | linux-dcd0538ff4e854fa9d7f4630b359ca8fdb5cb5a8.tar.xz |
ocfs2: sparse b-tree support
Introduce tree rotations into the b-tree code. This will allow ocfs2 to
support sparse files. Much of the added code is designed to be generic (in
the ocfs2 sense) so that it can later be re-used to implement large
extended attributes.
This patch only adds the rotation code and does minimal updates to callers
of the extent api.
Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
Diffstat (limited to 'fs/ocfs2/dir.c')
-rw-r--r-- | fs/ocfs2/dir.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/fs/ocfs2/dir.c b/fs/ocfs2/dir.c index 66821e1..5d211c5 100644 --- a/fs/ocfs2/dir.c +++ b/fs/ocfs2/dir.c @@ -365,8 +365,10 @@ int ocfs2_do_extend_dir(struct super_block *sb, spin_unlock(&OCFS2_I(dir)->ip_lock); if (extend) { - status = ocfs2_do_extend_allocation(OCFS2_SB(sb), dir, 1, - parent_fe_bh, handle, + u32 offset = OCFS2_I(dir)->ip_clusters; + + status = ocfs2_do_extend_allocation(OCFS2_SB(sb), dir, &offset, + 1, parent_fe_bh, handle, data_ac, meta_ac, NULL); BUG_ON(status == -EAGAIN); if (status < 0) { |