aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/srv6/sr_steering.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/vnet/srv6/sr_steering.c')
-rw-r--r--src/vnet/srv6/sr_steering.c13
1 files changed, 0 insertions, 13 deletions
diff --git a/src/vnet/srv6/sr_steering.c b/src/vnet/srv6/sr_steering.c
index cb1d81742eb..94c3d67a27a 100644
--- a/src/vnet/srv6/sr_steering.c
+++ b/src/vnet/srv6/sr_steering.c
@@ -184,9 +184,6 @@ sr_steering_policy (int is_del, ip6_address_t * bsid, u32 sr_policy_index,
else
sr_policy = pool_elt_at_index (sm->sr_policies, sr_policy_index);
- if (!sr_policy)
- return -2;
-
steer_pl->sr_policy = sr_policy - sm->sr_policies;
/* Remove old FIB/hw redirection and create a new one */
@@ -459,7 +456,6 @@ sr_steer_policy_command_fn (vlib_main_t * vm, unformat_input_t * input,
return 0;
}
-/* *INDENT-OFF* */
VLIB_CLI_COMMAND (sr_steer_policy_command, static) = {
.path = "sr steer",
.short_help = "sr steer (del) [l3 <ip_addr/mask>|l2 <sf_if>] "
@@ -474,7 +470,6 @@ VLIB_CLI_COMMAND (sr_steer_policy_command, static) = {
"\t\tsr steer del l3 2001::/64 via sr_policy index 5\n",
.function = sr_steer_policy_command_fn,
};
-/* *INDENT-ON* */
static clib_error_t *
show_sr_steering_policies_command_fn (vlib_main_t * vm,
@@ -491,9 +486,7 @@ show_sr_steering_policies_command_fn (vlib_main_t * vm,
int i;
vlib_cli_output (vm, "SR steering policies:");
- /* *INDENT-OFF* */
pool_foreach (steer_pl, sm->steer_policies) {vec_add1(steer_policies, steer_pl);}
- /* *INDENT-ON* */
vlib_cli_output (vm, "Traffic\t\tSR policy BSID");
for (i = 0; i < vec_len (steer_policies); i++)
{
@@ -526,13 +519,11 @@ show_sr_steering_policies_command_fn (vlib_main_t * vm,
return 0;
}
-/* *INDENT-OFF* */
VLIB_CLI_COMMAND (show_sr_steering_policies_command, static) = {
.path = "show sr steering-policies",
.short_help = "show sr steering-policies",
.function = show_sr_steering_policies_command_fn,
};
-/* *INDENT-ON* */
clib_error_t *
sr_steering_init (vlib_main_t * vm)
@@ -550,18 +541,14 @@ sr_steering_init (vlib_main_t * vm)
return 0;
}
-/* *INDENT-OFF* */
VLIB_INIT_FUNCTION (sr_steering_init);
-/* *INDENT-ON* */
-/* *INDENT-OFF* */
VNET_FEATURE_INIT (sr_pl_rewrite_encaps_l2, static) =
{
.arc_name = "device-input",
.node_name = "sr-pl-rewrite-encaps-l2",
.runs_before = VNET_FEATURES ("ethernet-input"),
};
-/* *INDENT-ON* */
/*
* fd.io coding-style-patch-verification: ON