aboutsummaryrefslogtreecommitdiff
path: root/numa.c
diff options
context:
space:
mode:
authorMarkus Armbruster <armbru@redhat.com>2015-02-10 15:06:23 +0100
committerMarkus Armbruster <armbru@redhat.com>2015-02-18 10:51:37 +0100
commit29b762f5f0efdb6a0cb693be6df2988c195523db (patch)
treeed46bd76d5d900c3f2720b10ea2ec6b0e46f7fc4 /numa.c
parent12d0cc2db971cc0888b7d465143c68dee381c88b (diff)
downloadqemu-29b762f5f0efdb6a0cb693be6df2988c195523db.zip
qemu-29b762f5f0efdb6a0cb693be6df2988c195523db.tar.gz
qemu-29b762f5f0efdb6a0cb693be6df2988c195523db.tar.bz2
numa: Avoid qerror_report_err() outside QMP command handlers
qerror_report_err() is a transitional interface to help with converting existing monitor commands to QMP. It should not be used elsewhere. Replace by error_report_err() in initial startup helper numa_init_func() and board setup helper memory_region_allocate_system_memory(). Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com>
Diffstat (limited to 'numa.c')
-rw-r--r--numa.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/numa.c b/numa.c
index afd2866..f8fc377 100644
--- a/numa.c
+++ b/numa.c
@@ -146,8 +146,7 @@ int numa_init_func(QemuOpts *opts, void *opaque)
return 0;
error:
- qerror_report_err(err);
- error_free(err);
+ error_report_err(err);
if (object) {
QapiDeallocVisitor *dv = qapi_dealloc_visitor_new();
@@ -262,8 +261,7 @@ static void allocate_system_memory_nonnuma(MemoryRegion *mr, Object *owner,
* regular RAM allocation.
*/
if (err) {
- qerror_report_err(err);
- error_free(err);
+ error_report_err(err);
memory_region_init_ram(mr, owner, name, ram_size, &error_abort);
}
#else
@@ -298,7 +296,7 @@ void memory_region_allocate_system_memory(MemoryRegion *mr, Object *owner,
}
MemoryRegion *seg = host_memory_backend_get_memory(backend, &local_err);
if (local_err) {
- qerror_report_err(local_err);
+ error_report_err(local_err);
exit(1);
}