forked from sonic-net/sonic-buildimage
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added patch in FRR to send tag value associated with route
via NETLINK RTA_PRIORITY field which can be used as attribute/metadata in fpmsyncd for different use-cases. Signed-off-by: Abhishek Dosi <[email protected]>
- Loading branch information
Showing
2 changed files
with
30 additions
and
0 deletions.
There are no files selected for viewing
29 changes: 29 additions & 0 deletions
29
src/sonic-frr/patch/0054-Added-Change-in-Zebra-FPM-library-to-send-tag-value-.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
From 1d16dfa1330c67e9bd25a93117f6e34b4bbb20b7 Mon Sep 17 00:00:00 2001 | ||
From: Abhishek Dosi <[email protected]> | ||
Date: Mon, 4 Nov 2024 18:58:56 +0000 | ||
Subject: [PATCH] Added Change in Zebra FPM library to send tag value as | ||
RTNETLINK Priority field (instead of metric). This tag value can be used as | ||
metadata/attribute of the route in upper application like fpmsyncd | ||
|
||
Signed-off-by: Abhishek Dosi <[email protected]> | ||
--- | ||
zebra/zebra_fpm_netlink.c | 3 ++- | ||
1 file changed, 2 insertions(+), 1 deletion(-) | ||
|
||
diff --git a/zebra/zebra_fpm_netlink.c b/zebra/zebra_fpm_netlink.c | ||
index 231047143..2b45087d4 100644 | ||
--- a/zebra/zebra_fpm_netlink.c | ||
+++ b/zebra/zebra_fpm_netlink.c | ||
@@ -297,7 +297,8 @@ static int netlink_route_info_fill(struct netlink_route_info *ri, int cmd, | ||
|
||
ri->rtm_protocol = netlink_proto_from_route_type(re->type); | ||
ri->rtm_type = RTN_UNICAST; | ||
- ri->metric = &re->metric; | ||
+ // Patch to send tag value via NETLINK Priority field (RTA_PRIORITY). The Tag vale can be used as metadata/attribute in fpmsyncd for further processing | ||
+ ri->metric = &re->tag; | ||
|
||
for (ALL_NEXTHOPS(re->nhe->nhg, nexthop)) { | ||
if (ri->num_nhs >= zrouter.multipath_num) | ||
-- | ||
2.25.1 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters