Skip to content

Commit d17d47d

Browse files
dsaherngregkh
authored andcommitted
neighbour: allow NUD_NOARP entries to be forced GCed
commit 7a6b1ab upstream. IFF_POINTOPOINT interfaces use NUD_NOARP entries for IPv6. It's possible to fill up the neighbour table with enough entries that it will overflow for valid connections after that. This behaviour is more prevalent after commit 5895631 ("neighbor: Improve garbage collection") is applied, as it prevents removal from entries that are not NUD_FAILED, unless they are more than 5s old. Fixes: 5895631 (neighbor: Improve garbage collection) Reported-by: Kasper Dupont <kasperd@gjkwv.06.feb.2021.kasperd.net> Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@canonical.com> Signed-off-by: David Ahern <dsahern@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent 6b53db8 commit d17d47d

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

net/core/neighbour.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -239,6 +239,7 @@ static int neigh_forced_gc(struct neigh_table *tbl)
239239

240240
write_lock(&n->lock);
241241
if ((n->nud_state == NUD_FAILED) ||
242+
(n->nud_state == NUD_NOARP) ||
242243
(tbl->is_multicast &&
243244
tbl->is_multicast(n->primary_key)) ||
244245
time_after(tref, n->updated))

0 commit comments

Comments
 (0)