diff options
author | Nikhil Kelapure <nikhil.kelapure@broadcom.com> | 2021-09-12 21:25:00 +0200 |
---|---|---|
committer | Nikhil Kelapure <nikhil.kelapure@broadcom.com> | 2021-09-13 17:39:43 +0200 |
commit | 316d2d52a25a4047f08952dd4aca6192be6240c7 (patch) | |
tree | ba876a25f300bfdef2691f976d588cd79cf72145 /zebra/zebra_fpm_private.h | |
parent | Merge pull request #9586 from idryzhov/bgp-default-originate-rmap-fixes (diff) | |
download | frr-316d2d52a25a4047f08952dd4aca6192be6240c7.tar.xz frr-316d2d52a25a4047f08952dd4aca6192be6240c7.zip |
zebra: Fix IPv4 routes with IPv6 link local next hops install in FPM
Description: Currently IPv4 routes with IPv6 link local next hops are
not properly installed in FPM.
Reason is the netlink decoding truncates the ipv6 LL address to 4 byte
ipv4 address.
Ex : fe80:: is directly converted to ipv4 and it results in 254.128.0.0
as next hop for below routes
show ip route
Codes: K - kernel route, C - connected, S - static, R - RIP,
O - OSPF, I - IS-IS, B - BGP, E - EIGRP, N - NHRP,
T - Table, v - VNC, V - VNC-Direct, A - Babel, D - SHARP,
F - PBR, f - OpenFabric,
> - selected route, * - FIB route, q - queued, r - rejected, b - backup
B>* 2.1.0.0/16 [200/0] via fe80::268a:7ff:fed0:d40, Ethernet0, weight 1,
02:22:26
B>* 5.1.0.0/16 [200/0] via fe80::268a:7ff:fed0:d40, Ethernet0, weight 1,
02:22:26
B>* 10.1.0.2/32 [200/0] via fe80::268a:7ff:fed0:d40, Ethernet0, weight
1, 02:22:26
Hence this fix converts the ipv6-LL address to ipv4-LL (169.254.0.1)
address before sending it to FPM. This is inline with how these types of
routes are currently programmed into kernel.
Signed-off-by: Nikhil Kelapure <nikhil.kelapure@broadcom.com>
Diffstat (limited to 'zebra/zebra_fpm_private.h')
-rw-r--r-- | zebra/zebra_fpm_private.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/zebra/zebra_fpm_private.h b/zebra/zebra_fpm_private.h index c169ee8c2..13415c7e1 100644 --- a/zebra/zebra_fpm_private.h +++ b/zebra/zebra_fpm_private.h @@ -97,6 +97,8 @@ extern int zfpm_netlink_encode_mac(struct fpm_mac_info_t *mac, char *in_buf, extern struct route_entry *zfpm_route_for_update(rib_dest_t *dest); +extern union g_addr ipv4ll_gateway; + #ifdef __cplusplus } #endif |