Skip to content

Commit 0895b08

Browse files
committed
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>
1 parent 05e3aa0 commit 0895b08

1 file changed

Lines changed: 0 additions & 9 deletions

File tree

‎net/core/neighbour.c‎

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -689,8 +689,6 @@ static void neigh_destroy_rcu(struct rcu_head *head)
689689
*/
690690
void neigh_destroy(struct neighbour *neigh)
691691
{
692-
struct hh_cache *hh;
693-
694692
NEIGH_CACHE_STAT_INC(neigh->tbl, destroys);
695693

696694
if (!neigh->dead) {
@@ -703,13 +701,6 @@ void neigh_destroy(struct neighbour *neigh)
703701
if (neigh_del_timer(neigh))
704702
printk(KERN_WARNING "Impossible event.\n");
705703

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-
713704
skb_queue_purge(&neigh->arp_queue);
714705

715706
dev_put(neigh->dev);

0 commit comments

Comments
 (0)