summaryrefslogtreecommitdiffstats
path: root/net/core
diff options
context:
space:
mode:
authorLeon Romanovsky <leonro@nvidia.com>2023-03-08 11:23:13 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2023-06-21 15:39:59 +0200
commitbd1c9c2bd6a3b9722d3f1e5b4583936e49841dec (patch)
tree956bae5adbd9248bc26abcb41648f2ba2824f22b /net/core
parentd70ab0d6261a53e841a4294fb8581f1fe2bbd454 (diff)
downloadlinux-stable-bd1c9c2bd6a3b9722d3f1e5b4583936e49841dec.tar.gz
linux-stable-bd1c9c2bd6a3b9722d3f1e5b4583936e49841dec.tar.bz2
linux-stable-bd1c9c2bd6a3b9722d3f1e5b4583936e49841dec.zip
neighbour: delete neigh_lookup_nodev as not used
commit 76b9bf965c98c9b53ef7420b3b11438dbd764f92 upstream. neigh_lookup_nodev isn't used in the kernel after removal of DECnet. So let's remove it. Fixes: 1202cdd66531 ("Remove DECnet support from kernel") Signed-off-by: Leon Romanovsky <leonro@nvidia.com> Reviewed-by: Eric Dumazet <edumazet@google.com> Reviewed-by: Nikolay Aleksandrov <razor@blackwall.org> Link: https://lore.kernel.org/r/eb5656200d7964b2d177a36b77efa3c597d6d72d.1678267343.git.leonro@nvidia.com Signed-off-by: Jakub Kicinski <kuba@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'net/core')
-rw-r--r--net/core/neighbour.c31
1 files changed, 0 insertions, 31 deletions
diff --git a/net/core/neighbour.c b/net/core/neighbour.c
index 778be5866d0a..5b6f3175d55b 100644
--- a/net/core/neighbour.c
+++ b/net/core/neighbour.c
@@ -476,37 +476,6 @@ struct neighbour *neigh_lookup(struct neigh_table *tbl, const void *pkey,
}
EXPORT_SYMBOL(neigh_lookup);
-struct neighbour *neigh_lookup_nodev(struct neigh_table *tbl, struct net *net,
- const void *pkey)
-{
- struct neighbour *n;
- unsigned int key_len = tbl->key_len;
- u32 hash_val;
- struct neigh_hash_table *nht;
-
- NEIGH_CACHE_STAT_INC(tbl, lookups);
-
- rcu_read_lock_bh();
- nht = rcu_dereference_bh(tbl->nht);
- hash_val = tbl->hash(pkey, NULL, nht->hash_rnd) >> (32 - nht->hash_shift);
-
- for (n = rcu_dereference_bh(nht->hash_buckets[hash_val]);
- n != NULL;
- n = rcu_dereference_bh(n->next)) {
- if (!memcmp(n->primary_key, pkey, key_len) &&
- net_eq(dev_net(n->dev), net)) {
- if (!refcount_inc_not_zero(&n->refcnt))
- n = NULL;
- NEIGH_CACHE_STAT_INC(tbl, hits);
- break;
- }
- }
-
- rcu_read_unlock_bh();
- return n;
-}
-EXPORT_SYMBOL(neigh_lookup_nodev);
-
struct neighbour *__neigh_create(struct neigh_table *tbl, const void *pkey,
struct net_device *dev, bool want_ref)
{