summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--tests/topotests/bfd-topo2/r1/ipv4_routes.json6
-rw-r--r--tests/topotests/bfd-topo2/r1/ipv6_routes.json6
-rw-r--r--tests/topotests/bfd-topo2/r2/ipv4_routes.json10
-rw-r--r--tests/topotests/bfd-topo2/r2/ipv6_routes.json6
-rw-r--r--tests/topotests/bfd-topo2/r3/ipv4_routes.json8
-rw-r--r--tests/topotests/bfd-topo2/r4/ipv4_routes.json2
-rw-r--r--tests/topotests/bfd-topo2/r4/ipv6_routes.json6
-rw-r--r--tests/topotests/bgp_vrf_lite_ipv6_rtadv/r1/ipv4_routes.json4
-rw-r--r--tests/topotests/bgp_vrf_lite_ipv6_rtadv/r1/ipv6_routes.json4
-rw-r--r--tests/topotests/bgp_vrf_lite_ipv6_rtadv/r2/ipv4_routes.json4
-rw-r--r--tests/topotests/bgp_vrf_lite_ipv6_rtadv/r2/ipv6_routes.json2
-rw-r--r--zebra/rib.h12
-rw-r--r--zebra/zebra_nhg.c6
-rw-r--r--zebra/zebra_rib.c2
-rw-r--r--zebra/zebra_rnh.c4
15 files changed, 36 insertions, 46 deletions
diff --git a/tests/topotests/bfd-topo2/r1/ipv4_routes.json b/tests/topotests/bfd-topo2/r1/ipv4_routes.json
index 8a2ec25baa..b0333de410 100644
--- a/tests/topotests/bfd-topo2/r1/ipv4_routes.json
+++ b/tests/topotests/bfd-topo2/r1/ipv4_routes.json
@@ -8,7 +8,7 @@
"selected": true,
"installed": true,
"prefix": "10.0.3.0/24",
- "internalStatus": 34,
+ "internalStatus": 16,
"nexthops": [
{
"interfaceName": "r1-eth0",
@@ -30,7 +30,7 @@
"selected": true,
"installed": true,
"prefix": "10.254.254.2/32",
- "internalStatus": 34,
+ "internalStatus": 16,
"nexthops": [
{
"interfaceName": "r1-eth0",
@@ -52,7 +52,7 @@
"selected": true,
"installed": true,
"prefix": "10.254.254.1/32",
- "internalStatus": 32,
+ "internalStatus": 16,
"nexthops": [
{
"directlyConnected": true,
diff --git a/tests/topotests/bfd-topo2/r1/ipv6_routes.json b/tests/topotests/bfd-topo2/r1/ipv6_routes.json
index 618853bd42..d09439a8a6 100644
--- a/tests/topotests/bfd-topo2/r1/ipv6_routes.json
+++ b/tests/topotests/bfd-topo2/r1/ipv6_routes.json
@@ -8,7 +8,7 @@
"selected": true,
"installed": true,
"prefix": "2001:db8:4::/64",
- "internalStatus": 34,
+ "internalStatus": 16,
"nexthops": [
{
"interfaceName": "r1-eth0",
@@ -27,7 +27,7 @@
"protocol": "bgp",
"internalFlags": 0,
"metric": 0,
- "internalStatus": 2,
+ "internalStatus": 0,
"prefix": "2001:db8:1::/64",
"nexthops": [
{
@@ -47,7 +47,7 @@
"selected": true,
"installed": true,
"prefix": "2001:db8:1::/64",
- "internalStatus": 32,
+ "internalStatus": 16,
"nexthops": [
{
"directlyConnected": true,
diff --git a/tests/topotests/bfd-topo2/r2/ipv4_routes.json b/tests/topotests/bfd-topo2/r2/ipv4_routes.json
index b9d8afb430..3c41e13434 100644
--- a/tests/topotests/bfd-topo2/r2/ipv4_routes.json
+++ b/tests/topotests/bfd-topo2/r2/ipv4_routes.json
@@ -5,7 +5,7 @@
"protocol": "ospf",
"internalFlags": 0,
"metric": 10,
- "internalStatus": 2,
+ "internalStatus": 0,
"prefix": "10.0.3.0/24",
"nexthops": [
{
@@ -25,7 +25,7 @@
"selected": true,
"installed": true,
"prefix": "10.0.3.0/24",
- "internalStatus": 32,
+ "internalStatus": 16,
"nexthops": [
{
"directlyConnected": true,
@@ -47,7 +47,7 @@
"selected": true,
"installed": true,
"prefix": "10.254.254.3/32",
- "internalStatus": 34,
+ "internalStatus": 16,
"nexthops": [
{
"interfaceName": "r2-eth1",
@@ -70,7 +70,7 @@
"selected": true,
"installed": true,
"prefix": "10.254.254.2/32",
- "internalStatus": 32,
+ "internalStatus": 16,
"nexthops": [
{
"directlyConnected": true,
@@ -92,7 +92,7 @@
"selected": true,
"installed": true,
"prefix": "10.254.254.1/32",
- "internalStatus": 34,
+ "internalStatus": 16,
"nexthops": [
{
"interfaceName": "r2-eth0",
diff --git a/tests/topotests/bfd-topo2/r2/ipv6_routes.json b/tests/topotests/bfd-topo2/r2/ipv6_routes.json
index 004e7588aa..bb45bbae52 100644
--- a/tests/topotests/bfd-topo2/r2/ipv6_routes.json
+++ b/tests/topotests/bfd-topo2/r2/ipv6_routes.json
@@ -5,7 +5,7 @@
"protocol": "ospf6",
"internalFlags": 0,
"metric": 10,
- "internalStatus": 2,
+ "internalStatus": 0,
"prefix": "2001:db8:4::/64",
"nexthops": [
{
@@ -25,7 +25,7 @@
"selected": true,
"installed": true,
"prefix": "2001:db8:4::/64",
- "internalStatus": 32,
+ "internalStatus": 16,
"nexthops": [
{
"directlyConnected": true,
@@ -47,7 +47,7 @@
"selected": true,
"installed": true,
"prefix": "2001:db8:1::/64",
- "internalStatus": 32,
+ "internalStatus": 16,
"nexthops": [
{
"directlyConnected": true,
diff --git a/tests/topotests/bfd-topo2/r3/ipv4_routes.json b/tests/topotests/bfd-topo2/r3/ipv4_routes.json
index 14dfc692fe..cbf116e687 100644
--- a/tests/topotests/bfd-topo2/r3/ipv4_routes.json
+++ b/tests/topotests/bfd-topo2/r3/ipv4_routes.json
@@ -25,7 +25,7 @@
"selected": true,
"installed": true,
"prefix": "10.0.3.0/24",
- "internalStatus": 32,
+ "internalStatus": 16,
"nexthops": [
{
"directlyConnected": true,
@@ -47,7 +47,7 @@
"selected": true,
"installed": true,
"prefix": "10.254.254.3/32",
- "internalStatus": 32,
+ "internalStatus": 16,
"nexthops": [
{
"directlyConnected": true,
@@ -69,7 +69,7 @@
"selected": true,
"installed": true,
"prefix": "10.254.254.2/32",
- "internalStatus": 34,
+ "internalStatus": 16,
"nexthops": [
{
"interfaceName": "r3-eth0",
@@ -92,7 +92,7 @@
"selected": true,
"installed": true,
"prefix": "10.254.254.1/32",
- "internalStatus": 34,
+ "internalStatus": 16,
"nexthops": [
{
"interfaceName": "r3-eth0",
diff --git a/tests/topotests/bfd-topo2/r4/ipv4_routes.json b/tests/topotests/bfd-topo2/r4/ipv4_routes.json
index ae1e97b017..b06184a44d 100644
--- a/tests/topotests/bfd-topo2/r4/ipv4_routes.json
+++ b/tests/topotests/bfd-topo2/r4/ipv4_routes.json
@@ -8,7 +8,7 @@
"selected": true,
"installed": true,
"prefix": "10.254.254.4/32",
- "internalStatus": 32,
+ "internalStatus": 16,
"nexthops": [
{
"directlyConnected": true,
diff --git a/tests/topotests/bfd-topo2/r4/ipv6_routes.json b/tests/topotests/bfd-topo2/r4/ipv6_routes.json
index 33608b45aa..a22c90cbba 100644
--- a/tests/topotests/bfd-topo2/r4/ipv6_routes.json
+++ b/tests/topotests/bfd-topo2/r4/ipv6_routes.json
@@ -5,7 +5,7 @@
"protocol": "ospf6",
"internalFlags": 0,
"metric": 10,
- "internalStatus": 2,
+ "internalStatus": 0,
"prefix": "2001:db8:4::/64",
"nexthops": [
{
@@ -25,7 +25,7 @@
"selected": true,
"installed": true,
"prefix": "2001:db8:4::/64",
- "internalStatus": 32,
+ "internalStatus": 16,
"nexthops": [
{
"directlyConnected": true,
@@ -47,7 +47,7 @@
"selected": true,
"installed": true,
"prefix": "2001:db8:1::/64",
- "internalStatus": 34,
+ "internalStatus": 16,
"nexthops": [
{
"interfaceName": "r4-eth0",
diff --git a/tests/topotests/bgp_vrf_lite_ipv6_rtadv/r1/ipv4_routes.json b/tests/topotests/bgp_vrf_lite_ipv6_rtadv/r1/ipv4_routes.json
index e32c84b7d5..1649ade96d 100644
--- a/tests/topotests/bgp_vrf_lite_ipv6_rtadv/r1/ipv4_routes.json
+++ b/tests/topotests/bgp_vrf_lite_ipv6_rtadv/r1/ipv4_routes.json
@@ -9,7 +9,7 @@
"distance": 20,
"metric": 0,
"installed": true,
- "internalStatus": 34,
+ "internalStatus": 16,
"internalFlags": 8,
"nexthops": [
{
@@ -33,7 +33,7 @@
"distance": 0,
"metric": 0,
"installed": true,
- "internalStatus": 32,
+ "internalStatus": 16,
"internalFlags": 8,
"nexthops": [
{
diff --git a/tests/topotests/bgp_vrf_lite_ipv6_rtadv/r1/ipv6_routes.json b/tests/topotests/bgp_vrf_lite_ipv6_rtadv/r1/ipv6_routes.json
index 88e8c5cd83..1ca62094bd 100644
--- a/tests/topotests/bgp_vrf_lite_ipv6_rtadv/r1/ipv6_routes.json
+++ b/tests/topotests/bgp_vrf_lite_ipv6_rtadv/r1/ipv6_routes.json
@@ -6,7 +6,7 @@
"vrfId":3,
"distance": 20,
"metric": 0,
- "internalStatus": 2,
+ "internalStatus": 0,
"internalFlags": 0,
"nexthops": [
{
@@ -27,7 +27,7 @@
"distance": 0,
"metric": 0,
"installed": true,
- "internalStatus": 32,
+ "internalStatus": 16,
"internalFlags": 8,
"nexthops": [
{
diff --git a/tests/topotests/bgp_vrf_lite_ipv6_rtadv/r2/ipv4_routes.json b/tests/topotests/bgp_vrf_lite_ipv6_rtadv/r2/ipv4_routes.json
index 9d7c0e6e4f..eda4bed035 100644
--- a/tests/topotests/bgp_vrf_lite_ipv6_rtadv/r2/ipv4_routes.json
+++ b/tests/topotests/bgp_vrf_lite_ipv6_rtadv/r2/ipv4_routes.json
@@ -9,7 +9,7 @@
"distance": 0,
"metric": 0,
"installed": true,
- "internalStatus": 32,
+ "internalStatus": 16,
"internalFlags": 8,
"nexthops": [
{
@@ -33,7 +33,7 @@
"distance": 20,
"metric": 0,
"installed": true,
- "internalStatus": 34,
+ "internalStatus": 16,
"internalFlags": 8,
"nexthops": [
{
diff --git a/tests/topotests/bgp_vrf_lite_ipv6_rtadv/r2/ipv6_routes.json b/tests/topotests/bgp_vrf_lite_ipv6_rtadv/r2/ipv6_routes.json
index 230fe38748..45c1b76017 100644
--- a/tests/topotests/bgp_vrf_lite_ipv6_rtadv/r2/ipv6_routes.json
+++ b/tests/topotests/bgp_vrf_lite_ipv6_rtadv/r2/ipv6_routes.json
@@ -9,7 +9,7 @@
"distance": 0,
"metric": 0,
"installed": true,
- "internalStatus": 32,
+ "internalStatus": 16,
"internalFlags": 8,
"nexthops": [
{
diff --git a/zebra/rib.h b/zebra/rib.h
index 181286a904..b82428e54c 100644
--- a/zebra/rib.h
+++ b/zebra/rib.h
@@ -124,18 +124,16 @@ struct route_entry {
/* RIB internal status */
uint32_t status;
#define ROUTE_ENTRY_REMOVED 0x1
-/* to simplify NHT logic when NHs change, instead of doing a NH by NH cmp */
-#define ROUTE_ENTRY_NEXTHOPS_CHANGED 0x2
/* The Route Entry has changed */
-#define ROUTE_ENTRY_CHANGED 0x4
+#define ROUTE_ENTRY_CHANGED 0x2
/* The Label has changed on the Route entry */
-#define ROUTE_ENTRY_LABELS_CHANGED 0x8
+#define ROUTE_ENTRY_LABELS_CHANGED 0x4
/* Route is queued for Installation into the Data Plane */
-#define ROUTE_ENTRY_QUEUED 0x10
+#define ROUTE_ENTRY_QUEUED 0x8
/* Route is installed into the Data Plane */
-#define ROUTE_ENTRY_INSTALLED 0x20
+#define ROUTE_ENTRY_INSTALLED 0x10
/* Route has Failed installation into the Data Plane in some manner */
-#define ROUTE_ENTRY_FAILED 0x40
+#define ROUTE_ENTRY_FAILED 0x20
/* Nexthop information. */
uint8_t nexthop_num;
diff --git a/zebra/zebra_nhg.c b/zebra/zebra_nhg.c
index 4a88296051..d123602550 100644
--- a/zebra/zebra_nhg.c
+++ b/zebra/zebra_nhg.c
@@ -272,8 +272,6 @@ static int nexthop_active(afi_t afi, struct route_entry *re,
SET_FLAG(nexthop->flags,
NEXTHOP_FLAG_RECURSIVE);
- SET_FLAG(re->status,
- ROUTE_ENTRY_NEXTHOPS_CHANGED);
nexthop_set_resolved(afi, newhop, nexthop);
resolved = 1;
}
@@ -501,10 +499,8 @@ int nexthop_active_update(struct route_node *rn, struct route_entry *re)
&& nexthop->type < NEXTHOP_TYPE_BLACKHOLE)
&& !(IPV6_ADDR_SAME(&prev_src.ipv6,
&nexthop->rmap_src.ipv6)))
- || CHECK_FLAG(re->status, ROUTE_ENTRY_LABELS_CHANGED)) {
+ || CHECK_FLAG(re->status, ROUTE_ENTRY_LABELS_CHANGED))
SET_FLAG(re->status, ROUTE_ENTRY_CHANGED);
- SET_FLAG(re->status, ROUTE_ENTRY_NEXTHOPS_CHANGED);
- }
}
return re->nexthop_active_num;
diff --git a/zebra/zebra_rib.c b/zebra/zebra_rib.c
index 5dcf21f561..479e971685 100644
--- a/zebra/zebra_rib.c
+++ b/zebra/zebra_rib.c
@@ -1128,8 +1128,6 @@ static void rib_process(struct route_node *rn)
re->status, re->flags, re->distance,
re->metric);
- UNSET_FLAG(re->status, ROUTE_ENTRY_NEXTHOPS_CHANGED);
-
/* Currently selected re. */
if (CHECK_FLAG(re->flags, ZEBRA_FLAG_SELECTED)) {
assert(old_selected == NULL);
diff --git a/zebra/zebra_rnh.c b/zebra/zebra_rnh.c
index 6f65f8ab7a..5a10892d9a 100644
--- a/zebra/zebra_rnh.c
+++ b/zebra/zebra_rnh.c
@@ -859,10 +859,8 @@ static void zebra_rnh_clear_nhc_flag(struct zebra_vrf *zvrf, afi_t afi,
re = zebra_rnh_resolve_nexthop_entry(zvrf, afi, nrn, rnh,
&prn);
- if (re) {
- UNSET_FLAG(re->status, ROUTE_ENTRY_NEXTHOPS_CHANGED);
+ if (re)
UNSET_FLAG(re->status, ROUTE_ENTRY_LABELS_CHANGED);
- }
}
/* Evaluate all tracked entries (nexthops or routes for import into BGP)