78 static auto
string(const
phys_t phys) noexcept -> const
char*;
86 static auto
physOf(const T* const
object) noexcept ->
phys_t;
123 if (
nullptr == text) [[unlikely]] {
129 for (
auto length {0_u64}; length < available; ++length) {
130 if (
'\0' == text[length]) {
static auto physOf(const T *const object) noexcept -> phys_t
Physical address of directly mapped object.
static auto end() noexcept -> phys_t
End of directly mapped physical memory.
static void setEnd(const phys_t end) noexcept
Set end of directly mapped physical memory (paging mapped more memory).
~direct() noexcept=default
D-tor.
static auto isMapped(const phys_t phys, const phys_t size) noexcept -> bool
Check if whole physical range is directly mapped.
static auto string(const phys_t phys) noexcept -> const char *
String at physical memory (nullptr if not directly mapped up to null terminator).
static constinit phys_t mEnd
End of directly mapped physical memory.
static auto pointer(const phys_t phys, const phys_t size=sizeof(T)) noexcept -> T *
Pointer to physical memory (nullptr if range is not directly mapped).
direct(const direct &other)=delete
Copy c-tor.
Physical page frame allocator.
std::size_t igros_usize_t
Unsigned size.
Memory management: physical page allocator, direct map, virtual addresses.
constexpr auto LOW_MEMORY_LIMIT
Physical memory mapped by boot code at kernel virtual offset (see boot.s).
igros_quad_t phys_t
Physical address (64-bit: physical memory may lie above 4 GB).
Physical memory allocator.
Common C++ types redefinition.