aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorPhilippe Mathieu-Daudé <philmd@linaro.org>2023-11-20 11:29:31 +0100
committerPhilippe Mathieu-Daudé <philmd@linaro.org>2024-01-05 16:20:15 +0100
commitb9159451d3411bfef528f431c98527c172cd46e8 (patch)
tree03ca4babad40185e2de6ce300fa866c2568da6a5 /include
parentfe5f33d6b086d6911d69dd77abe09b21bdb2ea5f (diff)
downloadqemu-b9159451d3411bfef528f431c98527c172cd46e8.zip
qemu-b9159451d3411bfef528f431c98527c172cd46e8.tar.gz
qemu-b9159451d3411bfef528f431c98527c172cd46e8.tar.bz2
memory: Have memory_region_init_rom() handler return a boolean
Following the example documented since commit e3fe3988d7 ("error: Document Error API usage rules"), have memory_region_init_rom() return a boolean indicating whether an error is set or not. Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org> Reviewed-by: Manos Pitsidianakis <manos.pitsidianakis@linaro.org> Reviewed-by: Gavin Shan <gshan@redhat.com> Message-Id: <20231120213301.24349-8-philmd@linaro.org>
Diffstat (limited to 'include')
-rw-r--r--include/exec/memory.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/include/exec/memory.h b/include/exec/memory.h
index b2dce73..9f54bc4 100644
--- a/include/exec/memory.h
+++ b/include/exec/memory.h
@@ -1611,8 +1611,10 @@ bool memory_region_init_ram(MemoryRegion *mr,
* must be unique within any device
* @size: size of the region.
* @errp: pointer to Error*, to store an error if it happens.
+ *
+ * Return: true on success, else false setting @errp with error.
*/
-void memory_region_init_rom(MemoryRegion *mr,
+bool memory_region_init_rom(MemoryRegion *mr,
Object *owner,
const char *name,
uint64_t size,