summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOle Troan <ot@cisco.com>2017-05-12 11:55:35 +0200
committerJohn Lo <loj@cisco.com>2017-05-20 21:08:01 +0000
commit01384fe3d4c8f9d5c082cd602087a8eb71facd15 (patch)
treedc5be4181fea2382b068643f4e37bd866c414840
parentbb292f4d3fbecfc6b1bac695f833b0da78369116 (diff)
API: Cleaning up message naming that does not follow the conventions
is_address_reachable - Disabled so deleted cli_request - Renamed to cli vnet_summary_stats_reply - Renamed to vnet_get_summary_stats_reply bridge_domain_sw_if_details - Deleted, incorporated in main message l2_fib_table_entry - Renamed to l2_fib_table_details Change-Id: I93b7e8769a3ba7b4989b3c270270f575f386464f Signed-off-by: Ole Troan <ot@cisco.com> Signed-off-by: Marek Gradzki <mgradzki@cisco.com> Signed-off-by: Ole Troan <ot@cisco.com>
-rw-r--r--src/vat/api_format.c114
-rw-r--r--src/vnet/l2/l2.api32
-rw-r--r--src/vnet/l2/l2_api.c61
-rw-r--r--src/vpp-api/java/jvpp-core/io/fd/vpp/jvpp/core/test/FutureApiTest.java4
-rw-r--r--src/vpp-api/java/jvpp/gen/jvppgen/util.py9
-rw-r--r--src/vpp/api/api.c85
-rw-r--r--src/vpp/api/custom_dump.c8
-rw-r--r--src/vpp/api/summary_stats_client.c6
-rw-r--r--src/vpp/api/vpe.api23
9 files changed, 116 insertions, 226 deletions
diff --git a/src/vat/api_format.c b/src/vat/api_format.c
index efb71ef649a..22a91666102 100644
--- a/src/vat/api_format.c
+++ b/src/vat/api_format.c
@@ -1323,6 +1323,9 @@ vl_api_ip6_nd_event_t_handler_json (vl_api_ip6_nd_event_t * mp)
/* JSON output not supported */
}
+#define vl_api_bridge_domain_details_t_endian vl_noop_handler
+#define vl_api_bridge_domain_details_t_print vl_noop_handler
+
/*
* Special-case: build the bridge domain table, maintain
* the next bd id vbl.
@@ -1332,6 +1335,7 @@ static void vl_api_bridge_domain_details_t_handler
{
vat_main_t *vam = &vat_main;
u32 n_sw_ifs = ntohl (mp->n_sw_ifs);
+ int i;
print (vam->ofp, "\n%-3s %-3s %-3s %-3s %-3s %-3s",
" ID", "LRN", "FWD", "FLD", "BVI", "#IF");
@@ -1341,7 +1345,37 @@ static void vl_api_bridge_domain_details_t_handler
mp->flood, ntohl (mp->bvi_sw_if_index), n_sw_ifs);
if (n_sw_ifs)
- print (vam->ofp, "\n\n%s %s %s", "sw_if_index", "SHG", "Interface Name");
+ {
+ vl_api_bridge_domain_sw_if_t *sw_ifs;
+ print (vam->ofp, "\n\n%s %s %s", "sw_if_index", "SHG",
+ "Interface Name");
+
+ sw_ifs = mp->sw_if_details;
+ for (i = 0; i < n_sw_ifs; i++)
+ {
+ u8 *sw_if_name = 0;
+ u32 sw_if_index;
+ hash_pair_t *p;
+
+ sw_if_index = ntohl (sw_ifs->sw_if_index);
+
+ /* *INDENT-OFF* */
+ hash_foreach_pair (p, vam->sw_if_index_by_interface_name,
+ ({
+ if ((u32) p->value[0] == sw_if_index)
+ {
+ sw_if_name = (u8 *)(p->key);
+ break;
+ }
+ }));
+ /* *INDENT-ON* */
+ print (vam->ofp, "%7d %3d %s", sw_if_index,
+ sw_ifs->shg, sw_if_name ? (char *) sw_if_name :
+ "sw_if_index not found!");
+
+ sw_ifs++;
+ }
+ }
}
static void vl_api_bridge_domain_details_t_handler_json
@@ -1349,6 +1383,7 @@ static void vl_api_bridge_domain_details_t_handler_json
{
vat_main_t *vam = &vat_main;
vat_json_node_t *node, *array = NULL;
+ u32 n_sw_ifs = ntohl (mp->n_sw_ifs);
if (VAT_JSON_ARRAY != vam->json_tree.type)
{
@@ -1364,58 +1399,28 @@ static void vl_api_bridge_domain_details_t_handler_json
vat_json_object_add_uint (node, "learn", mp->learn);
vat_json_object_add_uint (node, "bvi_sw_if_index",
ntohl (mp->bvi_sw_if_index));
- vat_json_object_add_uint (node, "n_sw_ifs", ntohl (mp->n_sw_ifs));
+ vat_json_object_add_uint (node, "n_sw_ifs", n_sw_ifs);
array = vat_json_object_add (node, "sw_if");
vat_json_init_array (array);
-}
-
-/*
- * Special-case: build the bridge domain sw if table.
- */
-static void vl_api_bridge_domain_sw_if_details_t_handler
- (vl_api_bridge_domain_sw_if_details_t * mp)
-{
- vat_main_t *vam = &vat_main;
- hash_pair_t *p;
- u8 *sw_if_name = 0;
- u32 sw_if_index;
-
- sw_if_index = ntohl (mp->sw_if_index);
- /* *INDENT-OFF* */
- hash_foreach_pair (p, vam->sw_if_index_by_interface_name,
- ({
- if ((u32) p->value[0] == sw_if_index)
- {
- sw_if_name = (u8 *)(p->key);
- break;
- }
- }));
- /* *INDENT-ON* */
- print (vam->ofp, "%7d %3d %s", sw_if_index,
- mp->shg, sw_if_name ? (char *) sw_if_name :
- "sw_if_index not found!");
-}
-static void vl_api_bridge_domain_sw_if_details_t_handler_json
- (vl_api_bridge_domain_sw_if_details_t * mp)
-{
- vat_main_t *vam = &vat_main;
- vat_json_node_t *node = NULL;
- uword last_index = 0;
- ASSERT (VAT_JSON_ARRAY == vam->json_tree.type);
- ASSERT (vec_len (vam->json_tree.array) >= 1);
- last_index = vec_len (vam->json_tree.array) - 1;
- node = &vam->json_tree.array[last_index];
- node = vat_json_object_get_element (node, "sw_if");
- ASSERT (NULL != node);
- node = vat_json_array_add (node);
+ if (n_sw_ifs)
+ {
+ vl_api_bridge_domain_sw_if_t *sw_ifs;
+ int i;
- vat_json_init_object (node);
- vat_json_object_add_uint (node, "bd_id", ntohl (mp->bd_id));
- vat_json_object_add_uint (node, "sw_if_index", ntohl (mp->sw_if_index));
- vat_json_object_add_uint (node, "shg", mp->shg);
+ sw_ifs = mp->sw_if_details;
+ for (i = 0; i < n_sw_ifs; i++)
+ {
+ node = vat_json_array_add (array);
+ vat_json_init_object (node);
+ vat_json_object_add_uint (node, "sw_if_index",
+ ntohl (sw_ifs->sw_if_index));
+ vat_json_object_add_uint (node, "shg", sw_ifs->shg);
+ sw_ifs++;
+ }
+ }
}
static void vl_api_control_ping_reply_t_handler
@@ -4334,7 +4339,6 @@ _(SW_INTERFACE_SET_L2_BRIDGE_REPLY, \
sw_interface_set_l2_bridge_reply) \
_(BRIDGE_DOMAIN_ADD_DEL_REPLY, bridge_domain_add_del_reply) \
_(BRIDGE_DOMAIN_DETAILS, bridge_domain_details) \
-_(BRIDGE_DOMAIN_SW_IF_DETAILS, bridge_domain_sw_if_details) \
_(BRIDGE_DOMAIN_SET_MAC_AGE_REPLY, bridge_domain_set_mac_age_reply) \
_(L2FIB_ADD_DEL_REPLY, l2fib_add_del_reply) \
_(L2FIB_FLUSH_INT_REPLY, l2fib_flush_int_reply) \
@@ -4409,7 +4413,7 @@ _(CREATE_VHOST_USER_IF_REPLY, create_vhost_user_if_reply) \
_(MODIFY_VHOST_USER_IF_REPLY, modify_vhost_user_if_reply) \
_(DELETE_VHOST_USER_IF_REPLY, delete_vhost_user_if_reply) \
_(SHOW_VERSION_REPLY, show_version_reply) \
-_(L2_FIB_TABLE_ENTRY, l2_fib_table_entry) \
+_(L2_FIB_TABLE_DETAILS, l2_fib_table_details) \
_(VXLAN_GPE_ADD_DEL_TUNNEL_REPLY, vxlan_gpe_add_del_tunnel_reply) \
_(VXLAN_GPE_TUNNEL_DETAILS, vxlan_gpe_tunnel_details) \
_(INTERFACE_NAME_RENUMBER_REPLY, interface_name_renumber_reply) \
@@ -4935,7 +4939,7 @@ int
exec (vat_main_t * vam)
{
api_main_t *am = &api_main;
- vl_api_cli_request_t *mp;
+ vl_api_cli_t *mp;
f64 timeout;
void *oldheap;
u8 *cmd = 0;
@@ -4956,7 +4960,7 @@ exec (vat_main_t * vam)
}
- M (CLI_REQUEST, mp);
+ M (CLI, mp);
/*
* Copy cmd into shared memory.
@@ -11896,8 +11900,8 @@ format_l2_fib_mac_address (u8 * s, va_list * args)
a[2], a[3], a[4], a[5], a[6], a[7]);
}
-static void vl_api_l2_fib_table_entry_t_handler
- (vl_api_l2_fib_table_entry_t * mp)
+static void vl_api_l2_fib_table_details_t_handler
+ (vl_api_l2_fib_table_details_t * mp)
{
vat_main_t *vam = &vat_main;
@@ -11908,8 +11912,8 @@ static void vl_api_l2_fib_table_entry_t_handler
mp->bvi_mac);
}
-static void vl_api_l2_fib_table_entry_t_handler_json
- (vl_api_l2_fib_table_entry_t * mp)
+static void vl_api_l2_fib_table_details_t_handler_json
+ (vl_api_l2_fib_table_details_t * mp)
{
vat_main_t *vam = &vat_main;
vat_json_node_t *node = NULL;
diff --git a/src/vnet/l2/l2.api b/src/vnet/l2/l2.api
index e9a1f36187d..bb3990c6fa4 100644
--- a/src/vnet/l2/l2.api
+++ b/src/vnet/l2/l2.api
@@ -36,7 +36,7 @@ define l2_xconnect_dump
u32 context;
};
-/** \brief l2 fib table entry structure
+/** \brief l2 fib table details structure
@param bd_id - the l2 fib / bridge domain table id
@param mac - the entry's mac address
@param sw_if_index - index of the interface
@@ -44,7 +44,7 @@ define l2_xconnect_dump
@param filter_mac - the entry is a mac filter entry.
@param bvi_mac - the mac address is a bridge virtual interface
*/
-define l2_fib_table_entry
+define l2_fib_table_details
{
u32 context;
u32 bd_id;
@@ -212,6 +212,18 @@ define bridge_domain_dump
u32 bd_id;
};
+/** \brief L2 bridge domain sw interface operational state response
+ @param bd_id - the bridge domain id
+ @param sw_if_index - sw_if_index in the domain
+ @param shg - split horizon group for the interface
+*/
+typeonly manual_print manual_endian define bridge_domain_sw_if
+{
+ u32 context;
+ u32 sw_if_index;
+ u8 shg;
+};
+
/** \brief L2 bridge domain operational state response
@param bd_id - the bridge domain id
@param flood - bcast/mcast flooding state on all interfaces in the bd
@@ -222,7 +234,7 @@ define bridge_domain_dump
@param mac_age - mac aging time in min, 0 for disabled
@param n_sw_ifs - number of sw_if_index's in the domain
*/
-define bridge_domain_details
+manual_print manual_endian define bridge_domain_details
{
u32 context;
u32 bd_id;
@@ -234,19 +246,7 @@ define bridge_domain_details
u8 mac_age;
u32 bvi_sw_if_index;
u32 n_sw_ifs;
-};
-
-/** \brief L2 bridge domain sw interface operational state response
- @param bd_id - the bridge domain id
- @param sw_if_index - sw_if_index in the domain
- @param shg - split horizon group for the interface
-*/
-define bridge_domain_sw_if_details
-{
- u32 context;
- u32 bd_id;
- u32 sw_if_index;
- u8 shg;
+ vl_api_bridge_domain_sw_if_t sw_if_details[n_sw_ifs];
};
/** \brief Set bridge flags (such as L2_LEARN, L2_FWD, L2_FLOOD,
diff --git a/src/vnet/l2/l2_api.c b/src/vnet/l2/l2_api.c
index 7c4b04230f4..aa3dcb7e49e 100644
--- a/src/vnet/l2/l2_api.c
+++ b/src/vnet/l2/l2_api.c
@@ -36,6 +36,9 @@
#include <vnet/vnet_all_api_h.h>
#undef vl_endianfun
+#define vl_api_bridge_domain_details_t_endian vl_noop_handler
+#define vl_api_bridge_domain_details_t_print vl_noop_handler
+
/* instantiate all the print functions we know about */
#define vl_print(handle, ...) vlib_cli_output (handle, __VA_ARGS__)
#define vl_printfun
@@ -119,11 +122,11 @@ send_l2fib_table_entry (vpe_api_main_t * am,
l2fib_entry_key_t * l2fe_key,
l2fib_entry_result_t * l2fe_res, u32 context)
{
- vl_api_l2_fib_table_entry_t *mp;
+ vl_api_l2_fib_table_details_t *mp;
mp = vl_msg_api_alloc (sizeof (*mp));
memset (mp, 0, sizeof (*mp));
- mp->_vl_msg_id = ntohs (VL_API_L2_FIB_TABLE_ENTRY);
+ mp->_vl_msg_id = ntohs (VL_API_L2_FIB_TABLE_DETAILS);
mp->bd_id =
ntohl (l2input_main.bd_configs[l2fe_key->fields.bd_index].bd_id);
@@ -358,13 +361,18 @@ vl_api_bridge_domain_add_del_t_handler (vl_api_bridge_domain_add_del_t * mp)
}
static void
-send_bridge_domain_details (unix_shared_memory_queue_t * q,
+send_bridge_domain_details (l2input_main_t * l2im,
+ unix_shared_memory_queue_t * q,
l2_bridge_domain_t * bd_config,
u32 n_sw_ifs, u32 context)
{
vl_api_bridge_domain_details_t *mp;
+ l2_flood_member_t *m;
+ vl_api_bridge_domain_sw_if_t *sw_ifs;
+ l2_input_config_t *input_cfg;
- mp = vl_msg_api_alloc (sizeof (*mp));
+ mp = vl_msg_api_alloc (sizeof (*mp) +
+ (n_sw_ifs * sizeof (vl_api_bridge_domain_sw_if_t)));
memset (mp, 0, sizeof (*mp));
mp->_vl_msg_id = ntohs (VL_API_BRIDGE_DOMAIN_DETAILS);
mp->bd_id = ntohl (bd_config->bd_id);
@@ -375,28 +383,18 @@ send_bridge_domain_details (unix_shared_memory_queue_t * q,
mp->arp_term = bd_feature_arp_term (bd_config);
mp->bvi_sw_if_index = ntohl (bd_config->bvi_sw_if_index);
mp->mac_age = bd_config->mac_age;
- mp->n_sw_ifs = ntohl (n_sw_ifs);
mp->context = context;
- vl_msg_api_send_shmem (q, (u8 *) & mp);
-}
-
-static void
-send_bd_sw_if_details (l2input_main_t * l2im,
- unix_shared_memory_queue_t * q,
- l2_flood_member_t * member, u32 bd_id, u32 context)
-{
- vl_api_bridge_domain_sw_if_details_t *mp;
- l2_input_config_t *input_cfg;
-
- mp = vl_msg_api_alloc (sizeof (*mp));
- memset (mp, 0, sizeof (*mp));
- mp->_vl_msg_id = ntohs (VL_API_BRIDGE_DOMAIN_SW_IF_DETAILS);
- mp->bd_id = ntohl (bd_id);
- mp->sw_if_index = ntohl (member->sw_if_index);
- input_cfg = vec_elt_at_index (l2im->configs, member->sw_if_index);
- mp->shg = input_cfg->shg;
- mp->context = context;
+ sw_ifs = (vl_api_bridge_domain_sw_if_t *) mp->sw_if_details;
+ vec_foreach (m, bd_config->members)
+ {
+ sw_ifs->sw_if_index = ntohl (m->sw_if_index);
+ input_cfg = vec_elt_at_index (l2im->configs, m->sw_if_index);
+ sw_ifs->shg = input_cfg->shg;
+ sw_ifs++;
+ mp->n_sw_ifs++;
+ }
+ mp->n_sw_ifs = htonl (mp->n_sw_ifs);
vl_msg_api_send_shmem (q, (u8 *) & mp);
}
@@ -434,18 +432,9 @@ vl_api_bridge_domain_dump_t_handler (vl_api_bridge_domain_dump_t * mp)
l2input_bd_config_from_index (l2im, bd_index);
/* skip dummy bd_id 0 */
if (bd_config && (bd_config->bd_id > 0))
- {
- u32 n_sw_ifs;
- l2_flood_member_t *m;
-
- n_sw_ifs = vec_len (bd_config->members);
- send_bridge_domain_details (q, bd_config, n_sw_ifs, mp->context);
-
- vec_foreach (m, bd_config->members)
- {
- send_bd_sw_if_details (l2im, q, m, bd_config->bd_id, mp->context);
- }
- }
+ send_bridge_domain_details (l2im, q, bd_config,
+ vec_len (bd_config->members),
+ mp->context);
}
}
diff --git a/src/vpp-api/java/jvpp-core/io/fd/vpp/jvpp/core/test/FutureApiTest.java b/src/vpp-api/java/jvpp-core/io/fd/vpp/jvpp/core/test/FutureApiTest.java
index 0d7c7471df7..63659f82c63 100644
--- a/src/vpp-api/java/jvpp-core/io/fd/vpp/jvpp/core/test/FutureApiTest.java
+++ b/src/vpp-api/java/jvpp-core/io/fd/vpp/jvpp/core/test/FutureApiTest.java
@@ -67,8 +67,8 @@ public class FutureApiTest {
} else {
LOG.info(
String.format(
- "Received empty bridge-domain dump reply with list of bridge-domains: %s, %s",
- reply.bridgeDomainDetails, reply.bridgeDomainSwIfDetails));
+ "Received bridge-domain dump reply with list of bridge-domains: %s",
+ reply.bridgeDomainDetails));
}
}
diff --git a/src/vpp-api/java/jvpp/gen/jvppgen/util.py b/src/vpp-api/java/jvpp/gen/jvppgen/util.py
index fc971c176d5..947fc31d48a 100644
--- a/src/vpp-api/java/jvpp/gen/jvppgen/util.py
+++ b/src/vpp-api/java/jvpp/gen/jvppgen/util.py
@@ -156,13 +156,6 @@ jni_field_accessors = {'u8': 'ByteField',
# vpe.api calls that do not follow naming conventions and have to be handled exceptionally when finding reply -> request mapping
# FIXME in vpe.api
unconventional_naming_rep_req = {
- 'cli_reply': 'cli_request',
- 'vnet_summary_stats_reply': 'vnet_get_summary_stats',
- # This below is actually a sub-details callback. We cannot derive the mapping of dump request
- # belonging to this sub-details from naming conventions. We need special mapping
- 'bridge_domain_sw_if_details': 'bridge_domain',
- # This is standard dump call + details reply. However it's not called details but entry
- 'l2_fib_table_entry': 'l2_fib_table'
}
#
@@ -172,7 +165,7 @@ notification_messages_reused = ["sw_interface_set_flags"]
# messages that must be ignored. These messages are INSUFFICIENTLY marked as disabled in vpe.api
# FIXME
-ignored_messages = ["is_address_reachable"]
+ignored_messages = []
def is_notification(name):
diff --git a/src/vpp/api/api.c b/src/vpp/api/api.c
index 7e4c341e12b..60eb5331f59 100644
--- a/src/vpp/api/api.c
+++ b/src/vpp/api/api.c
@@ -104,7 +104,6 @@
#define foreach_vpe_api_msg \
_(WANT_OAM_EVENTS, want_oam_events) \
_(OAM_ADD_DEL, oam_add_del) \
-_(IS_ADDRESS_REACHABLE, is_address_reachable) \
_(SW_INTERFACE_SET_MPLS_ENABLE, sw_interface_set_mpls_enable) \
_(SW_INTERFACE_SET_VPATH, sw_interface_set_vpath) \
_(SW_INTERFACE_SET_L2_XCONNECT, sw_interface_set_l2_xconnect) \
@@ -118,7 +117,7 @@ _(RESET_FIB, reset_fib) \
_(CREATE_LOOPBACK, create_loopback) \
_(CREATE_LOOPBACK_INSTANCE, create_loopback_instance) \
_(CONTROL_PING, control_ping) \
-_(CLI_REQUEST, cli_request) \
+_(CLI, cli) \
_(CLI_INBAND, cli_inband) \
_(SET_ARP_NEIGHBOR_LIMIT, set_arp_neighbor_limit) \
_(L2_PATCH_ADD_DEL, l2_patch_add_del) \
@@ -694,82 +693,6 @@ out:
}
static void
-vl_api_is_address_reachable_t_handler (vl_api_is_address_reachable_t * mp)
-{
-#if 0
- vpe_main_t *rm = &vpe_main;
- ip4_main_t *im4 = &ip4_main;
- ip6_main_t *im6 = &ip6_main;
- ip_lookup_main_t *lm;
- union
- {
- ip4_address_t ip4;
- ip6_address_t ip6;
- } addr;
- u32 adj_index, sw_if_index;
- vl_api_is_address_reachable_t *rmp;
- ip_adjacency_t *adj;
- unix_shared_memory_queue_t *q;
-
- q = vl_api_client_index_to_input_queue (mp->client_index);
- if (!q)
- {
- increment_missing_api_client_counter (rm->vlib_main);
- return;
- }
-
- rmp = vl_msg_api_alloc (sizeof (*rmp));
- clib_memcpy (rmp, mp, sizeof (*rmp));
-
- sw_if_index = mp->next_hop_sw_if_index;
- clib_memcpy (&addr, mp->address, sizeof (addr));
- if (mp->is_ipv6)
- {
- lm = &im6->lookup_main;
- adj_index = ip6_fib_lookup (im6, sw_if_index, &addr.ip6);
- }
- else
- {
- lm = &im4->lookup_main;
- // FIXME NOT an ADJ
- adj_index = ip4_fib_lookup (im4, sw_if_index, &addr.ip4);
- }
- if (adj_index == ~0)
- {
- rmp->is_error = 1;
- goto send;
- }
- adj = ip_get_adjacency (lm, adj_index);
-
- if (adj->lookup_next_index == IP_LOOKUP_NEXT_REWRITE
- && adj->rewrite_header.sw_if_index == sw_if_index)
- {
- rmp->is_known = 1;
- }
- else
- {
- if (adj->lookup_next_index == IP_LOOKUP_NEXT_ARP
- && adj->rewrite_header.sw_if_index == sw_if_index)
- {
- if (mp->is_ipv6)
- ip6_probe_neighbor (rm->vlib_main, &addr.ip6, sw_if_index);
- else
- ip4_probe_neighbor (rm->vlib_main, &addr.ip4, sw_if_index);
- }
- else if (adj->lookup_next_index == IP_LOOKUP_NEXT_DROP)
- {
- rmp->is_known = 1;
- goto send;
- }
- rmp->is_known = 0;
- }
-
-send:
- vl_msg_api_send_shmem (q, (u8 *) & rmp);
-#endif
-}
-
-static void
vl_api_sw_interface_set_mpls_enable_t_handler
(vl_api_sw_interface_set_mpls_enable_t * mp)
{
@@ -828,7 +751,7 @@ vl_api_vnet_get_summary_stats_t_handler (vl_api_vnet_get_summary_stats_t * mp)
{
stats_main_t *sm = &stats_main;
vnet_interface_main_t *im = sm->interface_main;
- vl_api_vnet_summary_stats_reply_t *rmp;
+ vl_api_vnet_get_summary_stats_reply_t *rmp;
vlib_combined_counter_main_t *cm;
vlib_counter_t v;
int i, which;
@@ -842,7 +765,7 @@ vl_api_vnet_get_summary_stats_t_handler (vl_api_vnet_get_summary_stats_t * mp)
return;
rmp = vl_msg_api_alloc (sizeof (*rmp));
- rmp->_vl_msg_id = ntohs (VL_API_VNET_SUMMARY_STATS_REPLY);
+ rmp->_vl_msg_id = ntohs (VL_API_VNET_GET_SUMMARY_STATS_REPLY);
rmp->context = mp->context;
rmp->retval = 0;
@@ -1115,7 +1038,7 @@ shmem_cli_output (uword arg, u8 * buffer, uword buffer_bytes)
static void
-vl_api_cli_request_t_handler (vl_api_cli_request_t * mp)
+vl_api_cli_t_handler (vl_api_cli_t * mp)
{
vl_api_cli_reply_t *rp;
unix_shared_memory_queue_t *q;
diff --git a/src/vpp/api/custom_dump.c b/src/vpp/api/custom_dump.c
index c073c52d69b..9071883b210 100644
--- a/src/vpp/api/custom_dump.c
+++ b/src/vpp/api/custom_dump.c
@@ -1656,12 +1656,12 @@ static void *vl_api_want_interface_events_t_print
FINISH;
}
-static void *vl_api_cli_request_t_print
- (vl_api_cli_request_t * mp, void *handle)
+static void *
+vl_api_cli_t_print (vl_api_cli_t * mp, void *handle)
{
u8 *s;
- s = format (0, "SCRIPT: cli_request ");
+ s = format (0, "SCRIPT: cli ");
FINISH;
}
@@ -3023,7 +3023,7 @@ _(DELETE_VHOST_USER_IF, delete_vhost_user_if) \
_(SW_INTERFACE_DUMP, sw_interface_dump) \
_(CONTROL_PING, control_ping) \
_(WANT_INTERFACE_EVENTS, want_interface_events) \
-_(CLI_REQUEST, cli_request) \
+_(CLI, cli) \
_(CLI_INBAND, cli_inband) \
_(MEMCLNT_CREATE, memclnt_create) \
_(SW_INTERFACE_VHOST_USER_DUMP, sw_interface_vhost_user_dump) \
diff --git a/src/vpp/api/summary_stats_client.c b/src/vpp/api/summary_stats_client.c
index 03999567d96..2c81d6678c3 100644
--- a/src/vpp/api/summary_stats_client.c
+++ b/src/vpp/api/summary_stats_client.c
@@ -101,8 +101,8 @@ vlib_cli_output (struct vlib_main_t *vm, char *fmt, ...)
static void
-vl_api_vnet_summary_stats_reply_t_handler (vl_api_vnet_summary_stats_reply_t *
- mp)
+ vl_api_vnet_get_summary_stats_reply_t_handler
+ (vl_api_vnet_get_summary_stats_reply_t * mp)
{
test_main_t *tm = &test_main;
static u8 *sb;
@@ -134,7 +134,7 @@ vl_api_vnet_summary_stats_reply_t_handler (vl_api_vnet_summary_stats_reply_t *
}
#define foreach_api_msg \
-_(VNET_SUMMARY_STATS_REPLY, vnet_summary_stats_reply)
+_(VNET_GET_SUMMARY_STATS_REPLY, vnet_get_summary_stats_reply)
int
connect_to_vpe (char *name)
diff --git a/src/vpp/api/vpe.api b/src/vpp/api/vpe.api
index 99ae47843c4..d3c7e985e42 100644
--- a/src/vpp/api/vpe.api
+++ b/src/vpp/api/vpe.api
@@ -135,25 +135,6 @@ autoreply define reset_vrf
u32 vrf_id;
};
-/** \brief Is Address Reachable request - DISABLED
- @param client_index - opaque cookie to identify the sender
- @param context - sender context, to match reply w/ request
- @param next_hop_sw_if_index - index of interface used to get to next hop
- @param is_ipv6 - 1 for IPv6, 0 for IPv4
- @param is_error - address not found or does not match intf
- @param address[] - Address in question
-*/
-define is_address_reachable
-{
- u32 client_index; /* (api_main_t *) am->my_client_index */
- u32 context;
- u32 next_hop_sw_if_index;
- u8 is_known; /* on reply, this is the answer */
- u8 is_ipv6;
- u8 is_error; /* address not found or does not match intf */
- u8 address[16];
-};
-
/** \brief Want Stats, register for stats updates
@param client_index - opaque cookie to identify the sender
@param context - sender context, to match reply w/ request
@@ -256,7 +237,7 @@ define vnet_get_summary_stats
@param total_bytes -
@param vector_rate -
*/
-define vnet_summary_stats_reply
+define vnet_get_summary_stats_reply
{
u32 context;
i32 retval;
@@ -414,7 +395,7 @@ define control_ping_reply
@param context - sender context, to match reply w/ request
@param cmd_in_shmem - pointer to cli command string
*/
-define cli_request
+define cli
{
u32 client_index;
u32 context;