mirror of
https://gitlab.com/qemu-project/qemu.git
synced 2026-05-06 04:16:46 -04:00
qom: Declare compat properties API in 'qom/compat-properties.h'
While most of QEMU files use the QOM concept, few of them use the compatibility properties API (mostly use in system emulation). Move its prototype to a new "qom/compat-properties.h" header, keeping "qom/object.h" for generic QOM. Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org> Reviewed-by: Michael Tokarev <mjt@tls.msk.ru> Message-Id: <20260325151728.45378-5-philmd@linaro.org>
This commit is contained in:
@@ -25,6 +25,7 @@
|
||||
|
||||
#include "qemu/osdep.h"
|
||||
#include "qemu/accel.h"
|
||||
#include "qom/compat-properties.h"
|
||||
#include "qapi/qapi-commands-accelerator.h"
|
||||
#include "monitor/monitor.h"
|
||||
#include "hw/core/boards.h"
|
||||
|
||||
@@ -18,6 +18,7 @@
|
||||
#include "qapi/qapi-builtin-visit.h"
|
||||
#include "qapi/visitor.h"
|
||||
#include "qemu/config-file.h"
|
||||
#include "qom/compat-properties.h"
|
||||
#include "qom/object_interfaces.h"
|
||||
#include "qemu/mmap-alloc.h"
|
||||
#include "qemu/madvise.h"
|
||||
|
||||
@@ -21,6 +21,7 @@
|
||||
#include "qapi/qapi-visit-machine.h"
|
||||
#include "qapi/qapi-commands-machine.h"
|
||||
#include "qemu/madvise.h"
|
||||
#include "qom/compat-properties.h"
|
||||
#include "qom/object_interfaces.h"
|
||||
#include "system/cpus.h"
|
||||
#include "system/system.h"
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
#include "qemu/units.h"
|
||||
#include "qemu/cutils.h"
|
||||
#include "qdev-prop-internal.h"
|
||||
#include "qom/compat-properties.h"
|
||||
#include "qom/qom-qobject.h"
|
||||
|
||||
void qdev_prop_set_after_realize(DeviceState *dev, const char *name,
|
||||
|
||||
@@ -32,6 +32,7 @@
|
||||
#include "qapi/visitor.h"
|
||||
#include "qemu/error-report.h"
|
||||
#include "qemu/option.h"
|
||||
#include "qom/compat-properties.h"
|
||||
#include "hw/core/irq.h"
|
||||
#include "hw/core/qdev-properties.h"
|
||||
#include "hw/core/boards.h"
|
||||
|
||||
@@ -56,6 +56,7 @@
|
||||
#include "hw/usb/hcd-uhci.h"
|
||||
#include "qapi/error.h"
|
||||
#include "qemu/error-report.h"
|
||||
#include "qom/compat-properties.h"
|
||||
#include "system/numa.h"
|
||||
#include "hw/hyperv/vmbus-bridge.h"
|
||||
#include "hw/mem/nvdimm.h"
|
||||
|
||||
@@ -29,4 +29,12 @@ typedef struct GlobalProperty {
|
||||
bool optional;
|
||||
} GlobalProperty;
|
||||
|
||||
void object_set_machine_compat_props(GPtrArray *compat_props);
|
||||
void object_set_accelerator_compat_props(GPtrArray *compat_props);
|
||||
void object_register_sugar_prop(const char *driver, const char *prop,
|
||||
const char *value, bool optional);
|
||||
void object_apply_compat_props(Object *obj);
|
||||
bool object_apply_global_props(Object *obj, const GPtrArray *props,
|
||||
Error **errp);
|
||||
|
||||
#endif
|
||||
|
||||
@@ -700,14 +700,6 @@ Object *object_new_with_propv(const char *typename,
|
||||
Error **errp,
|
||||
va_list vargs);
|
||||
|
||||
bool object_apply_global_props(Object *obj, const GPtrArray *props,
|
||||
Error **errp);
|
||||
void object_set_machine_compat_props(GPtrArray *compat_props);
|
||||
void object_set_accelerator_compat_props(GPtrArray *compat_props);
|
||||
void object_register_sugar_prop(const char *driver, const char *prop,
|
||||
const char *value, bool optional);
|
||||
void object_apply_compat_props(Object *obj);
|
||||
|
||||
/**
|
||||
* object_set_props:
|
||||
* @obj: the object instance to set properties on
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
clippy::too_many_arguments
|
||||
)]
|
||||
|
||||
use glib_sys::{GHashTable, GHashTableIter, GPtrArray, GSList};
|
||||
use glib_sys::{GHashTable, GHashTableIter, GSList};
|
||||
use util_sys::{Error, QDict, QObject, Visitor};
|
||||
|
||||
#[cfg(MESON)]
|
||||
|
||||
@@ -28,6 +28,7 @@
|
||||
#include "qemu/error-report.h"
|
||||
#include "qemu/option.h"
|
||||
#include "qemu/timer.h"
|
||||
#include "qom/compat-properties.h"
|
||||
#include "qom/object.h"
|
||||
#include "system/replay.h"
|
||||
#include "system/system.h"
|
||||
|
||||
@@ -119,6 +119,7 @@
|
||||
#include "qapi/string-input-visitor.h"
|
||||
#include "qapi/opts-visitor.h"
|
||||
#include "qapi/clone-visitor.h"
|
||||
#include "qom/compat-properties.h"
|
||||
#include "qom/object_interfaces.h"
|
||||
#include "semihosting/semihost.h"
|
||||
#include "crypto/init.h"
|
||||
|
||||
@@ -36,6 +36,7 @@
|
||||
#include "system/reset.h"
|
||||
#include "trace.h"
|
||||
#include "migration/blocker.h"
|
||||
#include "qom/compat-properties.h"
|
||||
#include "qom/object.h"
|
||||
#include "monitor/monitor.h"
|
||||
#include "monitor/hmp.h"
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
#include "qemu/error-report.h"
|
||||
#include "qemu/option.h"
|
||||
#include "qemu/units.h"
|
||||
#include "qom/compat-properties.h"
|
||||
#include "hw/core/qdev.h"
|
||||
#include "hw/core/qdev-properties.h"
|
||||
#include "migration/blocker.h"
|
||||
|
||||
Reference in New Issue
Block a user