![]() |
SyterKit 0.4.0.x
SyterKit is a bare-metal framework
|
Memory Management Unit (MMU) interface for RISC-V architecture. More...
#include <stdint.h>#include "csr.h"#include "timer.h"#include "barrier.h"#include "cache.h"#include "interrupt.h"
Go to the source code of this file.
Functions | |
| void | mmu_enable (void) |
| Enable the SV39 MMU with cache initialization. | |
| int | sysmap_add_mem_region (uint32_t start_addr, uint32_t len, uint32_t mem_attr) |
| Adds a memory region to the system memory map. | |
Memory Management Unit (MMU) interface for RISC-V architecture.
This header file provides functions and definitions for initializing and managing the memory management unit (MMU) on RISC-V architecture.
| void mmu_enable | ( | void | ) |
Enable the SV39 MMU with cache initialization.
This function initializes the cache and enables both data and instruction caches for the SV39 memory management unit.
Adds a memory region to the system memory map.
This function registers a new memory region with the given starting address, length, and memory attributes to the system's memory map. The region can be used for various purposes, such as memory allocation or defining regions for specific hardware access.
| start_addr | Starting address of the memory region. This address should be aligned to the appropriate boundary for the memory type. |
| len | Length of the memory region in bytes. The length should be a positive value and should not exceed the system's available memory range. |
| mem_attr | Memory attributes for the region (e.g., read/write, cacheable, non-cacheable, etc.). The exact attributes depend on the platform and memory type. |