[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20210608175937.900254955@linuxfoundation.org>
Date: Tue, 8 Jun 2021 20:27:47 +0200
From: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
To: linux-kernel@...r.kernel.org
Cc: Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
stable@...r.kernel.org,
Kasper Dupont <kasperd@...wv.06.feb.2021.kasperd.net>,
Thadeu Lima de Souza Cascardo <cascardo@...onical.com>,
David Ahern <dsahern@...nel.org>,
"David S. Miller" <davem@...emloft.net>
Subject: [PATCH 5.4 78/78] neighbour: allow NUD_NOARP entries to be forced GCed
From: David Ahern <dsahern@...nel.org>
commit 7a6b1ab7475fd6478eeaf5c9d1163e7a18125c8f 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 58956317c8de ("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: 58956317c8de (neighbor: Improve garbage collection)
Reported-by: Kasper Dupont <kasperd@...wv.06.feb.2021.kasperd.net>
Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@...onical.com>
Signed-off-by: David Ahern <dsahern@...nel.org>
Signed-off-by: David S. Miller <davem@...emloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
---
net/core/neighbour.c | 1 +
1 file changed, 1 insertion(+)
--- a/net/core/neighbour.c
+++ b/net/core/neighbour.c
@@ -239,6 +239,7 @@ static int neigh_forced_gc(struct neigh_
write_lock(&n->lock);
if ((n->nud_state == NUD_FAILED) ||
+ (n->nud_state == NUD_NOARP) ||
(tbl->is_multicast &&
tbl->is_multicast(n->primary_key)) ||
time_after(tref, n->updated))
Powered by blists - more mailing lists