summaryrefslogtreecommitdiffstats
path: root/zebra/rt_netlink.c
diff options
context:
space:
mode:
authorCarmine Scarpitta <carmine.scarpitta@uniroma2.it>2022-07-23 01:32:04 +0200
committerCarmine Scarpitta <carmine.scarpitta@uniroma2.it>2022-10-18 15:37:25 +0200
commit8bea07e49f883782907e3d74b4598903abf8e58c (patch)
treef6ad5c40d3012f2986694be67a1ab82dde02137e /zebra/rt_netlink.c
parentinclude: update seg6_local.h to latest kernel (diff)
downloadfrr-8bea07e49f883782907e3d74b4598903abf8e58c.tar.xz
frr-8bea07e49f883782907e3d74b4598903abf8e58c.zip
zebra, lib: add support for SRv6 End.DT46 behavior
This commit enables zebra to install End.DT46 nexthops into the Linux kernel. Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
Diffstat (limited to '')
-rw-r--r--zebra/rt_netlink.c22
1 files changed, 22 insertions, 0 deletions
diff --git a/zebra/rt_netlink.c b/zebra/rt_netlink.c
index e883033d5..3a8f5264f 100644
--- a/zebra/rt_netlink.c
+++ b/zebra/rt_netlink.c
@@ -1540,6 +1540,16 @@ static bool _netlink_route_build_singlepath(const struct prefix *p,
ctx->table))
return false;
break;
+ case ZEBRA_SEG6_LOCAL_ACTION_END_DT46:
+ if (!nl_attr_put32(nlmsg, req_size,
+ SEG6_LOCAL_ACTION,
+ SEG6_LOCAL_ACTION_END_DT46))
+ return false;
+ if (!nl_attr_put32(nlmsg, req_size,
+ SEG6_LOCAL_VRFTABLE,
+ ctx->table))
+ return false;
+ break;
default:
zlog_err("%s: unsupport seg6local behaviour action=%u",
__func__,
@@ -2706,6 +2716,18 @@ ssize_t netlink_nexthop_msg_encode(uint16_t cmd,
ctx->table))
return 0;
break;
+ case SEG6_LOCAL_ACTION_END_DT46:
+ if (!nl_attr_put32(
+ &req->n, buflen,
+ SEG6_LOCAL_ACTION,
+ SEG6_LOCAL_ACTION_END_DT46))
+ return 0;
+ if (!nl_attr_put32(
+ &req->n, buflen,
+ SEG6_LOCAL_VRFTABLE,
+ ctx->table))
+ return 0;
+ break;
default:
zlog_err("%s: unsupport seg6local behaviour action=%u",
__func__, action);