|
Barrelfish
|
Creates mapping based on the MMU type. More...
Macros | |
| #define | MIN_MEM_FOR_FREE (1 * 1024 * 1024) |
| Minimum free memory before we return it to memory server. | |
Functions | |
| errval_t | vspace_mmu_aware_init (struct vspace_mmu_aware *state, size_t size) |
| Initialize vspace_mmu_aware struct. More... | |
| errval_t | vspace_mmu_aware_map (struct vspace_mmu_aware *state, size_t req_size, void **retbuf, size_t *retsize) |
| Create mappings. More... | |
Creates mapping based on the MMU type.
If the MMU supports translations, then anonymous type is used (more efficient) else non contiguous memory is used.
| errval_t vspace_mmu_aware_init | ( | struct vspace_mmu_aware * | state, |
| size_t | size | ||
| ) |
Initialize vspace_mmu_aware struct.
| state | The struct to initialize |
| init | The buffer to use to initialize the struct |
| size | The size of anon memobj to create |
Initializes the struct according to the type of MMU
| errval_t vspace_mmu_aware_map | ( | struct vspace_mmu_aware * | state, |
| size_t | req_size, | ||
| void ** | retbuf, | ||
| size_t * | retsize | ||
| ) |
Create mappings.
| state | The object metadata |
| frame | An empty slot to place the frame capability in |
| req_size | The required amount by the application |
| retbuf | Pointer to return the mapped buffer |
| retsize | The actual size returned |
This function will returns a special error code if frame_create fails due to the constrains to the memory server (amount of memory or region of memory). This is to facilitate retrying with different constraints.
1.8.11