diff options
author | Mark Fasheh <mark.fasheh@oracle.com> | 2007-01-16 14:32:23 -0500 |
---|---|---|
committer | Mark Fasheh <mark.fasheh@oracle.com> | 2007-04-26 17:44:03 -0400 |
commit | dcd0538ff4e854fa9d7f4630b359ca8fdb5cb5a8 (patch) | |
tree | 226d725f8199907cea2433d1d183b01e51d9bc55 /fs/ocfs2/ocfs2_fs.h | |
parent | 6f16bf655c5795586dd2ac96a7c70e0b9a378746 (diff) |
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/ocfs2_fs.h')
-rw-r--r-- | fs/ocfs2/ocfs2_fs.h | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/fs/ocfs2/ocfs2_fs.h b/fs/ocfs2/ocfs2_fs.h index a476b63e2e60..f0101974f4f9 100644 --- a/fs/ocfs2/ocfs2_fs.h +++ b/fs/ocfs2/ocfs2_fs.h | |||
@@ -86,7 +86,8 @@ | |||
86 | OCFS2_SB(sb)->s_feature_incompat &= ~(mask) | 86 | OCFS2_SB(sb)->s_feature_incompat &= ~(mask) |
87 | 87 | ||
88 | #define OCFS2_FEATURE_COMPAT_SUPP OCFS2_FEATURE_COMPAT_BACKUP_SB | 88 | #define OCFS2_FEATURE_COMPAT_SUPP OCFS2_FEATURE_COMPAT_BACKUP_SB |
89 | #define OCFS2_FEATURE_INCOMPAT_SUPP OCFS2_FEATURE_INCOMPAT_LOCAL_MOUNT | 89 | #define OCFS2_FEATURE_INCOMPAT_SUPP (OCFS2_FEATURE_INCOMPAT_LOCAL_MOUNT \ |
90 | | OCFS2_FEATURE_INCOMPAT_SPARSE_ALLOC) | ||
90 | #define OCFS2_FEATURE_RO_COMPAT_SUPP 0 | 91 | #define OCFS2_FEATURE_RO_COMPAT_SUPP 0 |
91 | 92 | ||
92 | /* | 93 | /* |
@@ -311,7 +312,10 @@ struct ocfs2_extent_list { | |||
311 | /*00*/ __le16 l_tree_depth; /* Extent tree depth from this | 312 | /*00*/ __le16 l_tree_depth; /* Extent tree depth from this |
312 | point. 0 means data extents | 313 | point. 0 means data extents |
313 | hang directly off this | 314 | hang directly off this |
314 | header (a leaf) */ | 315 | header (a leaf) |
316 | NOTE: The high 8 bits cannot be | ||
317 | used - tree_depth is never that big. | ||
318 | */ | ||
315 | __le16 l_count; /* Number of extent records */ | 319 | __le16 l_count; /* Number of extent records */ |
316 | __le16 l_next_free_rec; /* Next unused extent slot */ | 320 | __le16 l_next_free_rec; /* Next unused extent slot */ |
317 | __le16 l_reserved1; | 321 | __le16 l_reserved1; |