]> xenbits.xensource.com Git - libvirt.git/commitdiff
New APIs for checking some object properties
authorDaniel P. Berrange <berrange@redhat.com>
Wed, 21 Oct 2009 10:49:05 +0000 (11:49 +0100)
committerDaniel P. Berrange <berrange@redhat.com>
Tue, 10 Nov 2009 17:00:26 +0000 (17:00 +0000)
Introduce a number of new APIs to  expose some boolean properties
of objects, which cannot otherwise reliably determined, nor are
aspects of the XML configuration.

 * virDomainIsActive: Checking virDomainGetID is not reliable
   since it is not possible to distinguish between error condition
   and inactive domain for ID of -1.
 * virDomainIsPersistent: Check whether a persistent config exists
   for the domain

 * virNetworkIsActive: Check whether the network is active
 * virNetworkIsPersistent: Check whether a persistent config exists
   for the network

 * virStoragePoolIsActive: Check whether the storage pool is active
 * virStoragePoolIsPersistent: Check whether a persistent config exists
   for the storage pool

 * virInterfaceIsActive: Check whether the host interface is active

 * virConnectIsSecure: whether the communication channel to the
   hypervisor is secure
 * virConnectIsEncrypted: whether any network based commnunication
   channels are encrypted

NB, a channel can be secure, even if not encrypted, eg if it does
not involve the network, like a UNIX socket, or pipe.

 * include/libvirt/libvirt.h.in: Define public API
 * src/driver.h: Define internal driver API
 * src/libvirt.c: Implement public API entry point
 * src/libvirt_public.syms: Export API symbols
 * src/esx/esx_driver.c, src/lxc/lxc_driver.c,
   src/interface/netcf_driver.c, src/network/bridge_driver.c,
   src/opennebula/one_driver.c, src/openvz/openvz_driver.c,
   src/phyp/phyp_driver.c, src/qemu/qemu_driver.c,
   src/remote/remote_driver.c, src/test/test_driver.c,
   src/uml/uml_driver.c, src/vbox/vbox_tmpl.c,
   src/xen/xen_driver.c: Stub out driver tables

17 files changed:
include/libvirt/libvirt.h.in
src/driver.h
src/esx/esx_driver.c
src/interface/netcf_driver.c
src/libvirt.c
src/libvirt_public.syms
src/lxc/lxc_driver.c
src/network/bridge_driver.c
src/opennebula/one_driver.c
src/openvz/openvz_driver.c
src/phyp/phyp_driver.c
src/qemu/qemu_driver.c
src/remote/remote_driver.c
src/test/test_driver.c
src/uml/uml_driver.c
src/vbox/vbox_tmpl.c
src/xen/xen_driver.c

index 7e75bee3f38ce2963a25611e111cd4cd963cc676..311ee838ec9904d8c9c346e757ed1847553d17a7 100644 (file)
@@ -1653,6 +1653,22 @@ int virStreamAbort(virStreamPtr st);
 int virStreamFree(virStreamPtr st);
 
 
+int virDomainIsActive(virDomainPtr dom);
+int virDomainIsPersistent(virDomainPtr dom);
+
+int virNetworkIsActive(virNetworkPtr net);
+int virNetworkIsPersistent(virNetworkPtr net);
+
+int virStoragePoolIsActive(virStoragePoolPtr pool);
+int virStoragePoolIsPersistent(virStoragePoolPtr pool);
+
+int virInterfaceIsActive(virInterfacePtr iface);
+
+int virConnectIsEncrypted(virConnectPtr conn);
+int virConnectIsSecure(virConnectPtr conn);
+
+
+
 #ifdef __cplusplus
 }
 #endif
index d4a8b960a1378fcf5fd5b3d922cb5933280285f4..a9fedc2d316020d724eba082e1beecba96cb7f61 100644 (file)
@@ -337,6 +337,15 @@ typedef int
                      unsigned long resource,
                      const char *dom_xml);
 
