diff options
author | Eyal Bari <ebari@cisco.com> | 2017-07-16 09:34:53 +0300 |
---|---|---|
committer | Eyal Bari <ebari@cisco.com> | 2017-07-24 08:21:52 +0300 |
commit | 001fd406df771f1cf73ca0dea440c8bde309e077 (patch) | |
tree | bfa98f32f5cba2d5fe06e2bc39a03b4d6ce98112 /src/vat | |
parent | beb0b2e346c63e21ffe892ae0e04b67bb10fba5e (diff) |
SPAN:add l2 mirror
added span feature nodes for l2-input / l2-output
Change-Id: Ib6e0ce60d0811901b6edd70209e6a4c4a35cd8ff
Signed-off-by: Eyal Bari <ebari@cisco.com>
Diffstat (limited to 'src/vat')
-rw-r--r-- | src/vat/api_format.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/vat/api_format.c b/src/vat/api_format.c index 40eca8c5..932e162d 100644 --- a/src/vat/api_format.c +++ b/src/vat/api_format.c @@ -18082,6 +18082,7 @@ api_sw_interface_span_enable_disable (vat_main_t * vam) u32 dst_sw_if_index = ~0; u8 state = 3; int ret; + u8 is_l2 = 0; while (unformat_check_input (i) != UNFORMAT_END_OF_INPUT) { @@ -18104,6 +18105,8 @@ api_sw_interface_span_enable_disable (vat_main_t * vam) state = 2; else if (unformat (i, "both")) state = 3; + else if (unformat (i, "l2")) + is_l2 = 1; else break; } @@ -18113,6 +18116,7 @@ api_sw_interface_span_enable_disable (vat_main_t * vam) mp->sw_if_index_from = htonl (src_sw_if_index); mp->sw_if_index_to = htonl (dst_sw_if_index); mp->state = state; + mp->is_l2 = is_l2; S (mp); W (ret); @@ -20044,7 +20048,7 @@ _(set_ipfix_classify_stream, "[domain <domain-id>] [src_port <src-port>]") \ _(ipfix_classify_stream_dump, "") \ _(ipfix_classify_table_add_del, "table <table-index> ip4|ip6 [tcp|udp]") \ _(ipfix_classify_table_dump, "") \ -_(sw_interface_span_enable_disable, "[src <intfc> | src_sw_if_index <id>] [disable | [[dst <intfc> | dst_sw_if_index <id>] [both|rx|tx]]]") \ +_(sw_interface_span_enable_disable, "[l2] [src <intfc> | src_sw_if_index <id>] [disable | [[dst <intfc> | dst_sw_if_index <id>] [both|rx|tx]]]") \ _(sw_interface_span_dump, "") \ _(get_next_index, "node-name <node-name> next-node-name <node-name>") \ _(pg_create_interface, "if_id <nn>") \ |