Skip to content

Commit d33d548

Browse files
author
vedganes
committed
[voq/inbandif]Code review comments fix 3
Signed-off-by: vedganes <vedavinayagam.ganesan@nokia.com> Changes done to delete kernel neigh when there is failure in adding kernel neigh for voq system neighbors if kernel entry already exists. When there is mac change, system neighs are synced with changed mac. With voq inband port type, static neighbor for this system neighbors are added in kernel always with single chassis mac address. So to take care of skpping adding neighbor we delete the kernel neighbor so that next re-try will program the neighbor and hence the route addition will proceed.
1 parent 1f1fc0d commit d33d548

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

cfgmgr/nbrmgr.cpp

+3
Original file line numberDiff line numberDiff line change
@@ -369,6 +369,9 @@ void NbrMgr::doStateSystemNeighTask(Consumer &consumer)
369369
if (!addKernelNeigh(nbr_odev, ip_address, mac_address))
370370
{
371371
SWSS_LOG_ERROR("Neigh entry add on dev %s failed for '%s'", nbr_odev.c_str(), kfvKey(t).c_str());
372+
// Delete neigh to take care of deletion of exiting nbr for mac change. This makes sure that
373+
// re-try will be successful and route addtion (below) will be attempted and be successful
374+
delKernelNeigh(nbr_odev, ip_address);
372375
it++;
373376
continue;
374377
}

0 commit comments

Comments
 (0)