diff options
author | neel <neel@FreeBSD.org> | 2012-09-29 01:15:45 +0000 |
---|---|---|
committer | neel <neel@FreeBSD.org> | 2012-09-29 01:15:45 +0000 |
commit | bc87f08e9822e6446dc91b0451317740259de95c (patch) | |
tree | cc4182b3e13e70bcf805289a17de0b30a4a5ec94 /sys/amd64/include | |
parent | b65259b285734eec4d40fe639b4e84a6f4bf9f02 (diff) | |
download | FreeBSD-src-bc87f08e9822e6446dc91b0451317740259de95c.zip FreeBSD-src-bc87f08e9822e6446dc91b0451317740259de95c.tar.gz |
Get rid of assumptions in the hypervisor that the host physical memory
associated with guest physical memory is contiguous.
In this case vm_malloc() was using vm_gpa2hpa() to indirectly infer whether
or not the address range had already been allocated.
Replace this instead with an explicit API 'vm_gpa_available()' that returns
TRUE if a page is available for allocation in guest physical address space.
Diffstat (limited to 'sys/amd64/include')
-rw-r--r-- | sys/amd64/include/vmm.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/amd64/include/vmm.h b/sys/amd64/include/vmm.h index 0b3a29c..bb2f778 100644 --- a/sys/amd64/include/vmm.h +++ b/sys/amd64/include/vmm.h @@ -89,7 +89,7 @@ extern struct vmm_ops vmm_ops_amd; struct vm *vm_create(const char *name); void vm_destroy(struct vm *vm); const char *vm_name(struct vm *vm); -int vm_malloc(struct vm *vm, vm_paddr_t gpa, size_t len, vm_paddr_t *ret_hpa); +int vm_malloc(struct vm *vm, vm_paddr_t gpa, size_t len); int vm_map_mmio(struct vm *vm, vm_paddr_t gpa, size_t len, vm_paddr_t hpa); int vm_unmap_mmio(struct vm *vm, vm_paddr_t gpa, size_t len); vm_paddr_t vm_gpa2hpa(struct vm *vm, vm_paddr_t gpa, size_t size); |