aboutsummaryrefslogtreecommitdiff
path: root/include/exec/ram_addr.h
diff options
context:
space:
mode:
authorAlexey Kardashevskiy <aik@ozlabs.ru>2017-03-02 13:36:11 +1100
committerDavid Gibson <david@gibson.dropbear.id.au>2017-03-03 11:30:59 +1100
commit9c60766887c647df7193463f7a2075e8993b514c (patch)
tree8c6c4797388c2b03226e7e5871531646234d0f1f /include/exec/ram_addr.h
parent9b44c836dc37507513eb67cea862f82dafa249d8 (diff)
exec, kvm, target-ppc: Move getrampagesize() to common code
getrampagesize() returns the largest supported page size and mainly used to know if huge pages are enabled. However is implemented in target-ppc/kvm.c and not available in TCG or other architectures. This renames and moves gethugepagesize() to mmap-alloc.c where fd-based analog of it is already implemented. This renames and moves getrampagesize() to exec.c as it seems to be the common place for helpers like this. Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to 'include/exec/ram_addr.h')
-rw-r--r--include/exec/ram_addr.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/exec/ram_addr.h b/include/exec/ram_addr.h
index 3e79466a44..cd432e73ae 100644
--- a/include/exec/ram_addr.h
+++ b/include/exec/ram_addr.h
@@ -52,6 +52,7 @@ static inline void *ramblock_ptr(RAMBlock *block, ram_addr_t offset)
return (char *)block->host + offset;
}
+long qemu_getrampagesize(void);
ram_addr_t last_ram_offset(void);
RAMBlock *qemu_ram_alloc_from_file(ram_addr_t size, MemoryRegion *mr,
bool share, const char *mem_path,