diff options
| author | Michael S. Tsirkin | 2014-12-16 10:21:23 +0100 |
|---|---|---|
| committer | Michael S. Tsirkin | 2015-01-08 12:17:54 +0100 |
| commit | e7af4c67300b3f9382e96f7a6741a5992116b2d2 (patch) | |
| tree | 3ac54bff09310f946a272b322780150231968ec1 /include/exec | |
| parent | Merge remote-tracking branch 'remotes/spice/tags/pull-spice-20141216-1' into ... (diff) | |
| download | qemu-e7af4c67300b3f9382e96f7a6741a5992116b2d2.tar.gz qemu-e7af4c67300b3f9382e96f7a6741a5992116b2d2.tar.xz qemu-e7af4c67300b3f9382e96f7a6741a5992116b2d2.zip | |
memory: add memory_region_set_size
Add API to change MR size.
Will be used internally for RAM resize.
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'include/exec')
| -rw-r--r-- | include/exec/memory.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/include/exec/memory.h b/include/exec/memory.h index f64ab5e3e5..0882221395 100644 --- a/include/exec/memory.h +++ b/include/exec/memory.h @@ -878,6 +878,16 @@ void memory_region_set_enabled(MemoryRegion *mr, bool enabled); void memory_region_set_address(MemoryRegion *mr, hwaddr addr); /* + * memory_region_set_size: dynamically update the size of a region. + * + * Dynamically updates the size of a region. + * + * @mr: the region to be updated + * @size: used size of the region. + */ +void memory_region_set_size(MemoryRegion *mr, uint64_t size); + +/* * memory_region_set_alias_offset: dynamically update a memory alias's offset * * Dynamically updates the offset into the target region that an alias points |