+typedef int
+    (*virDrvConnectIsEncrypted)(virConnectPtr conn);
+typedef int
+    (*virDrvConnectIsSecure)(virConnectPtr conn);
+typedef int
+    (*virDrvDomainIsActive)(virDomainPtr dom);
+typedef int
+    (*virDrvDomainIsPersistent)(virDomainPtr dom);
+
 /**
  * _virDriver:
  *
@@ -418,6 +427,10 @@ struct _virDriver {
     virDrvNodeDeviceReAttach    nodeDeviceReAttach;
     virDrvNodeDeviceReset       nodeDeviceReset;
     virDrvDomainMigratePrepareTunnel domainMigratePrepareTunnel;
+    virDrvConnectIsEncrypted   isEncrypted;
+    virDrvConnectIsSecure      isSecure;
+    virDrvDomainIsActive       domainIsActive;
+    virDrvDomainIsPersistent   domainIsPersistent;
 };
 
 typedef int
@@ -462,6 +475,12 @@ typedef int
         (*virDrvNetworkSetAutostart)   (virNetworkPtr network,
                                          int autostart);
 
+typedef int
+        (*virDrvNetworkIsActive)(virNetworkPtr net);
+typedef int
+        (*virDrvNetworkIsPersistent)(virNetworkPtr net);
+
+
 
 typedef struct _virNetworkDriver virNetworkDriver;
 typedef virNetworkDriver *virNetworkDriverPtr;
@@ -495,6 +514,8 @@ struct _virNetworkDriver {
         virDrvNetworkGetBridgeName     networkGetBridgeName;
         virDrvNetworkGetAutostart      networkGetAutostart;
         virDrvNetworkSetAutostart      networkSetAutostart;
+        virDrvNetworkIsActive           networkIsActive;
+        virDrvNetworkIsPersistent       networkIsPersistent;
 };
 
 /*-------*/
@@ -534,6 +555,10 @@ typedef int
         (*virDrvInterfaceDestroy)       (virInterfacePtr iface,
                                          unsigned int flags);
 
+typedef int
+        (*virDrvInterfaceIsActive)(virInterfacePtr iface);
+
+
 typedef struct _virInterfaceDriver virInterfaceDriver;
 typedef virInterfaceDriver *virInterfaceDriverPtr;
 
@@ -562,6 +587,7 @@ struct _virInterfaceDriver {
     virDrvInterfaceUndefine          interfaceUndefine;
     virDrvInterfaceCreate            interfaceCreate;
     virDrvInterfaceDestroy           interfaceDestroy;
+    virDrvInterfaceIsActive          interfaceIsActive;
 };
 
 
@@ -668,6 +694,12 @@ typedef virStorageVolPtr
                                               virStorageVolPtr clone,
                                               unsigned int flags);
 
+typedef int
+        (*virDrvStoragePoolIsActive)(virStoragePoolPtr pool);
+typedef int
+        (*virDrvStoragePoolIsPersistent)(virStoragePoolPtr pool);
+
+
 
 typedef struct _virStorageDriver virStorageDriver;
 typedef virStorageDriver *virStorageDriverPtr;
@@ -719,6 +751,8 @@ struct _virStorageDriver {
     virDrvStorageVolGetInfo volGetInfo;
     virDrvStorageVolGetXMLDesc volGetXMLDesc;
     virDrvStorageVolGetPath volGetPath;
+    virDrvStoragePoolIsActive   poolIsActive;
+    virDrvStoragePoolIsPersistent   poolIsPersistent;
 };
 
 #ifdef WITH_LIBVIRTD
index f81f744108e222c5d56f5ac0e81722ea80cae1c1..85e69455aeb0a857a8d2eb1e7d111a77ca4c4dce 100644 (file)
@@ -3313,6 +3313,10 @@ static virDriver esxDriver = {
     NULL,                            /* nodeDeviceReAttach */
     NULL,                            /* nodeDeviceReset */
     NULL,                            /* domainMigratePrepareTunnel */
+    NULL, /* isEncrypted */
+    NULL, /* isSecure */
+    NULL, /* domainIsActive */
+    NULL, /* domainIsPersistent */
 };
 
 
