From 5fa6bfffb1201c98960ea8a3808d6e1e7ed8c312 Mon Sep 17 00:00:00 2001 From: Stephen Worley Date: Thu, 1 Apr 2021 11:50:31 -0400 Subject: zebra: encode vni label via lwt encap Encode the vni label during route install on linux systems via lwt encap 64bit LWTUNNEL_IP_ID. The kernel expects this in network byte order, so we convert it. Signed-off-by: Stephen Worley --- zebra/kernel_netlink.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'zebra/kernel_netlink.c') diff --git a/zebra/kernel_netlink.c b/zebra/kernel_netlink.c index 42afe61469..0c45350700 100644 --- a/zebra/kernel_netlink.c +++ b/zebra/kernel_netlink.c @@ -705,6 +705,12 @@ bool nl_attr_put32(struct nlmsghdr *n, unsigned int maxlen, int type, return nl_attr_put(n, maxlen, type, &data, sizeof(uint32_t)); } +bool nl_attr_put64(struct nlmsghdr *n, unsigned int maxlen, int type, + uint64_t data) +{ + return nl_attr_put(n, maxlen, type, &data, sizeof(uint64_t)); +} + struct rtattr *nl_attr_nest(struct nlmsghdr *n, unsigned int maxlen, int type) { struct rtattr *nest = NLMSG_TAIL(n); -- cgit v1.2.3