[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-block] [PATCH v14 17/19] acpi: convert to QObjectInputVisitor for
From: |
Daniel P. Berrange |
Subject: |
[Qemu-block] [PATCH v14 17/19] acpi: convert to QObjectInputVisitor for -acpi parsing |
Date: |
Tue, 27 Sep 2016 14:13:19 +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..480d3dd 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, &err);
+ if (err) {
+ goto out;
}
+ visit_type_AcpiTableOptions(v, NULL, &hdrs, &err);
+ visit_free(v);
if (err) {
goto out;
--
2.7.4
- [Qemu-block] [PATCH v14 06/19] qapi: rename QmpOutputVisitor to QObjectOutputVisitor, (continued)
- [Qemu-block] [PATCH v14 06/19] qapi: rename QmpOutputVisitor to QObjectOutputVisitor, Daniel P. Berrange, 2016/09/27
- [Qemu-block] [PATCH v14 09/19] qapi: permit auto-creating single element lists, Daniel P. Berrange, 2016/09/27
- [Qemu-block] [PATCH v14 10/19] qapi: permit auto-creating nested structs, Daniel P. Berrange, 2016/09/27
- [Qemu-block] [PATCH v14 11/19] qapi: add integer range support for QObjectInputVisitor, Daniel P. Berrange, 2016/09/27
- [Qemu-block] [PATCH v14 13/19] qom: support non-scalar properties with -object, Daniel P. Berrange, 2016/09/27
- [Qemu-block] [PATCH v14 14/19] hmp: support non-scalar properties with object_add, Daniel P. Berrange, 2016/09/27
- [Qemu-block] [PATCH v14 12/19] qapi: allow QObjectInputVisitor to be created with QemuOpts, Daniel P. Berrange, 2016/09/27
- [Qemu-block] [PATCH v14 16/19] block: convert crypto driver to use QObjectInputVisitor, Daniel P. Berrange, 2016/09/27
- [Qemu-block] [PATCH v14 15/19] numa: convert to use QObjectInputVisitor for -numa, Daniel P. Berrange, 2016/09/27
- [Qemu-block] [PATCH v14 18/19] net: convert to QObjectInputVisitor for -net/-netdev parsing, Daniel P. Berrange, 2016/09/27
- [Qemu-block] [PATCH v14 17/19] acpi: convert to QObjectInputVisitor for -acpi parsing,
Daniel P. Berrange <=
- [Qemu-block] [PATCH v14 19/19] qapi: delete unused OptsVisitor code, Daniel P. Berrange, 2016/09/27