Lines Matching +full:00 +full:- +full:40 +full:bit
1 /* SPDX-License-Identifier: GPL-2.0-only */
2 /* -*- mode: c; c-basic-offset: 8; -*-
7 * On-disk structures for OCFS2.
61 ( OCFS2_SB(sb)->s_feature_compat & (mask) )
63 ( OCFS2_SB(sb)->s_feature_ro_compat & (mask) )
65 ( OCFS2_SB(sb)->s_feature_incompat & (mask) )
67 OCFS2_SB(sb)->s_feature_compat |= (mask)
69 OCFS2_SB(sb)->s_feature_ro_compat |= (mask)
71 OCFS2_SB(sb)->s_feature_incompat |= (mask)
73 OCFS2_SB(sb)->s_feature_compat &= ~(mask)
75 OCFS2_SB(sb)->s_feature_ro_compat &= ~(mask)
77 OCFS2_SB(sb)->s_feature_incompat &= ~(mask)
98 * Heartbeat-only devices are missing journals and other files. The
107 * after an aborted run without fsck-ing.
111 /* Used to denote a non-clustered volume */
114 /* Support for sparse allocation in b-trees */
121 * fsck-ing.
161 * Incompat bit to indicate useable clusterinfo with stackflags for all
162 * cluster stacks (userspace adnd o2cb). If this bit is set,
254 /* End compression flags --- maybe not all used */
256 #define OCFS2_INDEX_FL FS_INDEX_FL /* hash-indexed directory */
293 #define OCFS2_INVALID_SLOT ((u16)-1)
350 (NUM_SYSTEM_INODES - OCFS2_FIRST_LOCAL_SYSTEM_INODE)
365 /* Slot-specific system inodes (one copy per slot) */
387 #define OCFS2_DIR_ROUND (OCFS2_DIR_PAD - 1)
395 #define OCFS2_DX_LINK_MAX ((1U << 31) - 1U)
403 #define OCFS2_RAW_SB(dinode) (&((dinode)->id2.i_super))
411 /*00*/ __le32 bc_crc32e; /* 802.3 Ethernet II CRC32 */
412 __le16 bc_ecc; /* Single-error-correction parity vector.
429 /*00*/ __le32 e_cpos; /* Offset into the file, in clusters */
461 /*00*/ __le16 l_tree_depth; /* Extent tree depth from this
466 used - tree_depth is never that big.
482 /*00*/ __le16 cl_cpg; /* Clusters per Block Group */
496 /*00*/ __le16 tl_count; /* Total records in this log */
507 /*00*/ __u8 h_signature[8]; /* Signature for verification */
511 __le16 h_suballoc_bit; /* Bit offset in suballocator
523 /* Actual on-disk size is one block */
529 * value -1 (0xFFFF) is OCFS2_INVALID_SLOT. This marks a slot empty.
532 /*00*/ __le16 sm_slots[0];
534 * Actual on-disk size is one block. OCFS2_MAX_SLOTS is 255,
540 /*00*/ __u8 es_valid;
553 /*00*/ struct ocfs2_extended_slot se_slots[0];
561 * ci_stackflags is only valid if the incompat bit
565 /*00*/ __u8 ci_stack[OCFS2_STACK_LABEL_LEN];
585 /*00*/ __le16 s_major_rev_level;
596 __le32 s_feature_ro_compat; /* Readonly-compatible feature set */
603 /*40*/ __le16 s_max_slots; /* Max number of simultaneous mounts
610 /*90*/ __u8 s_uuid[OCFS2_VOL_UUID_LEN]; /* 128-bit uuid */
617 __le32 s_dx_seed[3]; /* seed[0-2] for dx dir hash.
639 /*00*/ __le32 la_bm_off; /* Starting bit offset in main bitmap */
647 * Data-in-inode header. This is only used if i_dyn_features has
652 /*00*/ __le16 id_count; /* Number of bytes that can be used
663 /*00*/ __u8 i_signature[8]; /* Signature for validation */
667 __le16 i_suballoc_bit; /* Bit offset in suballocator
680 /*40*/ __le64 i_mtime; /* Modification time */
685 /*60*/ __le32 i_fs_generation; /* Generation per fs-instance */
706 64bit union */
734 /* Actual on-disk size is one block */
738 * On-disk directory entry structure for OCFS2
740 * Packed as this structure could be accessed unaligned on 64-bit platforms
743 /*00*/ __le64 inode; /* Inode number */
748 /* Actual on-disk length specified by rec_len */
752 * Per-block record for the unindexed directory btree. This is carefully
760 /*00*/ __le64 db_compat_inode; /* Always zero. Was inode */
776 /*40*/
813 * start-of-list pointers.
820 __le16 dr_suballoc_bit; /* Bit offset in suballocator
848 struct ocfs2_dx_entry_list dr_entries; /* In-root-block list of
880 /*00*/ __u8 bg_signature[8]; /* Signature for validation */
896 /*40*/ union {
905 * discontiguous group is signified by a non-zero
906 * bg_list->l_next_free_rec. Only block groups
918 /* Actual on-disk size is one block */
922 /*00*/ __le64 r_cpos; /* Physical offset, in clusters */
933 /*00*/ __le16 rl_count; /* Maximum number of entries possible
943 /*00*/ __u8 rf_signature[8]; /* Signature for verification */
946 __le16 rf_suballoc_bit; /* Bit offset in suballocator
960 /*40*/ __le32 rf_generation; /* generation number. all be the same
976 /* Actual on-disk size is one block */
995 * type and the highest bit indicates whether
1031 * b-tree like file data. The xattr value root points to this structure.
1034 /*00*/ __le32 xr_clusters; /* clusters covered by xattr value. */
1044 * attributes will be organized and stored in an indexed-btree.
1047 /*00*/ __le32 xt_clusters; /* clusters covered by xattr. */
1067 /*00*/ __u8 xb_signature[8]; /* Signature for verification */
1070 __le16 xb_suballoc_bit; /* Bit offset in suballocator
1098 xe->xe_type |= OCFS2_XATTR_ENTRY_LOCAL; in ocfs2_xattr_set_local()
1100 xe->xe_type &= ~OCFS2_XATTR_ENTRY_LOCAL; in ocfs2_xattr_set_local()
1105 return xe->xe_type & OCFS2_XATTR_ENTRY_LOCAL; in ocfs2_xattr_is_local()
1110 xe->xe_type |= type & OCFS2_XATTR_TYPE_MASK; in ocfs2_xattr_set_type()
1115 return xe->xe_type & OCFS2_XATTR_TYPE_MASK; in ocfs2_xattr_get_type()
1150 /*00*/ __le32 dqi_bgrace; /* Grace time for space softlimit excess */
1163 /*00*/ __le32 dqb_id; /* ID the structure belongs to */
1172 /*40*/ __le64 dqb_itime; /* time limit for excessive inode use */
1178 * On-disk structures for local quota file
1216 /*00*/ __le64 dqb_id; /* id this quota applies to */
1227 /*00*/ struct ocfs2_block_check dq_check; /* Error checking */
1235 ptr += blocksize - OCFS2_QBLK_RESERVED_SPACE; in ocfs2_block_dqtrailer()
1243 return sb->s_blocksize - in ocfs2_fast_symlink_chars()
1250 unsigned int xattrsize = le16_to_cpu(di->i_xattr_inline_size); in ocfs2_max_inline_data_with_xattr()
1252 if (le16_to_cpu(di->i_dyn_features) & OCFS2_INLINE_XATTR_FL) in ocfs2_max_inline_data_with_xattr()
1253 return sb->s_blocksize - in ocfs2_max_inline_data_with_xattr()
1254 offsetof(struct ocfs2_dinode, id2.i_data.id_data) - in ocfs2_max_inline_data_with_xattr()
1257 return sb->s_blocksize - in ocfs2_max_inline_data_with_xattr()
1265 size = sb->s_blocksize - in ocfs2_extent_recs_per_inode()
1276 unsigned int xattrsize = le16_to_cpu(di->i_xattr_inline_size); in ocfs2_extent_recs_per_inode_with_xattr()
1278 if (le16_to_cpu(di->i_dyn_features) & OCFS2_INLINE_XATTR_FL) in ocfs2_extent_recs_per_inode_with_xattr()
1279 size = sb->s_blocksize - in ocfs2_extent_recs_per_inode_with_xattr()
1280 offsetof(struct ocfs2_dinode, id2.i_list.l_recs) - in ocfs2_extent_recs_per_inode_with_xattr()
1283 size = sb->s_blocksize - in ocfs2_extent_recs_per_inode_with_xattr()
1293 size = sb->s_blocksize - in ocfs2_extent_recs_per_dx_root()
1303 size = sb->s_blocksize - in ocfs2_chain_recs_per_inode()
1313 size = sb->s_blocksize - in ocfs2_extent_recs_per_eb()
1323 size = sb->s_blocksize - in ocfs2_extent_recs_per_gd()
1333 size = sb->s_blocksize - in ocfs2_dx_entries_per_leaf()
1343 size = sb->s_blocksize - in ocfs2_dx_entries_per_root()
1353 size = sb->s_blocksize - in ocfs2_local_alloc_size()
1363 int size = sb->s_blocksize - in ocfs2_group_bitmap_size()
1370 * bg_size as-is unless discontig_bg is enabled. in ocfs2_group_bitmap_size()
1383 size = sb->s_blocksize - in ocfs2_truncate_recs_per_inode()
1395 offset >>= sb->s_blocksize_bits; in ocfs2_backup_super_blkno()
1407 size = sb->s_blocksize - in ocfs2_xattr_recs_per_xb()
1418 size = sb->s_blocksize - in ocfs2_extent_recs_per_rb()
1428 size = sb->s_blocksize - in ocfs2_refcount_recs_per_rb()
1437 return le64_to_cpu(rec->r_cpos) & OCFS2_32BIT_POS_MASK; in ocfs2_get_ref_rec_low_cpos()
1442 return blocksize - offsetof(struct ocfs2_dinode, id2.i_symlink); in ocfs2_fast_symlink_chars()
1448 if (di && (di->i_dyn_features & OCFS2_INLINE_XATTR_FL)) in ocfs2_max_inline_data_with_xattr()
1449 return blocksize - in ocfs2_max_inline_data_with_xattr()
1450 offsetof(struct ocfs2_dinode, id2.i_data.id_data) - in ocfs2_max_inline_data_with_xattr()
1451 di->i_xattr_inline_size; in ocfs2_max_inline_data_with_xattr()
1453 return blocksize - in ocfs2_max_inline_data_with_xattr()
1461 size = blocksize - in ocfs2_extent_recs_per_inode()
1471 size = blocksize - in ocfs2_chain_recs_per_inode()
1481 size = blocksize - in ocfs2_extent_recs_per_eb()
1491 size = blocksize - in ocfs2_extent_recs_per_gd()
1501 size = blocksize - in ocfs2_local_alloc_size()
1511 int size = sb->s_blocksize - in ocfs2_group_bitmap_size()
1518 * bg_size as-is unless discontig_bg is enabled. in ocfs2_group_bitmap_size()
1531 size = blocksize - in ocfs2_truncate_recs_per_inode()
1554 size = blocksize - in ocfs2_xattr_recs_per_xb()
1593 de->file_type = fs_umode_to_ftype(mode); in ocfs2_set_de_type()
1599 le16_to_cpu(gd->bg_size)) != in ocfs2_gd_is_discontig()
1606 if (!gd->bg_list.l_next_free_rec) in ocfs2_gd_is_discontig()