Skip to content

Commit

Permalink
zebra: relax if_type check to allow early ES config creation
Browse files Browse the repository at this point in the history
The API for configuring ES in zebra had a strict check for if_type
"isBond" that prevented the ES config from being created before the
interface.

Ticket: CM-29454

Signed-off-by: Anuradha Karuppiah <[email protected]>
  • Loading branch information
AnuradhaKaruppiah authored and donaldsharp committed Nov 10, 2022
1 parent e07ff2c commit 3fa177e
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions zebra/zebra_evpn_mh.c
Original file line number Diff line number Diff line change
Expand Up @@ -2759,6 +2759,12 @@ bool zebra_evpn_is_if_es_capable(struct zebra_if *zif)
if (zif->zif_type == ZEBRA_IF_BOND)
return true;

/* relax the checks to allow config to be applied in zebra
* before interface is rxed from the kernel
*/
if (zif->ifp->ifindex == IFINDEX_INTERNAL)
return true;

/* XXX: allow swpX i.e. a regular ethernet port to be an ES link too */
return false;
}
Expand Down

0 comments on commit 3fa177e

Please sign in to comment.