⚠️ VeridianOS Kernel Documentation - This is low-level kernel code. All functions are unsafe unless explicitly marked otherwise. no_std

Module frame_allocator

Module frame_allocator 

Source
Expand description

Physical frame allocator for VeridianOS

Implements a hybrid allocator combining bitmap (for small allocations) and buddy system (for large allocations) with NUMA awareness.

Structs§

FrameAllocator
NUMA-aware hybrid frame allocator
FrameAllocatorStats
Statistics for frame allocator
FrameNumber
Physical frame number
PerCpuPageCache
Per-CPU page frame cache to reduce global FRAME_ALLOCATOR contention.
PhysicalAddress
Physical memory address
PhysicalFrame
Physical frame representation
ReservedRegion
Reserved memory region

Enums§

FrameAllocatorError
Frame allocator errors
MemoryZone
Memory zone for frame allocation

Constants§

FRAME_SIZE
Size of a physical frame (4KB)

Functions§

per_cpu_alloc_frame
Allocate a single physical frame using the per-CPU cache.
per_cpu_free_frame
Free a single physical frame using the per-CPU cache.

Type Aliases§

Result
Frame allocation result