diff mbox series

[ovs-dev,v2,1/9] ofctrl: change ofctrl_dup_flow to module internal function

Message ID 1599461142-84752-2-git-send-email-hzhou@ovn.org
State Accepted
Headers show
Series Incremental processing for flow installation. | expand

Commit Message

Han Zhou Sept. 7, 2020, 6:45 a.m. UTC
Signed-off-by: Han Zhou <hzhou@ovn.org>
---
 controller/ofctrl.c | 8 +++++---
 controller/ofctrl.h | 2 --
 2 files changed, 5 insertions(+), 5 deletions(-)
diff mbox series

Patch

diff --git a/controller/ofctrl.c b/controller/ofctrl.c
index b8a9c2d..919db6d 100644
--- a/controller/ofctrl.c
+++ b/controller/ofctrl.c
@@ -169,6 +169,8 @@  static struct ofpbuf *encode_meter_mod(const struct ofputil_meter_mod *);
 
 static void ovn_installed_flow_table_clear(void);
 static void ovn_installed_flow_table_destroy(void);
+static struct ovn_flow *ovn_flow_dup(struct ovn_flow *source);
+
 
 static void ofctrl_recv(const struct ofp_header *, enum ofptype);
 
@@ -787,8 +789,8 @@  ovn_flow_match_hash(const struct ovn_flow *f)
 }
 
 /* Duplicate an ovn_flow structure. */
-struct ovn_flow *
-ofctrl_dup_flow(struct ovn_flow *src)
+static struct ovn_flow *
+ovn_flow_dup(struct ovn_flow *src)
 {
     struct ovn_flow *dst = xmalloc(sizeof *dst);
     dst->table_id = src->table_id;
@@ -1291,7 +1293,7 @@  ofctrl_put(struct ovn_desired_flow_table *flow_table,
             ovn_flow_log(d, "adding installed");
 
             /* Copy 'd' from 'flow_table' to installed_flows. */
-            struct ovn_flow *new_node = ofctrl_dup_flow(d);
+            struct ovn_flow *new_node = ovn_flow_dup(d);
             hmap_insert(&installed_flows, &new_node->match_hmap_node,
                         new_node->match_hmap_node.hash);
         }
diff --git a/controller/ofctrl.h b/controller/ofctrl.h
index 21d2ce6..37f06db 100644
--- a/controller/ofctrl.h
+++ b/controller/ofctrl.h
@@ -56,8 +56,6 @@  void ofctrl_wait(void);
 void ofctrl_destroy(void);
 int64_t ofctrl_get_cur_cfg(void);
 
-struct ovn_flow *ofctrl_dup_flow(struct ovn_flow *source);
-
 void ofctrl_ct_flush_zone(uint16_t zone_id);
 
 char *ofctrl_inject_pkt(const struct ovsrec_bridge *br_int,