diff options
Diffstat (limited to 'fs/ocfs2/ocfs2.h')
-rw-r--r-- | fs/ocfs2/ocfs2.h | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/fs/ocfs2/ocfs2.h b/fs/ocfs2/ocfs2.h index a7c8369c402f..3749c32c2fc4 100644 --- a/fs/ocfs2/ocfs2.h +++ b/fs/ocfs2/ocfs2.h | |||
@@ -340,6 +340,9 @@ struct ocfs2_super | |||
340 | 340 | ||
341 | /* used to protect metaecc calculation check of xattr. */ | 341 | /* used to protect metaecc calculation check of xattr. */ |
342 | spinlock_t osb_xattr_lock; | 342 | spinlock_t osb_xattr_lock; |
343 | |||
344 | unsigned int osb_dx_mask; | ||
345 | u32 osb_dx_seed[4]; | ||
343 | }; | 346 | }; |
344 | 347 | ||
345 | #define OCFS2_SB(sb) ((struct ocfs2_super *)(sb)->s_fs_info) | 348 | #define OCFS2_SB(sb) ((struct ocfs2_super *)(sb)->s_fs_info) |
@@ -398,6 +401,13 @@ static inline int ocfs2_meta_ecc(struct ocfs2_super *osb) | |||
398 | return 0; | 401 | return 0; |
399 | } | 402 | } |
400 | 403 | ||
404 | static inline int ocfs2_supports_indexed_dirs(struct ocfs2_super *osb) | ||
405 | { | ||
406 | if (osb->s_feature_incompat & OCFS2_FEATURE_INCOMPAT_INDEXED_DIRS) | ||
407 | return 1; | ||
408 | return 0; | ||
409 | } | ||
410 | |||
401 | /* set / clear functions because cluster events can make these happen | 411 | /* set / clear functions because cluster events can make these happen |
402 | * in parallel so we want the transitions to be atomic. this also | 412 | * in parallel so we want the transitions to be atomic. this also |
403 | * means that any future flags osb_flags must be protected by spinlock | 413 | * means that any future flags osb_flags must be protected by spinlock |
@@ -478,6 +488,12 @@ static inline int ocfs2_uses_extended_slot_map(struct ocfs2_super *osb) | |||
478 | #define OCFS2_IS_VALID_DIR_TRAILER(ptr) \ | 488 | #define OCFS2_IS_VALID_DIR_TRAILER(ptr) \ |
479 | (!strcmp((ptr)->db_signature, OCFS2_DIR_TRAILER_SIGNATURE)) | 489 | (!strcmp((ptr)->db_signature, OCFS2_DIR_TRAILER_SIGNATURE)) |
480 | 490 | ||
491 | #define OCFS2_IS_VALID_DX_ROOT(ptr) \ | ||
492 | (!strcmp((ptr)->dr_signature, OCFS2_DX_ROOT_SIGNATURE)) | ||
493 | |||
494 | #define OCFS2_IS_VALID_DX_LEAF(ptr) \ | ||
495 | (!strcmp((ptr)->dl_signature, OCFS2_DX_LEAF_SIGNATURE)) | ||
496 | |||
481 | static inline unsigned long ino_from_blkno(struct super_block *sb, | 497 | static inline unsigned long ino_from_blkno(struct super_block *sb, |
482 | u64 blkno) | 498 | u64 blkno) |
483 | { | 499 | { |