index b5c3664c9172861dfdd4b00ce2d9b5a8c3201191..7fea0574b64eb4e62d182c55d8b1a19797c88d61 100644 (file)
@@ -526,6 +526,7 @@ static virInterfaceDriver interfaceDriver = {
     interfaceUndefine,               /* interfaceUndefine */
     interfaceCreate,                 /* interfaceCreate */
     interfaceDestroy,                /* interfaceDestroy */
+    NULL,                            /* interfaceIsActive */
 };
 
 int interfaceRegister(void) {
index 9e80e29ef74c936005066dc5f4e3fc11abac5246..4598f26ce01c3bb490beaf9353612549500230d8 100644 (file)
@@ -10334,3 +10334,313 @@ int virStreamFree(virStreamPtr stream)
         return (-1);
     return (0);
 }
+
+
+/**
+ * virDomainIsActive:
+ * @dom: pointer to the domain object
+ *
+ * Determine if the domain is currently running
+ *
+ * Returns 1 if running, 0 if inactive, -1 on error
+ */
+int virDomainIsActive(virDomainPtr dom)
+{
+    DEBUG("dom=%p", dom);
+
+    virResetLastError();
+
+    if (!VIR_IS_CONNECTED_DOMAIN(dom)) {
+        virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__);
+        return (-1);
+    }
+    if (dom->conn->driver->domainIsActive) {
+        int ret;
+        ret = dom->conn->driver->domainIsActive(dom);
+        if (ret < 0)
+            goto error;
+        return ret;
+    }
+
+    virLibConnError(dom->conn, VIR_ERR_NO_SUPPORT, __FUNCTION__);
+error:
+    /* Copy to connection error object for back compatability */
+    virSetConnError(dom->conn);
+    return -1;
+}
+
+/**
+ * virDomainIsPersistent:
+ * @dom: pointer to the domain object
+ *
+ * Determine if the domain has a persistent configuration
+ * which means it will still exist after shutting down
+ *
+ * Returns 1 if persistent, 0 if transient, -1 on error
+ */
+int virDomainIsPersistent(virDomainPtr dom)
+{
+    DEBUG("dom=%p", dom);
+
+    virResetLastError();
+
+    if (!VIR_IS_CONNECTED_DOMAIN(dom)) {
+        virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__);
+        return (-1);
+    }
+    if (dom->conn->driver->domainIsPersistent) {
+        int ret;
+        ret = dom->conn->driver->domainIsPersistent(dom);
+        if (ret < 0)
+            goto error;
+        return ret;
+    }
+
+    virLibConnError(dom->conn, VIR_ERR_NO_SUPPORT, __FUNCTION__);
+error:
+    /* Copy to connection error object for back compatability */
+    virSetConnError(dom->conn);
+    return -1;
+}
+
+/**
+ * virNetworkIsActive:
+ * @net: pointer to the network object
+ *
+ * Determine if the network is currently running
+ *
+ * Returns 1 if running, 0 if inactive, -1 on error
+ */
+int virNetworkIsActive(virNetworkPtr net)
+{
+    DEBUG("net=%p", net);
+
+    virResetLastError();
+
+    if (!VIR_IS_CONNECTED_NETWORK(net)) {
+        virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__);
+        return (-1);
+    }
+    if (net->conn->networkDriver->networkIsActive) {
+        int ret;
+        ret = net->conn->networkDriver->networkIsActive(net);
+        if (ret < 0)
+            goto error;
+        return ret;
+    }
+
+    virLibConnError(net->conn, VIR_ERR_NO_SUPPORT, __FUNCTION__);
+error:
+    /* Copy to connection error object for back compatability */
+    virSetConnError(net->conn);
+    return -1;
+}
+
+
+/**
+ * virNetworkIsPersistent:
+ * @net: pointer to the network object
+ *
+ * Determine if the network has a persistent configuration
+ * which means it will still exist after shutting down
+ *
+ * Returns 1 if persistent, 0 if transient, -1 on error
+ */
+int virNetworkIsPersistent(virNetworkPtr net)
+{
+    DEBUG("net=%p", net);
+
+    virResetLastError();
+
+    if (!VIR_IS_CONNECTED_NETWORK(net)) {
+        virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__);
+        return (-1);
+    }
+    if (net->conn->networkDriver->networkIsPersistent) {
+        int ret;
+        ret = net->conn->networkDriver->networkIsPersistent(net);
+        if (ret < 0)
+            goto error;
+        return ret;
+    }
+
+    virLibConnError(net->conn, VIR_ERR_NO_SUPPORT, __FUNCTION__);
+error:
+    /* Copy to connection error object for back compatability */
+    virSetConnError(net->conn);
+    return -1;
+}
+
+
+/**
+ * virStoragePoolIsActive:
+ * @pool: pointer to the storage pool object
+ *
+ * Determine if the storage pool is currently running
+ *
+ * Returns 1 if running, 0 if inactive, -1 on error
+ */
+int virStoragePoolIsActive(virStoragePoolPtr pool)
+{
+    DEBUG("pool=%p", pool);
+
+    virResetLastError();
+
+    if (!VIR_IS_CONNECTED_STORAGE_POOL(pool)) {
+        virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__);
+        return (-1);
+    }
+    if (pool->conn->storageDriver->poolIsActive) {
+        int ret;
+        ret = pool->conn->storageDriver->poolIsActive(pool);
+        if (ret < 0)
+            goto error;
+        return ret;
+    }
+
+    virLibConnError(pool->conn, VIR_ERR_NO_SUPPORT, __FUNCTION__);
+error:
+    /* Copy to connection error object for back compatability */
+    virSetConnError(pool->conn);
+    return -1;
+}
+
+
+/**
+ * virStoragePoolIsPersistent:
+ * @pool: pointer to the storage pool object
+ *
+ * Determine if the storage pool has a persistent configuration
+ * which means it will still exist after shutting down
+ *
+ * Returns 1 if persistent, 0 if transient, -1 on error
+ */
+int virStoragePoolIsPersistent(virStoragePoolPtr pool)
+{
+    DEBUG("pool=%p", pool);
+
+    virResetLastError();
+
+    if (!VIR_IS_CONNECTED_STORAGE_POOL(pool)) {
+        virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__);
+        return (-1);
+    }
+    if (pool->conn->storageDriver->poolIsPersistent) {
+        int ret;
+        ret = pool->conn->storageDriver->poolIsPersistent(pool);
+        if (ret < 0)
+            goto error;
+        return ret;
+    }
+
+    virLibConnError(pool->conn, VIR_ERR_NO_SUPPORT, __FUNCTION__);
+error:
+    /* Copy to connection error object for back compatability */
+    virSetConnError(pool->conn);
+    return -1;
+}
+
+
+/**
+ * virInterfaceIsActive:
+ * @iface: pointer to the interface object
+ *
+ * Determine if the interface is currently running
+ *
+ * Returns 1 if running, 0 if inactive, -1 on error
+ */
+int virInterfaceIsActive(virInterfacePtr iface)
+{
+    DEBUG("iface=%p", iface);
+
+    virResetLastError();
+
+    if (!VIR_IS_CONNECTED_INTERFACE(iface)) {
+        virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__);
+        return (-1);
+    }
+    if (iface->conn->interfaceDriver->interfaceIsActive) {
+        int ret;
+        ret = iface->conn->interfaceDriver->interfaceIsActive(iface);
+        if (ret < 0)
+            goto error;
+        return ret;
+    }
+
+    virLibConnError(iface->conn, VIR_ERR_NO_SUPPORT, __FUNCTION__);
+error:
+    /* Copy to connection error object for back compatability */
+    virSetConnError(iface->conn);
+    return -1;
+}
+
+
+/**
+ * virConnectIsEncrypted:
+ * @conn: pointer to the connection object
+ *
+ * Determine if the connection to the hypervisor is encrypted
+ *
+ * Returns 1 if encrypted, 0 if not encrypted, -1 on error
+ */
+int virConnectIsEncrypted(virConnectPtr conn)
+{
+    DEBUG("conn=%p", conn);
+
+    virResetLastError();
+
+    if (!VIR_IS_CONNECT(conn)) {
+        virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__);
+        return (-1);
+    }
+    if (conn->driver->isEncrypted) {
+        int ret;
+        ret = conn->driver->isEncrypted(conn);
+        if (ret < 0)
+            goto error;
+        return ret;
+    }
+
+    virLibConnError(conn, VIR_ERR_NO_SUPPORT, __FUNCTION__);
+error:
+    /* Copy to connection error object for back compatability */
+    virSetConnError(conn);
+    return -1;
+}
+
+/**
+ * virConnectIsSecure:
+ * @conn: pointer to the connection object
+ *
+ * Determine if the connection to the hypervisor is secure
+ *
+ * A connection will be classed as secure if it is either
+ * encrypted, or running over a channel which is not exposed
+ * to eavesdropping (eg a UNIX domain socket, or pipe)
+ *
+ * Returns 1 if secure, 0 if secure, -1 on error
+ */
+int virConnectIsSecure(virConnectPtr conn)
+{
+    DEBUG("conn=%p", conn);
+
+    virResetLastError();
+
+    if (!VIR_IS_CONNECT(conn)) {
+        virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__);
+        return (-1);
+    }
+    if (conn->driver->isSecure) {
+        int ret;
+        ret = conn->driver->isSecure(conn);
+        if (ret < 0)
+            goto error;
+        return ret;
+    }
+
+    virLibConnError(conn, VIR_ERR_NO_SUPPORT, __FUNCTION__);
+error:
+    /* Copy to connection error object for back compatability */
+    virSetConnError(conn);
+    return -1;
+}
index 8921c1a5d025471e19d808f0bdb8dc69cb8063cc..739f8b0ab77831806fb47067ca9027ffce1eb5c2 100644 (file)
@@ -329,4 +329,17 @@ LIBVIRT_0.7.2 {
        virDomainMigrateToURI;
 } LIBVIRT_0.7.1;
 
+LIBVIRT_0.7.3 {
+    global:
+       virConnectIsEncrypted;
+       virConnectIsSecure;
+       virDomainIsActive;
+       virDomainIsPersistent;
+       virNetworkIsActive;
+       virNetworkIsPersistent;
+       virStoragePoolIsActive;
+       virStoragePoolIsPersistent;
+       virInterfaceIsActive;
+} LIBVIRT_0.7.2;
+
 # .... define new API here using predicted next version number ....
index f44901c76d290429d7a26a8ab0d86b006bdc556b..f326d8cf82aeb52ffdd8c10b3a6150ae882bf035 100644 (file)
@@ -2278,6 +2278,10 @@ static virDriver lxcDriver = {
     NULL, /* nodeDeviceReAttach */
     NULL, /* nodeDeviceReset */
     NULL, /* domainMigratePrepareTunnel */
+    NULL, /* isEncrypted */
+    NULL, /* isSecure */
+    NULL, /* domainIsActive */
+    NULL, /* domainIsPersistent */
 };
 
 static virStateDriver lxcStateDriver = {
index 109febda70c9ae6f107f802e812dcf311c93ba73..8f4cdfb2c18a20a3971c22f34f4a77f747cd29bb 100644 (file)
@@ -1515,6 +1515,8 @@ static virNetworkDriver networkDriver = {
     networkGetBridgeName, /* networkGetBridgeName */
     networkGetAutostart, /* networkGetAutostart */
     networkSetAutostart, /* networkSetAutostart */
+    NULL, /* networkIsActive */
+    NULL, /* networkIsPersistent */
 };
 
 static virStateDriver networkStateDriver = {
index f461ff6bf692165e3217060836e3500ccbae2a26..b721e2f732872eb63becc36afbc306ec197fde7b 100644 (file)
@@ -761,6 +761,10 @@ static virDriver oneDriver = {
     NULL, /* nodeDeviceReAttach; */
     NULL, /* nodeDeviceReset; */
     NULL, /* domainMigratePrepareTunnel */
+    NULL, /* isEncrypted */
+    NULL, /* isSecure */
+    NULL, /* domainIsActive */
+    NULL, /* domainIsPersistent */
 };
 
 static virStateDriver oneStateDriver = {
index 467c03bbe0878212cbd1ff402911b0e8e2724c9e..f05f99045426a144e0b429a6b7042aa1aa267dc0 100644 (file)
@@ -1471,6 +1471,10 @@ static virDriver openvzDriver = {
     NULL, /* nodeDeviceReAttach */
     NULL, /* nodeDeviceReset */
     NULL, /* domainMigratePrepareTunnel */
+    NULL, /* isEncrypted */
+    NULL, /* isSecure */
+    NULL, /* domainIsActive */
+    NULL, /* domainIsPersistent */
 };
 
 int openvzRegister(void) {
index 702d51bf3c61a0f79f38c4b71005191446144f88..95b086c1c2cd31a10302de948212fcb0cf60b0ee 100644 (file)
@@ -1625,6 +1625,10 @@ virDriver phypDriver = {
     NULL,                       /* nodeDeviceReAttach */
     NULL,                       /* nodeDeviceReset */
     NULL,                       /* domainMigratePrepareTunnel */
+    NULL, /* isEncrypted */
+    NULL, /* isSecure */
+    NULL, /* domainIsActive */
+    NULL, /* domainIsPersistent */
 };
 
 int
index 7d20a545d5005a91cb31d72f390263fbc68b3c56..4a054af2fdea547900c60cd7646a6d5c4b434c67 100644 (file)
@@ -7465,6 +7465,10 @@ static virDriver qemuDriver = {
     qemudNodeDeviceReAttach, /* nodeDeviceReAttach */
     qemudNodeDeviceReset, /* nodeDeviceReset */
     qemudDomainMigratePrepareTunnel, /* domainMigratePrepareTunnel */
+    NULL, /* isEncrypted */
+    NULL, /* isSecure */
+    NULL, /* domainIsActive */
+    NULL, /* domainIsPersistent */
 };
 
 
index ba111d872ad5a7e6663284cd27bd0de440a465b3..e851532029a2c70d144e9afa674302996a48f724 100644 (file)
@@ -8554,6 +8554,10 @@ static virDriver remote_driver = {
     remoteNodeDeviceReAttach, /* nodeDeviceReAttach */
     remoteNodeDeviceReset, /* nodeDeviceReset */
     remoteDomainMigratePrepareTunnel, /* domainMigratePrepareTunnel */
+    NULL, /* isEncrypted */
+    NULL, /* isSecure */
+    NULL, /* domainIsActive */
+    NULL, /* domainIsPersistent */
 };
 
 static virNetworkDriver network_driver = {
@@ -8575,6 +8579,8 @@ static virNetworkDriver network_driver = {
     .networkGetBridgeName = remoteNetworkGetBridgeName,
     .networkGetAutostart = remoteNetworkGetAutostart,
     .networkSetAutostart = remoteNetworkSetAutostart,
+    .networkIsActive = NULL,
+    .networkIsPersistent = NULL,
 };
 
 static virInterfaceDriver interface_driver = {
@@ -8592,6 +8598,7 @@ static virInterfaceDriver interface_driver = {
     .interfaceUndefine = remoteInterfaceUndefine,
     .interfaceCreate = remoteInterfaceCreate,
     .interfaceDestroy = remoteInterfaceDestroy,
+    .interfaceIsActive = NULL, /* interfaceIsActive */
 };
 
 static virStorageDriver storage_driver = {
@@ -8630,6 +8637,9 @@ static virStorageDriver storage_driver = {
     .volGetInfo = remoteStorageVolGetInfo,
     .volGetXMLDesc = remoteStorageVolDumpXML,
     .volGetPath = remoteStorageVolGetPath,
+
+    .poolIsActive = NULL, /* poolIsActive */
+    .poolIsPersistent = NULL, /* poolIsEncrypted */
 };
 
 static virSecretDriver secret_driver = {
index fb367c9f420fa467bb4a4aa0e3faea18743e445e..4a041791fa5087c8acf8c56cdf571ac9efff9b34 100644 (file)
@@ -5064,6 +5064,10 @@ static virDriver testDriver = {
     NULL, /* nodeDeviceReAttach */
     NULL, /* nodeDeviceReset */
     NULL, /* domainMigratePrepareTunnel */
+    NULL, /* isEncrypted */
+    NULL, /* isSecure */
+    NULL, /* domainIsActive */
+    NULL, /* domainIsPersistent */
 };
 
 static virNetworkDriver testNetworkDriver = {
@@ -5085,6 +5089,8 @@ static virNetworkDriver testNetworkDriver = {
     testNetworkGetBridgeName, /* networkGetBridgeName */
     testNetworkGetAutostart, /* networkGetAutostart */
     testNetworkSetAutostart, /* networkSetAutostart */
+    NULL, /* networkIsActive */
+    NULL, /* networkIsPersistent */
 };
 
 static virInterfaceDriver testInterfaceDriver = {
@@ -5102,6 +5108,7 @@ static virInterfaceDriver testInterfaceDriver = {
     testInterfaceUndefine,      /* interfaceUndefine */
     testInterfaceCreate,        /* interfaceCreate */
     testInterfaceDestroy,       /* interfaceDestroy */
+    NULL, /* interfaceIsActive */
 };
 
 
@@ -5142,6 +5149,9 @@ static virStorageDriver testStorageDriver = {
     .volGetInfo = testStorageVolumeGetInfo,
     .volGetXMLDesc = testStorageVolumeGetXMLDesc,
     .volGetPath = testStorageVolumeGetPath,
+
+    .poolIsActive = NULL, /* poolIsActive */
+    .poolIsPersistent = NULL, /* poolIsPersistent */
 };
 
 static virDeviceMonitor testDevMonitor = {
index 6214ef8514e560d8e8a433ce68c67b33eb2b8e61..8580b48c3f330019a0cc545cb178d7304172c77d 100644 (file)
@@ -1824,6 +1824,10 @@ static virDriver umlDriver = {
     NULL, /* nodeDeviceReAttach */
     NULL, /* nodeDeviceReset */
     NULL, /* domainMigratePrepareTunnel */
+    NULL, /* isEncrypted */
+    NULL, /* isSecure */
+    NULL, /* domainIsActive */
+    NULL, /* domainIsPersistent */
 };
 
 
index 0957809ecd1701b5a70bcd900c25c203d09e18ae..2170e1bcf3f530313dd4e0adad12d75b4289a953 100644 (file)
@@ -6469,6 +6469,10 @@ virDriver NAME(Driver) = {
     NULL, /* nodeDeviceReAttach */
     NULL, /* nodeDeviceReset */
     NULL, /* domainMigratePrepareTunnel */
+    NULL, /* isEncrypted */
+    NULL, /* isSecure */
+    NULL, /* domainIsActive */
+    NULL, /* domainIsPerrsistent */
 };
 
 virNetworkDriver NAME(NetworkDriver) = {
index a83b764b39451ffaedb4328f4b179d7eff0ab2f4..a4b4d239eaa4a7c0a71cb3e9911587aee407a284 100644 (file)
@@ -1709,6 +1709,10 @@ static virDriver xenUnifiedDriver = {
     xenUnifiedNodeDeviceReAttach, /* nodeDeviceReAttach */
     xenUnifiedNodeDeviceReset, /* nodeDeviceReset */
     NULL, /* domainMigratePrepareTunnel */
+    NULL, /* isEncrypted */
+    NULL, /* isSecure */
+    NULL, /* domainIsActive */
+    NULL, /* domainIsPersistent */
 };
 
 /**