Commit 80703d26 authored by David S. Miller's avatar David S. Miller

ipv4: Eliminate spurious argument to __ipv4_neigh_lookup

'tbl' is always arp_tbl, so specifying it is pointless.
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 4c5e4036
...@@ -15,14 +15,14 @@ static inline u32 arp_hashfn(u32 key, const struct net_device *dev, u32 hash_rnd ...@@ -15,14 +15,14 @@ static inline u32 arp_hashfn(u32 key, const struct net_device *dev, u32 hash_rnd
return val * hash_rnd; return val * hash_rnd;
} }
static inline struct neighbour *__ipv4_neigh_lookup(struct neigh_table *tbl, struct net_device *dev, u32 key) static inline struct neighbour *__ipv4_neigh_lookup(struct net_device *dev, u32 key)
{ {
struct neigh_hash_table *nht; struct neigh_hash_table *nht;
struct neighbour *n; struct neighbour *n;
u32 hash_val; u32 hash_val;
rcu_read_lock_bh(); rcu_read_lock_bh();
nht = rcu_dereference_bh(tbl->nht); nht = rcu_dereference_bh(arp_tbl.nht);
hash_val = arp_hashfn(key, dev, nht->hash_rnd[0]) >> (32 - nht->hash_shift); hash_val = arp_hashfn(key, dev, nht->hash_rnd[0]) >> (32 - nht->hash_shift);
for (n = rcu_dereference_bh(nht->hash_buckets[hash_val]); for (n = rcu_dereference_bh(nht->hash_buckets[hash_val]);
n != NULL; n != NULL;
......
...@@ -1127,7 +1127,7 @@ static struct neighbour *ipv4_neigh_lookup(const struct dst_entry *dst, const vo ...@@ -1127,7 +1127,7 @@ static struct neighbour *ipv4_neigh_lookup(const struct dst_entry *dst, const vo
else if (rt->rt_gateway) else if (rt->rt_gateway)
pkey = (const __be32 *) &rt->rt_gateway; pkey = (const __be32 *) &rt->rt_gateway;
n = __ipv4_neigh_lookup(&arp_tbl, dev, *(__force u32 *)pkey); n = __ipv4_neigh_lookup(dev, *(__force u32 *)pkey);
if (n) if (n)
return n; return n;
return neigh_create(&arp_tbl, pkey, dev); return neigh_create(&arp_tbl, pkey, dev);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment