summaryrefslogtreecommitdiff
path: root/packages
diff options
context:
space:
mode:
authorChristian Breunig <christian@breunig.cc>2024-07-22 15:26:07 +0200
committerGitHub <noreply@github.com>2024-07-22 15:26:07 +0200
commitd07b978408143ed9cc13742258f6e9731714f95f (patch)
treeb7c2bb60c3cff5fa53e20a741bd3aee24f9546e8 /packages
parente880af90ac92b41c44307e49a3cd456baad2724e (diff)
parentbef7b3eda985c7b17ca4e3441e45a08c5de143cf (diff)
downloadvyos-build-d07b978408143ed9cc13742258f6e9731714f95f.tar.gz
vyos-build-d07b978408143ed9cc13742258f6e9731714f95f.zip
Merge pull request #704 from c-po/frr-ospfd-ldp-sync
frr: T6600: apply pending upstream patch for ospfd ldp-sync
Diffstat (limited to 'packages')
-rw-r--r--packages/frr/patches/0001-ospfd-fix-internal-ldp-sync-state-flags-when-feature.patch129
1 files changed, 129 insertions, 0 deletions
diff --git a/packages/frr/patches/0001-ospfd-fix-internal-ldp-sync-state-flags-when-feature.patch b/packages/frr/patches/0001-ospfd-fix-internal-ldp-sync-state-flags-when-feature.patch
new file mode 100644
index 00000000..5d05cdcd
--- /dev/null
+++ b/packages/frr/patches/0001-ospfd-fix-internal-ldp-sync-state-flags-when-feature.patch
@@ -0,0 +1,129 @@
+From 5a70378a47f541b0354fbb96770dd0a65ec552b8 Mon Sep 17 00:00:00 2001
+From: Christian Breunig <christian@breunig.cc>
+Date: Sat, 13 Jul 2024 08:43:36 +0200
+Subject: [PATCH] ospfd: fix internal ldp-sync state flags when feature is
+ disabled
+
+When enabling "mpls ldp-sync" under "router ospf" ospfd configures
+SET_FLAG(ldp_sync_info->flags, LDP_SYNC_FLAG_IF_CONFIG) so internally knowing
+that the ldp-sync feature is enabled. However the flag is not cleared when
+turning of the feature using "nompls ldp-sync"!
+
+https://github.com/FRRouting/frr/issues/16375
+
+Signed-off-by: Christian Breunig <christian@breunig.cc>
+---
+ ospfd/ospf_ldp_sync.c | 2 +-
+ tests/topotests/ldp_sync_ospf_topo1/r2/show_ospf_ldp_sync.ref | 4 ++--
+ .../r2/show_ospf_ldp_sync_r1_eth1_shutdown.ref | 4 ++--
+ .../r2/show_ospf_ldp_sync_r2_eth1_shutdown.ref | 4 ++--
+ tests/topotests/ldp_sync_ospf_topo1/r3/show_ospf_ldp_sync.ref | 4 ++--
+ .../r3/show_ospf_ldp_sync_r1_eth1_shutdown.ref | 4 ++--
+ .../r3/show_ospf_ldp_sync_r2_eth1_shutdown.ref | 4 ++--
+ 7 files changed, 13 insertions(+), 13 deletions(-)
+
+diff --git a/ospfd/ospf_ldp_sync.c b/ospfd/ospf_ldp_sync.c
+index d1ef85c9a..496ae5b4b 100644
+--- a/ospfd/ospf_ldp_sync.c
++++ b/ospfd/ospf_ldp_sync.c
+@@ -901,7 +901,7 @@ DEFPY (no_mpls_ldp_sync,
+ * stop holddown timer if running
+ * restore ospf cost
+ */
+- SET_FLAG(ldp_sync_info->flags, LDP_SYNC_FLAG_IF_CONFIG);
++ UNSET_FLAG(ldp_sync_info->flags, LDP_SYNC_FLAG_IF_CONFIG);
+ ldp_sync_info->enabled = LDP_IGP_SYNC_DEFAULT;
+ ldp_sync_info->state = LDP_IGP_SYNC_STATE_NOT_REQUIRED;
+ EVENT_OFF(ldp_sync_info->t_holddown);
+diff --git a/tests/topotests/ldp_sync_ospf_topo1/r2/show_ospf_ldp_sync.ref b/tests/topotests/ldp_sync_ospf_topo1/r2/show_ospf_ldp_sync.ref
+index 6c27a1042..846be5b84 100644
+--- a/tests/topotests/ldp_sync_ospf_topo1/r2/show_ospf_ldp_sync.ref
++++ b/tests/topotests/ldp_sync_ospf_topo1/r2/show_ospf_ldp_sync.ref
+@@ -5,8 +5,8 @@
+ "ldpIgpSyncState":"Sync achieved"
+ },
+ "r2-eth2":{
+- "ldpIgpSyncEnabled":false,
++ "ldpIgpSyncEnabled":true,
+ "holdDownTimeInSec":50,
+- "ldpIgpSyncState":"Sync not required"
++ "ldpIgpSyncState":"Sync achieved"
+ }
+ }
+diff --git a/tests/topotests/ldp_sync_ospf_topo1/r2/show_ospf_ldp_sync_r1_eth1_shutdown.ref b/tests/topotests/ldp_sync_ospf_topo1/r2/show_ospf_ldp_sync_r1_eth1_shutdown.ref
+index 889f69ed7..ad3b8b5ca 100644
+--- a/tests/topotests/ldp_sync_ospf_topo1/r2/show_ospf_ldp_sync_r1_eth1_shutdown.ref
++++ b/tests/topotests/ldp_sync_ospf_topo1/r2/show_ospf_ldp_sync_r1_eth1_shutdown.ref
+@@ -5,8 +5,8 @@
+ "ldpIgpSyncState":"Holding down until Sync"
+ },
+ "r2-eth2":{
+- "ldpIgpSyncEnabled":false,
++ "ldpIgpSyncEnabled":true,
+ "holdDownTimeInSec":50,
+- "ldpIgpSyncState":"Sync not required"
++ "ldpIgpSyncState":"Sync achieved"
+ }
+ }
+diff --git a/tests/topotests/ldp_sync_ospf_topo1/r2/show_ospf_ldp_sync_r2_eth1_shutdown.ref b/tests/topotests/ldp_sync_ospf_topo1/r2/show_ospf_ldp_sync_r2_eth1_shutdown.ref
+index d9036e124..d5e4b88d0 100644
+--- a/tests/topotests/ldp_sync_ospf_topo1/r2/show_ospf_ldp_sync_r2_eth1_shutdown.ref
++++ b/tests/topotests/ldp_sync_ospf_topo1/r2/show_ospf_ldp_sync_r2_eth1_shutdown.ref
+@@ -1,7 +1,7 @@
+ {
+ "r2-eth2":{
+- "ldpIgpSyncEnabled":false,
++ "ldpIgpSyncEnabled":true,
+ "holdDownTimeInSec":50,
+- "ldpIgpSyncState":"Sync not required"
++ "ldpIgpSyncState":"Sync achieved"
+ }
+ }
+diff --git a/tests/topotests/ldp_sync_ospf_topo1/r3/show_ospf_ldp_sync.ref b/tests/topotests/ldp_sync_ospf_topo1/r3/show_ospf_ldp_sync.ref
+index b417ab040..5b9542d5a 100644
+--- a/tests/topotests/ldp_sync_ospf_topo1/r3/show_ospf_ldp_sync.ref
++++ b/tests/topotests/ldp_sync_ospf_topo1/r3/show_ospf_ldp_sync.ref
+@@ -1,8 +1,8 @@
+ {
+ "r3-eth1":{
+- "ldpIgpSyncEnabled":false,
++ "ldpIgpSyncEnabled":true,
+ "holdDownTimeInSec":50,
+- "ldpIgpSyncState":"Sync not required"
++ "ldpIgpSyncState":"Sync achieved"
+ },
+ "r3-eth2":{
+ "ldpIgpSyncEnabled":true,
+diff --git a/tests/topotests/ldp_sync_ospf_topo1/r3/show_ospf_ldp_sync_r1_eth1_shutdown.ref b/tests/topotests/ldp_sync_ospf_topo1/r3/show_ospf_ldp_sync_r1_eth1_shutdown.ref
+index b417ab040..5b9542d5a 100644
+--- a/tests/topotests/ldp_sync_ospf_topo1/r3/show_ospf_ldp_sync_r1_eth1_shutdown.ref
++++ b/tests/topotests/ldp_sync_ospf_topo1/r3/show_ospf_ldp_sync_r1_eth1_shutdown.ref
+@@ -1,8 +1,8 @@
+ {
+ "r3-eth1":{
+- "ldpIgpSyncEnabled":false,
++ "ldpIgpSyncEnabled":true,
+ "holdDownTimeInSec":50,
+- "ldpIgpSyncState":"Sync not required"
++ "ldpIgpSyncState":"Sync achieved"
+ },
+ "r3-eth2":{
+ "ldpIgpSyncEnabled":true,
+diff --git a/tests/topotests/ldp_sync_ospf_topo1/r3/show_ospf_ldp_sync_r2_eth1_shutdown.ref b/tests/topotests/ldp_sync_ospf_topo1/r3/show_ospf_ldp_sync_r2_eth1_shutdown.ref
+index b417ab040..5b9542d5a 100644
+--- a/tests/topotests/ldp_sync_ospf_topo1/r3/show_ospf_ldp_sync_r2_eth1_shutdown.ref
++++ b/tests/topotests/ldp_sync_ospf_topo1/r3/show_ospf_ldp_sync_r2_eth1_shutdown.ref
+@@ -1,8 +1,8 @@
+ {
+ "r3-eth1":{
+- "ldpIgpSyncEnabled":false,
++ "ldpIgpSyncEnabled":true,
+ "holdDownTimeInSec":50,
+- "ldpIgpSyncState":"Sync not required"
++ "ldpIgpSyncState":"Sync achieved"
+ },
+ "r3-eth2":{
+ "ldpIgpSyncEnabled":true,
+--
+2.39.2
+