diff options
author | Ahmed Abdelsalam <ahabdels@cisco.com> | 2019-12-08 12:58:27 +0100 |
---|---|---|
committer | Andrew Yourtchenko <ayourtch@gmail.com> | 2020-08-12 15:59:46 +0000 |
commit | 4362672562f5b379361f147cbb7a9b72c3332c30 (patch) | |
tree | 57229904a4c9998c543ea29db3e892684bafb0fa /src/vnet/srv6/sr_localsid.c | |
parent | 4d5da6c5eded39ea3f1d7bb721e8bc598e689e0d (diff) |
sr: some fixes for SRv6 CLI/API
Return FIB table_id instead of vrf_index to clients
Type: fix
Signed-off-by: Ahmed Abdelsalam <ahabdels@cisco.com>
Change-Id: I76a97bad3ecd3ac8eb045efb1657eaa90c2a57b6
(cherry picked from commit 13e6fce7c5b3a16a6af0b27fc259ef3f65d8c861)
Diffstat (limited to 'src/vnet/srv6/sr_localsid.c')
-rwxr-xr-x | src/vnet/srv6/sr_localsid.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/src/vnet/srv6/sr_localsid.c b/src/vnet/srv6/sr_localsid.c index c592f797d1c..ffd08ca1528 100755 --- a/src/vnet/srv6/sr_localsid.c +++ b/src/vnet/srv6/sr_localsid.c @@ -474,7 +474,9 @@ show_sr_localsid_command_fn (vlib_main_t * vm, unformat_input_t * input, vlib_cli_output (vm, "\tAddress: \t%U\n\tBehavior: \tT (Endpoint with specific IPv6 table lookup)" "\n\tTable: \t%u", - format_ip6_address, &ls->localsid, ls->vrf_index); + format_ip6_address, &ls->localsid, + fib_table_get_table_id (ls->vrf_index, + FIB_PROTOCOL_IP6)); break; case SR_BEHAVIOR_DX4: vlib_cli_output (vm, @@ -507,13 +509,16 @@ show_sr_localsid_command_fn (vlib_main_t * vm, unformat_input_t * input, vlib_cli_output (vm, "\tAddress: \t%U\n\tBehavior: \tDT6 (Endpoint with decapsulation and specific IPv6 table lookup)" "\n\tTable: %u", format_ip6_address, &ls->localsid, - ls->vrf_index); + fib_table_get_table_id (ls->vrf_index, + FIB_PROTOCOL_IP6)); break; case SR_BEHAVIOR_DT4: vlib_cli_output (vm, "\tAddress: \t%U\n\tBehavior: \tDT4 (Endpoint with decapsulation and specific IPv4 table lookup)" "\n\tTable: \t%u", format_ip6_address, - &ls->localsid, ls->vrf_index); + &ls->localsid, + fib_table_get_table_id (ls->vrf_index, + FIB_PROTOCOL_IP4)); break; default: if (ls->behavior >= SR_BEHAVIOR_LAST) |