diff options
author | David S. Miller <davem@davemloft.net> | 2011-07-16 20:36:53 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2011-07-16 20:36:53 -0400 |
commit | 0895b08adeb3f660cdff21990d0a9c2b59a919e7 (patch) | |
tree | c0e96f6775d38b79a8f7a614490f09282ccc855d | |
parent | 05e3aa0949c138803185f92bd7db9be59cfca1be (diff) |
neigh: Simply destroy handling wrt. hh_cache.
Now that hh_cache entries are embedded inside of neighbour
entries, their lifetimes and accesses are now synchronous
to that of the encompassing neighbour object.
Therefore we don't need to hook up the blackhole op to
hh_output on destroy.
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | net/core/neighbour.c | 9 |
1 files changed, 0 insertions, 9 deletions
diff --git a/net/core/neighbour.c b/net/core/neighbour.c index 77a399f2ad03..83f9998f3347 100644 --- a/net/core/neighbour.c +++ b/net/core/neighbour.c | |||
@@ -689,8 +689,6 @@ static void neigh_destroy_rcu(struct rcu_head *head) | |||
689 | */ | 689 | */ |
690 | void neigh_destroy(struct neighbour *neigh) | 690 | void neigh_destroy(struct neighbour *neigh) |
691 | { | 691 | { |
692 | struct hh_cache *hh; | ||
693 | |||
694 | NEIGH_CACHE_STAT_INC(neigh->tbl, destroys); | 692 | NEIGH_CACHE_STAT_INC(neigh->tbl, destroys); |
695 | 693 | ||
696 | if (!neigh->dead) { | 694 | if (!neigh->dead) { |
@@ -703,13 +701,6 @@ void neigh_destroy(struct neighbour *neigh) | |||
703 | if (neigh_del_timer(neigh)) | 701 | if (neigh_del_timer(neigh)) |
704 | printk(KERN_WARNING "Impossible event.\n"); | 702 | printk(KERN_WARNING "Impossible event.\n"); |
705 | 703 | ||
706 | hh = &neigh->hh; | ||
707 | if (hh->hh_len) { | ||
708 | write_seqlock_bh(&hh->hh_lock); | ||
709 | hh->hh_output = neigh_blackhole; | ||
710 | write_sequnlock_bh(&hh->hh_lock); | ||
711 | } | ||
712 | |||
713 | skb_queue_purge(&neigh->arp_queue); | 704 | skb_queue_purge(&neigh->arp_queue); |
714 | 705 | ||
715 | dev_put(neigh->dev); | 706 | dev_put(neigh->dev); |