UVM_KM_SUBALLOC(9) Kernel Developer's Manual UVM_KM_SUBALLOC(9)

uvm_km_suballoc, uvm_km_freeraw kernel memory or address space allocator

#include <sys/param.h>
#include <uvm/uvm.h>

uvm_km_suballoc(vm_map_t map, vaddr_t *min, vaddr_t *max , vsize_t size, int flags, boolean_t fixed, vm_map_t submap);

void
uvm_km_free(vm_map_t map, vaddr_t addr, vsize_t size);

The () function allocates submap (with the specified flags, as described above) from map, creating a new map if submap is NULL. The addresses of the submap can be specified exactly by setting the fixed argument to non-zero, which causes the min argument to specify the beginning of the address in the submap. If fixed is zero, any address of size size will be allocated from map and the start and end addresses returned in min and max.

The () function free size bytes of memory in the kernel map, starting at address addr.

km_alloc(9)

August 24, 2024 OpenBSD 7.7