drivers/md/dm-vdo/constants.h
Source file repositories/reference/linux-study-clean/drivers/md/dm-vdo/constants.h
File Facts
- System
- Linux kernel
- Corpus path
drivers/md/dm-vdo/constants.h- Extension
.h- Size
- 2975 bytes
- Lines
- 103
- Domain
- Driver Families
- Bucket
- drivers/md
- Inferred role
- Driver Families: implementation source
- Status
- source implementation candidate
Why This File Exists
Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
Dependency Surface
linux/blkdev.htypes.h
Detected Declarations
- No top-level syscall, struct, function, initcall, or export declaration detected by the generator.
Annotated Snippet
#ifndef VDO_CONSTANTS_H
#define VDO_CONSTANTS_H
#include <linux/blkdev.h>
#include "types.h"
enum {
/*
* The maximum number of contiguous PBNs which will go to a single bio submission queue,
* assuming there is more than one queue.
*/
VDO_BIO_ROTATION_INTERVAL_LIMIT = 1024,
/* The number of entries on a block map page */
VDO_BLOCK_MAP_ENTRIES_PER_PAGE = 812,
/* The origin of the flat portion of the block map */
VDO_BLOCK_MAP_FLAT_PAGE_ORIGIN = 1,
/*
* The height of a block map tree. Assuming a root count of 60 and 812 entries per page,
* this is big enough to represent almost 95 PB of logical space.
*/
VDO_BLOCK_MAP_TREE_HEIGHT = 5,
/* The default number of bio submission queues. */
DEFAULT_VDO_BIO_SUBMIT_QUEUE_COUNT = 4,
/* The number of contiguous PBNs to be submitted to a single bio queue. */
DEFAULT_VDO_BIO_SUBMIT_QUEUE_ROTATE_INTERVAL = 64,
/* The number of trees in the arboreal block map */
DEFAULT_VDO_BLOCK_MAP_TREE_ROOT_COUNT = 60,
/* The default size of the recovery journal, in blocks */
DEFAULT_VDO_RECOVERY_JOURNAL_SIZE = 32 * 1024,
/* The default size of each slab journal, in blocks */
DEFAULT_VDO_SLAB_JOURNAL_SIZE = 224,
/* The recovery journal starting sequence number set at format time */
RECOVERY_JOURNAL_STARTING_SEQUENCE_NUMBER = 1,
/*
* The initial size of lbn_operations and pbn_operations, which is based upon the expected
* maximum number of outstanding VIOs. This value was chosen to make it highly unlikely
* that the maps would need to be resized.
*/
VDO_LOCK_MAP_CAPACITY = 10000,
/* The maximum number of logical zones */
MAX_VDO_LOGICAL_ZONES = 60,
/* The maximum number of physical zones */
MAX_VDO_PHYSICAL_ZONES = 16,
/* The default blocks in one slab */
DEFAULT_VDO_SLAB_BLOCKS = 1U << 19,
/* The minimum blocks in one slab */
MIN_VDO_SLAB_BLOCKS = 1U << 13,
/* The maximum blocks in one slab */
MAX_VDO_SLAB_BLOCKS = 1U << 23,
/* The maximum number of slabs the slab depot supports */
MAX_VDO_SLABS = 8192,
/*
* The maximum number of block map pages to load simultaneously during recovery or rebuild.
*/
MAXIMUM_SIMULTANEOUS_VDO_BLOCK_MAP_RESTORATION_READS = 1024,
/* The maximum number of entries in the slab summary */
MAXIMUM_VDO_SLAB_SUMMARY_ENTRIES = MAX_VDO_SLABS * MAX_VDO_PHYSICAL_ZONES,
/* The maximum number of total threads in a VDO thread configuration. */
MAXIMUM_VDO_THREADS = 100,
/* The maximum number of VIOs in the system at once */
MAXIMUM_VDO_USER_VIOS = 2048,
/* The only physical block size supported by VDO */
VDO_BLOCK_SIZE = 4096,
/* The number of sectors per block */
VDO_SECTORS_PER_BLOCK = (VDO_BLOCK_SIZE >> SECTOR_SHIFT),
/* The size of a sector that will not be torn */
Annotation
- Immediate include surface: `linux/blkdev.h`, `types.h`.
- Atlas domain: Driver Families / drivers/md.
- Implementation status: source implementation candidate.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.