From 744c63be132a4644c7c3799a0f0d2a07bfc5b98a Mon Sep 17 00:00:00 2001 From: vivek Date: Fri, 1 Mar 2019 07:10:53 +0000 Subject: [PATCH] zebra: Use next hop's VRF for EVPN-based routes Ensure that the next hop's VRF is used for IPv4 and IPv6 unicast routes sourced from EVPN routes, for next hop and Router MAC tracking and install. This way, leaked routes from other instances are handled properly. Signed-off-by: Vivek Venkatraman Reviewed-by: Anuradha Karuppiah Reviewed-by: Donald Sharp --- zebra/zapi_msg.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/zebra/zapi_msg.c b/zebra/zapi_msg.c index 9b91289dec..ef9917d4e6 100644 --- a/zebra/zapi_msg.c +++ b/zebra/zapi_msg.c @@ -1463,8 +1463,8 @@ static void zread_route_add(ZAPI_HANDLER_ARGS) &(api_nh->gate.ipv4), sizeof(struct in_addr)); zebra_vxlan_evpn_vrf_route_add( - vrf_id, &api_nh->rmac, &vtep_ip, - &api.prefix); + api_nh->vrf_id, &api_nh->rmac, + &vtep_ip, &api.prefix); } break; case NEXTHOP_TYPE_IPV6: @@ -1493,8 +1493,8 @@ static void zread_route_add(ZAPI_HANDLER_ARGS) memcpy(&vtep_ip.ipaddr_v6, &(api_nh->gate.ipv6), sizeof(struct in6_addr)); zebra_vxlan_evpn_vrf_route_add( - vrf_id, &api_nh->rmac, &vtep_ip, - &api.prefix); + api_nh->vrf_id, &api_nh->rmac, + &vtep_ip, &api.prefix); } break; case NEXTHOP_TYPE_BLACKHOLE: