From 9487b1f6602b8a503d2dd7cabf70a25a0bc1a56f Mon Sep 17 00:00:00 2001 From: Abhishek Dosi Date: Wed, 27 Nov 2024 02:52:43 +0000 Subject: [PATCH] Updated the patch to have fpm flag check Signed-off-by: Abhishek Dosi --- ...g-value-associated-with-route-via-ne.patch | 44 ++++++++++++------- 1 file changed, 28 insertions(+), 16 deletions(-) diff --git a/src/sonic-frr/patch/0053-Patch-to-send-tag-value-associated-with-route-via-ne.patch b/src/sonic-frr/patch/0053-Patch-to-send-tag-value-associated-with-route-via-ne.patch index 9a5405d934d0..09b7782103a0 100644 --- a/src/sonic-frr/patch/0053-Patch-to-send-tag-value-associated-with-route-via-ne.patch +++ b/src/sonic-frr/patch/0053-Patch-to-send-tag-value-associated-with-route-via-ne.patch @@ -1,37 +1,49 @@ -From 1a8b3715a88aeaa4bda1ac445aa4992a14f33f31 Mon Sep 17 00:00:00 2001 +From dd71a11ab9543622553a3835dac6513faa27b990 Mon Sep 17 00:00:00 2001 From: Abhishek Dosi -Date: Fri, 8 Nov 2024 02:19:37 +0000 -Subject: [PATCH] Patch to send tag value associated with route via netlink in +Date: Wed, 27 Nov 2024 02:45:50 +0000 +Subject: [PATCH] Patch to send tag value associated with route via netlink in RTA_PRIORITY field. Signed-off-by: Abhishek Dosi --- - zebra/rt_netlink.c | 10 +++++++++- - 1 file changed, 9 insertions(+), 1 deletion(-) + zebra/rt_netlink.c | 23 ++++++++++++++++++++--- + 1 file changed, 20 insertions(+), 3 deletions(-) diff --git a/zebra/rt_netlink.c b/zebra/rt_netlink.c -index 3f51894be..65f598aad 100644 +index 3f51894be..33818c99b 100644 --- a/zebra/rt_netlink.c +++ b/zebra/rt_netlink.c -@@ -2113,9 +2113,17 @@ ssize_t netlink_route_multipath_msg_encode(int cmd, +@@ -2113,10 +2113,27 @@ ssize_t netlink_route_multipath_msg_encode(int cmd, * path(s) * by the routing protocol and for communicating with protocol peers. */ -+ -+ /* Patch to send tag value as route attribute using RTA_PRIORITY -+ * which can be used as metadata/attribute to take application specific -+ * action. As seen in above comment this field is not use anyways and can be -+ * use by fpmsyncd */ - if (!nl_attr_put32(&req->n, datalen, RTA_PRIORITY, +- if (!nl_attr_put32(&req->n, datalen, RTA_PRIORITY, - ROUTE_INSTALLATION_METRIC)) -+ cmd == RTM_DELROUTE ? dplane_ctx_get_old_tag(ctx) : -+ dplane_ctx_get_tag(ctx))) ++ if (fpm) + { ++ /* Patch to send tag value as route attribute using RTA_PRIORITY ++ * which can be used as metadata/attribute to take application specific ++ * action. As seen in above comment this field is not use anyways and can be ++ * use by fpmsyncd */ ++ if (!nl_attr_put32(&req->n, datalen, RTA_PRIORITY, ++ cmd == RTM_DELROUTE ? dplane_ctx_get_old_tag(ctx) : ++ dplane_ctx_get_tag(ctx))) ++ { return 0; +- ++ } ++ } ++ else ++ { ++ if (!nl_attr_put32(&req->n, datalen, RTA_PRIORITY, ++ ROUTE_INSTALLATION_METRIC)) ++ { ++ return 0; ++ } + } - #if defined(SUPPORT_REALMS) if (cmd == RTM_DELROUTE) + tag = dplane_ctx_get_old_tag(ctx); -- 2.25.1