summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilippe Guibert <philippe.guibert@6wind.com>2025-02-05 09:52:59 +0100
committerMergify <37929162+mergify[bot]@users.noreply.github.com>2025-02-13 17:58:35 +0000
commit12f7120c078fdb7065e44277050659146060968f (patch)
treeb3a389f443648b42cb8f9a747dccf024ab3aef78
parent3b97f50e31614a14a7c446e420f269b878f5fdf9 (diff)
lib: fix false context information for SRv6 route
The seg6local route dumped by 'show ipv6 route' makes think that the USP flavor is supported, whereas it is not the case. This information is a context information, and for End, the context information should be empty. > # show ipv6 route > [..] > I>* fc00:0:4::/128 [115/0] is directly connected, sr0, seg6local End USP, weight 1, 00:49:01 Fix this by suppressing the USP information from the output. Fixes: e496b4203055 ("bgpd: prefix-sid srv6 l3vpn service tlv") Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com> (cherry picked from commit 658bf0281d99461849453628ddc792ec424d0bd4)
-rw-r--r--lib/srv6.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/srv6.c b/lib/srv6.c
index e6fc375fbb..76655a820b 100644
--- a/lib/srv6.c
+++ b/lib/srv6.c
@@ -76,7 +76,6 @@ void seg6local_context2json(const struct seg6local_context *ctx,
{
switch (action) {
case ZEBRA_SEG6_LOCAL_ACTION_END:
- json_object_boolean_add(json, "USP", true);
return;
case ZEBRA_SEG6_LOCAL_ACTION_END_X:
case ZEBRA_SEG6_LOCAL_ACTION_END_DX6:
@@ -116,7 +115,7 @@ const char *seg6local_context2str(char *str, size_t size,
switch (action) {
case ZEBRA_SEG6_LOCAL_ACTION_END:
- snprintf(str, size, "USP");
+ snprintf(str, size, "-");
return str;
case ZEBRA_SEG6_LOCAL_ACTION_END_X: