summaryrefslogtreecommitdiff
path: root/eigrpd/eigrp_update.c
diff options
context:
space:
mode:
authorDonald Sharp <sharpd@cumulusnetworks.com>2017-08-22 14:40:24 -0400
committerDonald Sharp <sharpd@cumulusnetworks.com>2017-08-24 08:04:20 -0400
commitcd0442479369e53f3b8451163a8679a00f4c0d25 (patch)
tree6f29144967cb02ee1a684dc724d630cf594b6a81 /eigrpd/eigrp_update.c
parentcbe6eca6a60e6910ed60998b7e0dd287fb791295 (diff)
eigrpd: Start split-horizon
EIGRP was not handling split-horizon. This code starts down the path of properly considering it. There still exists situations where we are not properly handling it though. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Diffstat (limited to 'eigrpd/eigrp_update.c')
-rw-r--r--eigrpd/eigrp_update.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/eigrpd/eigrp_update.c b/eigrpd/eigrp_update.c
index d0c6520c4e..2934c6c652 100644
--- a/eigrpd/eigrp_update.c
+++ b/eigrpd/eigrp_update.c
@@ -610,8 +610,7 @@ void eigrp_update_send_EOT(struct eigrp_neighbor *nbr)
for (ALL_LIST_ELEMENTS(nbr->ei->eigrp->topology_table, node, nnode, pe)) {
for (ALL_LIST_ELEMENTS(pe->entries, node2, nnode2, te)) {
- if ((te->ei == nbr->ei)
- && (te->prefix->nt == EIGRP_TOPOLOGY_TYPE_REMOTE))
+ if (eigrp_nbr_split_horizon_check(te, nbr->ei))
continue;
if ((length + 0x001D) > (u_int16_t)nbr->ei->ifp->mtu) {
@@ -701,10 +700,15 @@ void eigrp_update_send(struct eigrp_interface *ei)
has_tlv = 0;
for (ALL_LIST_ELEMENTS(ei->eigrp->topology_changes_internalIPV4, node,
nnode, pe)) {
+ struct eigrp_neighbor_entry *ne;
if (!(pe->req_action & EIGRP_FSM_NEED_UPDATE))
continue;
+ ne = listnode_head(pe->entries);
+ if (eigrp_nbr_split_horizon_check(ne, ei))
+ continue;
+
if ((length + 0x001D) > (u_int16_t)ei->ifp->mtu) {
if ((IF_DEF_PARAMS(ei->ifp)->auth_type == EIGRP_AUTH_TYPE_MD5)
&& (IF_DEF_PARAMS(ei->ifp)->auth_keychain != NULL)) {