提交 5d546d4b 编写于 作者: P Peter Crosthwaite 提交者: Paolo Bonzini

memory: constify memory_region_name

It doesn't change the MR and some prospective call sites will have
const MRs at hand.
Signed-off-by: NPeter Crosthwaite <peter.crosthwaite@xilinx.com>
Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com>
上级 83234bf2
......@@ -511,7 +511,7 @@ void memory_region_unregister_iommu_notifier(Notifier *n);
*
* @mr: the memory region being queried
*/
const char *memory_region_name(MemoryRegion *mr);
const char *memory_region_name(const MemoryRegion *mr);
/**
* memory_region_is_logging: return whether a memory region is logging writes
......
......@@ -1308,7 +1308,7 @@ uint64_t memory_region_size(MemoryRegion *mr)
return int128_get64(mr->size);
}
const char *memory_region_name(MemoryRegion *mr)
const char *memory_region_name(const MemoryRegion *mr)
{
return mr->name;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册