aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/interface_api.c
diff options
context:
space:
mode:
authorNeale Ranns <nranns@cisco.com>2020-04-08 12:19:38 +0000
committerNeale Ranns <nranns@cisco.com>2020-04-23 08:15:53 +0000
commit59f71132edffcfa1b94c400736575bd55bdbd7d7 (patch)
treefebcf6fad99ef594d97a3b28806fc3a1a69b8b73 /src/vnet/interface_api.c
parentc87fbb417a580bf8e93d0176dba6a90b3cd6a787 (diff)
ip: Replace Sematics for Interface IP addresses
Type: feature - replace functions for prefixes attached to interfaces - add ip_interface.[ch] to consoldate the functions Signed-off-by: Neale Ranns <nranns@cisco.com> Change-Id: I9c0c39c09dbf80ea1aadefee02c9bd16f094b6ad
Diffstat (limited to 'src/vnet/interface_api.c')
-rw-r--r--src/vnet/interface_api.c32
1 files changed, 30 insertions, 2 deletions
diff --git a/src/vnet/interface_api.c b/src/vnet/interface_api.c
index 4ce0a9ab053..5b24a29efc9 100644
--- a/src/vnet/interface_api.c
+++ b/src/vnet/interface_api.c
@@ -79,8 +79,12 @@ _(CREATE_LOOPBACK_INSTANCE, create_loopback_instance) \
_(DELETE_LOOPBACK, delete_loopback) \
_(INTERFACE_NAME_RENUMBER, interface_name_renumber) \
_(COLLECT_DETAILED_INTERFACE_STATS, collect_detailed_interface_stats) \
-_(SW_INTERFACE_SET_IP_DIRECTED_BROADCAST, \
- sw_interface_set_ip_directed_broadcast)
+_(SW_INTERFACE_SET_IP_DIRECTED_BROADCAST, \
+ sw_interface_set_ip_directed_broadcast) \
+_(SW_INTERFACE_ADDRESS_REPLACE_BEGIN, \
+ sw_interface_address_replace_begin) \
+_(SW_INTERFACE_ADDRESS_REPLACE_END, \
+ sw_interface_address_replace_end)
static void
vl_api_sw_interface_set_flags_t_handler (vl_api_sw_interface_set_flags_t * mp)
@@ -1366,6 +1370,30 @@ static void
REPLY_MACRO (VL_API_COLLECT_DETAILED_INTERFACE_STATS_REPLY);
}
+static void
+ vl_api_sw_interface_address_replace_begin_t_handler
+ (vl_api_sw_interface_address_replace_begin_t * mp)
+{
+ vl_api_sw_interface_address_replace_begin_reply_t *rmp;
+ int rv = 0;
+
+ ip_interface_address_mark ();
+
+ REPLY_MACRO (VL_API_SW_INTERFACE_ADDRESS_REPLACE_BEGIN_REPLY);
+}
+
+static void
+ vl_api_sw_interface_address_replace_end_t_handler
+ (vl_api_sw_interface_address_replace_end_t * mp)
+{
+ vl_api_sw_interface_address_replace_end_reply_t *rmp;
+ int rv = 0;
+
+ ip_interface_address_sweep ();
+
+ REPLY_MACRO (VL_API_SW_INTERFACE_ADDRESS_REPLACE_END_REPLY);
+}
+
/*
* vpe_api_hookup
* Add vpe's API message handlers to the table.