Message ID | 4C7FEE55.8060002@dti2.net |
---|---|
State | Not Applicable, archived |
Delegated to: | David Miller |
Headers | show |
From: "Jorge Boncompte [DTI2]" <jorge@dti2.net> Date: Thu, 02 Sep 2010 20:35:01 +0200 > Skip entries from foreign network namespaces. > > Signed-off-by: Jorge Boncompte [DTI2] <jorge@dti2.net> Your email client mangled the patch, breaking up long lines and making other textual changes to the patch, which makes it unusable. Please report this in an unmangled form. Thanks. -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/net/core/neighbour.c b/net/core/neighbour.c index a4e0a74..4c36fa9 100644 --- a/net/core/neighbour.c +++ b/net/core/neighbour.c @@ -2323,6 +2323,7 @@ static struct pneigh_entry *pneigh_get_next(struct seq_file *seq, struct net *net = seq_file_net(seq); struct neigh_table *tbl = state->tbl; +restart: pn = pn->next; while (!pn) {
Skip entries from foreign network namespaces. Signed-off-by: Jorge Boncompte [DTI2] <jorge@dti2.net> --- net/core/neighbour.c | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-) if (++state->bucket > PNEIGH_HASHMASK) @@ -2334,6 +2335,9 @@ static struct pneigh_entry *pneigh_get_next(struct seq_file *seq, break; } + if (pn && !net_eq(pneigh_net(pn), net)) + goto restart; + if (pn && pos) --(*pos);