summaryrefslogtreecommitdiff
path: root/net/core/neighbour.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2011-11-26 14:47:03 -0500
committerDavid S. Miller <davem@davemloft.net>2011-11-26 14:47:03 -0500
commit6dec4ac4ee1ad894dc0e9647cd3e180f93fc353c (patch)
treecd71e597bbbe677820bb229c6aedbad412758959 /net/core/neighbour.c
parentd6f03f29f7cdf064289f941bf0b838348e996e65 (diff)
parentfc0b927d9a5024e138c4318fe19a590f23e3eeec (diff)
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Conflicts: net/ipv4/inet_diag.c
Diffstat (limited to 'net/core/neighbour.c')
-rw-r--r--net/core/neighbour.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/net/core/neighbour.c b/net/core/neighbour.c
index 2684794458ca..27d3fefeaa13 100644
--- a/net/core/neighbour.c
+++ b/net/core/neighbour.c
@@ -2414,7 +2414,10 @@ static struct pneigh_entry *pneigh_get_next(struct seq_file *seq,
struct net *net = seq_file_net(seq);
struct neigh_table *tbl = state->tbl;
- pn = pn->next;
+ do {
+ pn = pn->next;
+ } while (pn && !net_eq(pneigh_net(pn), net));
+
while (!pn) {
if (++state->bucket > PNEIGH_HASHMASK)
break;