diff --git a/src/qemu/qemu_domain.c b/src/qemu/qemu_domain.c index 2ec23bb52f2076380e5c1add5e619f9623e21981..24e84a59660cd3198b6f7d12a075338a1510b026 100644 --- a/src/qemu/qemu_domain.c +++ b/src/qemu/qemu_domain.c @@ -1407,6 +1407,43 @@ qemuDomainNetworkPrivateDispose(void *obj G_GNUC_UNUSED) } +static virClassPtr qemuDomainFSPrivateClass; +static void qemuDomainFSPrivateDispose(void *obj); + + +static int +qemuDomainFSPrivateOnceInit(void) +{ + if (!VIR_CLASS_NEW(qemuDomainFSPrivate, virClassForObject())) + return -1; + + return 0; +} + + +VIR_ONCE_GLOBAL_INIT(qemuDomainFSPrivate); + + +static virObjectPtr +qemuDomainFSPrivateNew(void) +{ + qemuDomainFSPrivatePtr priv; + + if (qemuDomainFSPrivateInitialize() < 0) + return NULL; + + if (!(priv = virObjectNew(qemuDomainFSPrivateClass))) + return NULL; + + return (virObjectPtr) priv; +} + + +static void +qemuDomainFSPrivateDispose(void *obj G_GNUC_UNUSED) +{ +} + static virClassPtr qemuDomainVideoPrivateClass; static void qemuDomainVideoPrivateDispose(void *obj); @@ -3865,6 +3902,7 @@ virDomainXMLPrivateDataCallbacks virQEMUDriverPrivateDataCallbacks = { .graphicsNew = qemuDomainGraphicsPrivateNew, .networkNew = qemuDomainNetworkPrivateNew, .videoNew = qemuDomainVideoPrivateNew, + .fsNew = qemuDomainFSPrivateNew, .parse = qemuDomainObjPrivateXMLParse, .format = qemuDomainObjPrivateXMLFormat, .getParseOpaque = qemuDomainObjPrivateXMLGetParseOpaque, diff --git a/src/qemu/qemu_domain.h b/src/qemu/qemu_domain.h index c93bdf4099048a7f904f31d2fbbf008344e41d1a..c6afc484f6e3225450c900961251ae2e71073018 100644 --- a/src/qemu/qemu_domain.h +++ b/src/qemu/qemu_domain.h @@ -560,6 +560,18 @@ struct _qemuDomainNetworkPrivate { }; +#define QEMU_DOMAIN_FS_PRIVATE(dev) \ + ((qemuDomainFSPrivatePtr) (dev)->privateData) + +typedef struct _qemuDomainFSPrivate qemuDomainFSPrivate; +typedef qemuDomainFSPrivate *qemuDomainFSPrivatePtr; +struct _qemuDomainFSPrivate { + virObject parent; + + int dummy; +}; + + typedef enum { QEMU_PROCESS_EVENT_WATCHDOG = 0, QEMU_PROCESS_EVENT_GUESTPANIC,