|
enum | m0_balloc_group_desc_format_version { M0_BALLOC_GROUP_DESC_FORMAT_VERSION_1 = 1,
M0_BALLOC_GROUP_DESC_FORMAT_VERSION = M0_BALLOC_GROUP_DESC_FORMAT_VERSION_1
} |
|
enum | m0_balloc_allocation_flag {
M0_BALLOC_HINT_MERGE = 1 << 0,
M0_BALLOC_HINT_RESERVED = 1 << 1,
M0_BALLOC_HINT_METADATA = 1 << 2,
M0_BALLOC_HINT_FIRST = 1 << 3,
M0_BALLOC_HINT_BEST = 1 << 4,
M0_BALLOC_HINT_DATA = 1 << 5,
M0_BALLOC_HINT_NOPREALLOC = 1 << 6,
M0_BALLOC_HINT_GROUP_ALLOC = 1 << 7,
M0_BALLOC_HINT_GOAL_ONLY = 1 << 8,
M0_BALLOC_HINT_TRY_GOAL = 1 << 9,
M0_BALLOC_DELALLOC_RESERVED = 1 << 10,
M0_BALLOC_STREAM_ALLOC = 1 << 11,
M0_BALLOC_SPARE_ZONE = 1 << 12,
M0_BALLOC_NORMAL_ZONE = 1 << 13
} |
|
enum | m0_balloc_group_info_state { M0_BALLOC_GROUP_INFO_INIT = 1 << 0,
M0_BALLOC_GROUP_INFO_DIRTY = 1 << 1
} |
|
enum | m0_balloc_super_block_state { M0_BALLOC_SB_DIRTY = 1 << 0
} |
|
enum | m0_balloc_super_block_version { M0_BALLOC_SB_VERSION = 1ULL
} |
|
enum | { M0_BALLOC_BUDDY_LOOKUP_MAX = 10
} |
|
enum | m0_balloc_format_version { M0_BALLOC_FORMAT_VERSION_1 = 1,
M0_BALLOC_FORMAT_VERSION = M0_BALLOC_FORMAT_VERSION_1
} |
|
enum | { BALLOC_DEF_CONTAINER_SIZE = 4096ULL * 32 * 1024 * 1000,
BALLOC_DEF_BLOCK_SHIFT = 12,
BALLOC_DEF_GROUPS_NR = 64,
BALLOC_DEF_BLOCKS_PER_GROUP = 32768
} |
|
All data structures stored in db in little-endian format (Intel CPU endian). To correctly compare the key value, a custom specific comparison function is provided to db.
◆ anonymous enum
Enumerator |
---|
M0_BALLOC_BUDDY_LOOKUP_MAX | |
Definition at line 212 of file balloc.h.
◆ anonymous enum
Enumerator |
---|
BALLOC_DEF_CONTAINER_SIZE | - Todo:
- should equal to size of HDD
|
BALLOC_DEF_BLOCK_SHIFT | |
BALLOC_DEF_GROUPS_NR | Approximate number of groups. Exact number of groups can differ depending on group size restrictions.
|
BALLOC_DEF_BLOCKS_PER_GROUP | Used as minimal group size
|
Definition at line 327 of file balloc.h.
◆ m0_balloc_allocation_flag
Enumerator |
---|
M0_BALLOC_HINT_MERGE | prefer goal again. length
|
M0_BALLOC_HINT_RESERVED | blocks already reserved
|
M0_BALLOC_HINT_METADATA | metadata is being allocated
|
M0_BALLOC_HINT_FIRST | use the first found extent
|
M0_BALLOC_HINT_BEST | search for the best chunk
|
M0_BALLOC_HINT_DATA | data is being allocated
|
M0_BALLOC_HINT_NOPREALLOC | don't preallocate (for tails)
|
M0_BALLOC_HINT_GROUP_ALLOC | allocate for locality group
|
M0_BALLOC_HINT_GOAL_ONLY | allocate goal blocks or none
|
M0_BALLOC_HINT_TRY_GOAL | goal is meaningful
|
M0_BALLOC_DELALLOC_RESERVED | blocks already pre-reserved by delayed allocation
|
M0_BALLOC_STREAM_ALLOC | We are doing stream allocation
|
M0_BALLOC_SPARE_ZONE | Allocate in spare zone.
|
M0_BALLOC_NORMAL_ZONE | Allocate in normal zone.
|
Definition at line 87 of file balloc.h.
◆ m0_balloc_format_version
Enumerator |
---|
M0_BALLOC_FORMAT_VERSION_1 | |
M0_BALLOC_FORMAT_VERSION | Current version, should point to the latest version present
|
Definition at line 254 of file balloc.h.
◆ m0_balloc_group_desc_format_version
Enumerator |
---|
M0_BALLOC_GROUP_DESC_FORMAT_VERSION_1 | |
M0_BALLOC_GROUP_DESC_FORMAT_VERSION | Current version, should point to the latest version present
|
Definition at line 76 of file balloc.h.
◆ m0_balloc_group_info_state
Enumerator |
---|
M0_BALLOC_GROUP_INFO_INIT | inited from disk
|
M0_BALLOC_GROUP_INFO_DIRTY | dirty, need sync
|
Definition at line 164 of file balloc.h.
◆ m0_balloc_super_block_state
Enumerator |
---|
M0_BALLOC_SB_DIRTY | |
Definition at line 204 of file balloc.h.
◆ m0_balloc_super_block_version
Enumerator |
---|
M0_BALLOC_SB_VERSION | |
Definition at line 208 of file balloc.h.
◆ b2m0()
◆ m0_balloc_create()
Creates struct m0_balloc instance with container on back-end segment .
One balloc instance is allocated and initialised per storage domain.
- Parameters
-
fid | - unique fid for balloc tree. |
- See also
- struct ad_balloc_ops
- Precondition
- out != NULL
Definition at line 3015 of file balloc.c.
◆ m0_balloc_debug_dump_group()
◆ m0_balloc_debug_dump_group_extent()
M0_INTERNAL void m0_balloc_debug_dump_group_extent |
( |
const char * |
tag, |
|
|
struct m0_balloc_group_info * |
grp |
|
) |
| |
◆ m0_balloc_debug_dump_sb()
◆ m0_balloc_gn2info()
◆ m0_balloc_group_desc_init()
◆ m0_balloc_init()
M0_INTERNAL void m0_balloc_init |
( |
struct m0_balloc * |
cb | ) |
|
◆ m0_balloc_load_extents()
◆ m0_balloc_lock_group()
◆ m0_balloc_release_extents()
◆ m0_balloc_trylock_group()
◆ m0_balloc_unlock_group()
◆ M0_XCA_DOMAIN()
◆ M0_XCA_DOMAIN