History

Revert "neighbour: force neigh_invalidate when NUD_FAILED update is from admin"

This reverts commit 8e326289e3069dfc9fa9c209924668dd031ab8ef. This patch results in unnecessary netlink notification when one tries to delete a neigh entry already in NUD_FAILED state. Found this with a buggy app that tries to delete a NUD_FAILED entry repeatedly. While the notification issue can be fixed with more checks, adding more complexity here seems unnecessary. Also, recent tests with other changes in the neighbour code have shown that the INCOMPLETE and PROBE checks are good enough for the original issue.

Roopa Prabhu committed 8 years ago

Commit d2fb4fb1 parent 4ba4c561 file · +1 −2Browse files

Unified · Split

net/core/neighbour.c+1−2
@@ -1148,8 +1148,7 @@ int neigh_update(struct neighbour *neigh, const u8 *lladdr, u8 new, · 1147 unmodified lines
11481148 neigh->nud_state = new;
11491149 err = 0;
11501150 notify = old & NUD_VALID;
1151− if (((old & (NUD_INCOMPLETE | NUD_PROBE)) ||
1152− (flags & NEIGH_UPDATE_F_ADMIN)) &&
1151+ if ((old & (NUD_INCOMPLETE | NUD_PROBE)) &&
11531152 (new & NUD_FAILED)) {
11541153 neigh_invalidate(neigh);
11551154 notify = 1;