mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-01 14:53:54 -06:00
memory: add memory_region_is_mapped() API
which allows to check if MemoryRegion is already mapped. Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
This commit is contained in:
parent
10b7e74bf2
commit
eed2bacfd2
2 changed files with 17 additions and 1 deletions
|
@ -847,6 +847,14 @@ void memory_region_set_alias_offset(MemoryRegion *mr,
|
|||
*/
|
||||
bool memory_region_present(MemoryRegion *container, hwaddr addr);
|
||||
|
||||
/**
|
||||
* memory_region_is_mapped: returns true if #MemoryRegion is mapped
|
||||
* into any address space.
|
||||
*
|
||||
* @mr: a #MemoryRegion which should be checked if it's mapped
|
||||
*/
|
||||
bool memory_region_is_mapped(MemoryRegion *mr);
|
||||
|
||||
/**
|
||||
* memory_region_find: translate an address/size relative to a
|
||||
* MemoryRegion into a #MemoryRegionSection.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue