Re: [PATCH 2/5] network: implement RPC calls for virNetworkDefineXMLFlags

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2012年08月20日 14:17, Laine Stump wrote:
This is very short, becaquse almost everything is autogenerated. All
that's needed are:

* src/remote/remote_driver.c: add pointer to autogenerated
     remoteNetworkDefineXMLFlags to the function table for the remote
     network driver.

* src/remote/remote_protocol.x: add the "args" and "ret" structs (which are
     nearly identical to those for virNetworkDefineXML), and add one more
     item to the remote_procedure enum for this function.

* src/remote_protocol-struct: updated to match remote_protocol.x
---
  src/remote/remote_driver.c   |  1 +
  src/remote/remote_protocol.x | 12 +++++++++++-
  src/remote_protocol-structs  |  8 ++++++++
  3 files changed, 20 insertions(+), 1 deletion(-)

diff --git a/src/remote/remote_driver.c b/src/remote/remote_driver.c
index c4941c5..912233a 100644
--- a/src/remote/remote_driver.c
+++ b/src/remote/remote_driver.c
@@ -5383,6 +5383,7 @@ static virNetworkDriver network_driver = {
      .networkLookupByUUID = remoteNetworkLookupByUUID, /* 0.3.0 */
      .networkLookupByName = remoteNetworkLookupByName, /* 0.3.0 */
      .networkCreateXML = remoteNetworkCreateXML, /* 0.3.0 */
+    .networkDefineXMLFlags = remoteNetworkDefineXMLFlags, /* 0.3.0 */

It should be 0.10.0


      .networkDefineXML = remoteNetworkDefineXML, /* 0.3.0 */
      .networkUndefine = remoteNetworkUndefine, /* 0.3.0 */
      .networkCreate = remoteNetworkCreate, /* 0.3.0 */
diff --git a/src/remote/remote_protocol.x b/src/remote/remote_protocol.x
index 200fe75..94fb6cd 100644
--- a/src/remote/remote_protocol.x
+++ b/src/remote/remote_protocol.x
@@ -1280,6 +1280,15 @@ struct remote_network_create_xml_ret {
      remote_nonnull_network net;
  };

+struct remote_network_define_xml_flags_args {
+    remote_nonnull_string xml;
+    unsigned int flags;
+};
+
+struct remote_network_define_xml_flags_ret {
+    remote_nonnull_network net;
+};
+
  struct remote_network_define_xml_args {
      remote_nonnull_string xml;
  };
@@ -2854,7 +2863,8 @@ enum remote_procedure {
      REMOTE_PROC_DOMAIN_LIST_ALL_SNAPSHOTS = 274, /* skipgen skipgen priority:high */
      REMOTE_PROC_DOMAIN_SNAPSHOT_LIST_ALL_CHILDREN = 275, /* skipgen skipgen priority:high */
      REMOTE_PROC_DOMAIN_EVENT_BALLOON_CHANGE = 276, /* autogen autogen */
-    REMOTE_PROC_DOMAIN_GET_HOSTNAME = 277 /* autogen autogen */
+    REMOTE_PROC_DOMAIN_GET_HOSTNAME = 277, /* autogen autogen */
+    REMOTE_PROC_NETWORK_DEFINE_XML_FLAGS = 278 /* autogen autogen priority:high */

      /*
       * Notice how the entries are grouped in sets of 10 ?
diff --git a/src/remote_protocol-structs b/src/remote_protocol-structs
index 8d09138..693d629 100644
--- a/src/remote_protocol-structs
+++ b/src/remote_protocol-structs
@@ -930,6 +930,13 @@ struct remote_network_create_xml_args {
  struct remote_network_create_xml_ret {
          remote_nonnull_network     net;
  };
+struct remote_network_define_xml_flags_args {
+        remote_nonnull_string      xml;
+        u_int                      flags;
+};
+struct remote_network_define_xml_flags_ret {
+        remote_nonnull_network     net;
+};
  struct remote_network_define_xml_args {
          remote_nonnull_string      xml;
  };
@@ -2259,4 +2266,5 @@ enum remote_procedure {
          REMOTE_PROC_DOMAIN_SNAPSHOT_LIST_ALL_CHILDREN = 275,
          REMOTE_PROC_DOMAIN_EVENT_BALLOON_CHANGE = 276,
          REMOTE_PROC_DOMAIN_GET_HOSTNAME = 277,
+        REMOTE_PROC_NETWORK_DEFINE_XML_FLAGS = 278,
  };

ACK with the version fixed.

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list



[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]