[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH v14 19/21] acpi: convert to QObjectInputVisitor for
From: |
Daniel P. Berrange |
Subject: |
[Qemu-devel] [PATCH v14 19/21] acpi: convert to QObjectInputVisitor for -acpi parsing |
Date: |
Fri, 30 Sep 2016 15:45:42 +0100 |
The -acpi command line option parsing uses the OptsVisitor
currently. This is easily replaced by the QObjectInputVisitor
instead. There is no need to enable any of the compatibility
options, since the AcpiTableOptions QAPI struct only contains
scalar properties.
Signed-off-by: Daniel P. Berrange <address@hidden>
---
hw/acpi/core.c | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/hw/acpi/core.c b/hw/acpi/core.c
index e890a5d..67c0abe 100644
--- a/hw/acpi/core.c
+++ b/hw/acpi/core.c
@@ -25,7 +25,7 @@
#include "hw/acpi/acpi.h"
#include "hw/nvram/fw_cfg.h"
#include "qemu/config-file.h"
-#include "qapi/opts-visitor.h"
+#include "qapi/qobject-input-visitor.h"
#include "qapi-visit.h"
#include "qapi-event.h"
@@ -237,14 +237,14 @@ void acpi_table_add(const QemuOpts *opts, Error **errp)
char **cur;
size_t bloblen = 0;
char unsigned *blob = NULL;
+ Visitor *v;
- {
- Visitor *v;
-
- v = opts_visitor_new(opts);
- visit_type_AcpiTableOptions(v, NULL, &hdrs, &err);
- visit_free(v);
+ v = qobject_input_visitor_new_opts(opts, false, 0, false, false, &err);
+ if (err) {
+ goto out;
}
+ visit_type_AcpiTableOptions(v, NULL, &hdrs, &err);
+ visit_free(v);
if (err) {
goto out;
--
2.7.4
- [Qemu-devel] [PATCH v14 10/21] qapi: permit auto-creating nested structs, (continued)
- [Qemu-devel] [PATCH v14 10/21] qapi: permit auto-creating nested structs, Daniel P. Berrange, 2016/09/30
- [Qemu-devel] [PATCH v14 11/21] qapi: add integer range support for QObjectInputVisitor, Daniel P. Berrange, 2016/09/30
- [Qemu-devel] [PATCH v14 12/21] option: allow qemu_opts_to_qdict to merge repeated options, Daniel P. Berrange, 2016/09/30
- [Qemu-devel] [PATCH v14 13/21] qdict: allow qdict_crumple to accept compound types as values, Daniel P. Berrange, 2016/09/30
- [Qemu-devel] [PATCH v14 14/21] qapi: allow repeated opts with qobject_input_visitor_new_opts, Daniel P. Berrange, 2016/09/30
- [Qemu-devel] [PATCH v14 15/21] qom: support non-scalar properties with -object, Daniel P. Berrange, 2016/09/30
- [Qemu-devel] [PATCH v14 17/21] numa: convert to use QObjectInputVisitor for -numa, Daniel P. Berrange, 2016/09/30
- [Qemu-devel] [PATCH v14 18/21] block: convert crypto driver to use QObjectInputVisitor, Daniel P. Berrange, 2016/09/30
- [Qemu-devel] [PATCH v14 16/21] hmp: support non-scalar properties with object_add, Daniel P. Berrange, 2016/09/30
- [Qemu-devel] [PATCH v14 19/21] acpi: convert to QObjectInputVisitor for -acpi parsing,
Daniel P. Berrange <=
- [Qemu-devel] [PATCH v14 20/21] net: convert to QObjectInputVisitor for -net/-netdev parsing, Daniel P. Berrange, 2016/09/30
- [Qemu-devel] [PATCH v14 21/21] qapi: delete unused OptsVisitor code, Daniel P. Berrange, 2016/09/30
- Re: [Qemu-devel] [PATCH v14 00/21] QAPI/QOM work for non-scalar object properties, no-reply, 2016/09/30