aboutsummaryrefslogtreecommitdiff
path: root/hw/core
diff options
context:
space:
mode:
authorMarcel Apfelbaum <marcel@redhat.com>2015-01-06 15:29:13 +0200
committerPeter Maydell <peter.maydell@linaro.org>2015-01-08 17:32:27 +0000
commit5e97b623c254a2c7b1f67b21f7aede93d995f4bd (patch)
tree97b7da05aebd989ad14e0bef456fad3f415c378b /hw/core
parentf8b6f8edac926bb979bd2b1d21d896c219b522c2 (diff)
hw/machine: added machine_usb wrapper
Following QOM convention, object properties should not be accessed directly. Signed-off-by: Marcel Apfelbaum <marcel@redhat.com> Reviewed-by: Paolo Bonzini <pbonzini@redhat.com> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com> Reviewed-by: Alexander Graf <agraf@suse.de> Message-id: 1420550957-22337-3-git-send-email-marcel@redhat.com Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'hw/core')
-rw-r--r--hw/core/machine.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/hw/core/machine.c b/hw/core/machine.c
index a0ae5f94ce..fbd91be575 100644
--- a/hw/core/machine.c
+++ b/hw/core/machine.c
@@ -398,6 +398,11 @@ static void machine_finalize(Object *obj)
g_free(ms->firmware);
}
+bool machine_usb(MachineState *machine)
+{
+ return machine->usb;
+}
+
static const TypeInfo machine_info = {
.name = TYPE_MACHINE,
.parent = TYPE_OBJECT,