s = format (0, "SCRIPT: l2fib_add_del ");
- s = format (s, "mac %U ", format_ethernet_address, &mp->mac);
+ s = format (s, "mac %U ", format_ethernet_address, mp->mac);
s = format (s, "bd_id %d ", ntohl (mp->bd_id));
FINISH;
}
+static void *vl_api_tap_create_v2_t_print
+ (vl_api_tap_create_v2_t * mp, void *handle)
+{
+ u8 *s;
+ u8 null_mac[6];
+
+ memset (null_mac, 0, sizeof (null_mac));
+
+ s = format (0, "SCRIPT: tap_create_v2 ");
+ s = format (s, "name %s ", mp->tap_name);
+ if (memcmp (mp->mac_address, null_mac, 6))
+ s = format (s, "hw-addr %U ", format_ethernet_address, mp->mac_address);
+ if (mp->host_namespace_set)
+ s = format (s, "host-ns %s ", mp->host_namespace);
+ if (mp->host_bridge_set)
+ s = format (s, "host-bridge %s ", mp->host_bridge);
+ if (mp->host_ip4_addr_set)
+ s = format (s, "host-ip4-addr %U/%d ", format_ip4_address,
+ mp->host_ip4_addr, mp->host_ip4_prefix_len);
+ if (mp->host_ip6_addr_set)
+ s = format (s, "host-ip6-addr %U/%d ", format_ip6_address,
+ mp->host_ip6_addr, mp->host_ip6_prefix_len);
+ if (mp->tx_ring_sz)
+ s = format (s, "tx-ring-size %d ", mp->tx_ring_sz);
+ if (mp->rx_ring_sz)
+ s = format (s, "rx-ring-size %d ", mp->rx_ring_sz);
+ FINISH;
+}
+
+static void *vl_api_tap_delete_v2_t_print
+ (vl_api_tap_delete_v2_t * mp, void *handle)
+{
+ u8 *s;
+
+ s = format (0, "SCRIPT: tap_delete_v2 ");
+ s = format (s, "sw_if_index %d ", ntohl (mp->sw_if_index));
+
+ FINISH;
+}
+
+static void *vl_api_sw_interface_tap_v2_dump_t_print
+ (vl_api_sw_interface_tap_v2_dump_t * mp, void *handle)
+{
+ u8 *s;
+
+ s = format (0, "SCRIPT: sw_interface_tap_v2_dump ");
+
+ FINISH;
+}
static void *vl_api_ip_add_del_route_t_print
(vl_api_ip_add_del_route_t * mp, void *handle)
FINISH;
}
-static void *
-vl_api_reset_vrf_t_print (vl_api_reset_vrf_t * mp, void *handle)
-{
- u8 *s;
-
- s = format (0, "SCRIPT: reset_vrf ");
-
- if (mp->vrf_id)
- s = format (s, "vrf %d ", ntohl (mp->vrf_id));
-
- if (mp->is_ipv6 != 0)
- s = format (s, "ipv6 ");
-
- FINISH;
-}
-
static void *vl_api_create_vlan_subif_t_print
(vl_api_create_vlan_subif_t * mp, void *handle)
{
s = format (s, "tbl_id %d ", ntohl (mp->tbl_id));
- s = format (s, "fib_id %d ", ntohl (mp->fib_id));
-
- s = format (s, "oui %d ", ntohl (mp->oui));
+ if (mp->vss_type == VSS_TYPE_VPN_ID)
+ {
+ s = format (s, "fib_id %d ", ntohl (mp->vpn_index));
+ s = format (s, "oui %d ", ntohl (mp->oui));
+ }
+ else if (mp->vss_type == VSS_TYPE_ASCII)
+ s = format (s, "vpn_ascii_id %s", mp->vpn_ascii_id);
if (mp->is_ipv6 != 0)
s = format (s, "ipv6 ");
u8 *s;
char *proto = mp->transport_proto == 0 ? "tcp" : "udp";
s = format (0, "SCRIPT: session_rule_add_del ");
+ mp->tag[sizeof (mp->tag) - 1] = 0;
if (mp->is_ip4)
- s = format (s, "appns %d scope %d %s %U/%d %d %U/%d %d action %u",
+ s = format (s, "appns %d scope %d %s %U/%d %d %U/%d %d action %u tag %s",
mp->appns_index, mp->scope, proto, format_ip4_address,
(ip4_address_t *) mp->lcl_ip, mp->lcl_plen,
format_ip4_address, (ip4_address_t *) mp->rmt_ip,
- mp->rmt_plen, mp->action_index);
+ mp->rmt_plen, mp->action_index, mp->tag);
else
- s = format (s, "appns %d scope %d %s %U/%d %d %U/%d %d action %u",
+ s = format (s, "appns %d scope %d %s %U/%d %d %U/%d %d action %u tag %s",
mp->appns_index, mp->scope, proto, format_ip6_address,
(ip6_address_t *) mp->lcl_ip, mp->lcl_plen,
format_ip6_address, (ip6_address_t *) mp->rmt_ip,
- mp->rmt_plen, mp->action_index);
+ mp->rmt_plen, mp->action_index, mp->tag);
+ FINISH;
+}
+
+static void *vl_api_ip_container_proxy_add_del_t_print
+ (vl_api_ip_container_proxy_add_del_t * mp, void *handle)
+{
+ u8 *s;
+ s = format (0, "SCRIPT: ip_container_proxy_add_del ");
+ if (mp->is_ip4)
+ s = format (s, "is_add %d address %U/%d sw_if_index %d",
+ mp->is_add, format_ip4_address,
+ (ip4_address_t *) mp->ip, mp->plen, mp->sw_if_index);
+ else
+ s = format (s, "is_add %d address %U/%d sw_if_index %d",
+ mp->is_add, format_ip6_address,
+ (ip6_address_t *) mp->ip, mp->plen, mp->sw_if_index);
FINISH;
}
+
#define foreach_custom_print_no_arg_function \
_(lisp_eid_table_vni_dump) \
_(lisp_map_resolver_dump) \
_(TAP_MODIFY, tap_modify) \
_(TAP_DELETE, tap_delete) \
_(SW_INTERFACE_TAP_DUMP, sw_interface_tap_dump) \
+_(TAP_CREATE_V2, tap_create_v2) \
+_(TAP_DELETE_V2, tap_delete_v2) \
+_(SW_INTERFACE_TAP_V2_DUMP, sw_interface_tap_v2_dump) \
_(IP_ADD_DEL_ROUTE, ip_add_del_route) \
_(PROXY_ARP_ADD_DEL, proxy_arp_add_del) \
_(PROXY_ARP_INTFC_ENABLE_DISABLE, proxy_arp_intfc_enable_disable) \
_(MPLS_TUNNEL_ADD_DEL, mpls_tunnel_add_del) \
_(SW_INTERFACE_SET_UNNUMBERED, sw_interface_set_unnumbered) \
_(IP_NEIGHBOR_ADD_DEL, ip_neighbor_add_del) \
-_(RESET_VRF, reset_vrf) \
_(CREATE_VLAN_SUBIF, create_vlan_subif) \
_(CREATE_SUBIF, create_subif) \
_(OAM_ADD_DEL, oam_add_del) \