neighbour.h (448cc2fb3a7b327823a9afd374808c37b8e6194f) | neighbour.h (1e84dc6b7bbfc4d1dd846decece4611b7e035772) |
---|---|
1/* SPDX-License-Identifier: GPL-2.0 */ 2#ifndef _NET_NEIGHBOUR_H 3#define _NET_NEIGHBOUR_H 4 5#include <linux/neighbour.h> 6 7/* 8 * Generic neighbour manipulation --- 307 unchanged lines hidden (view full) --- 316 317static inline struct neighbour *__neigh_lookup_noref(struct neigh_table *tbl, 318 const void *pkey, 319 struct net_device *dev) 320{ 321 return ___neigh_lookup_noref(tbl, tbl->key_eq, tbl->hash, pkey, dev); 322} 323 | 1/* SPDX-License-Identifier: GPL-2.0 */ 2#ifndef _NET_NEIGHBOUR_H 3#define _NET_NEIGHBOUR_H 4 5#include <linux/neighbour.h> 6 7/* 8 * Generic neighbour manipulation --- 307 unchanged lines hidden (view full) --- 316 317static inline struct neighbour *__neigh_lookup_noref(struct neigh_table *tbl, 318 const void *pkey, 319 struct net_device *dev) 320{ 321 return ___neigh_lookup_noref(tbl, tbl->key_eq, tbl->hash, pkey, dev); 322} 323 |
324static inline void neigh_confirm(struct neighbour *n) 325{ 326 if (n) { 327 unsigned long now = jiffies; 328 329 /* avoid dirtying neighbour */ 330 if (READ_ONCE(n->confirmed) != now) 331 WRITE_ONCE(n->confirmed, now); 332 } 333} 334 |
|
324void neigh_table_init(int index, struct neigh_table *tbl); 325int neigh_table_clear(int index, struct neigh_table *tbl); 326struct neighbour *neigh_lookup(struct neigh_table *tbl, const void *pkey, 327 struct net_device *dev); 328struct neighbour *neigh_lookup_nodev(struct neigh_table *tbl, struct net *net, 329 const void *pkey); 330struct neighbour *__neigh_create(struct neigh_table *tbl, const void *pkey, 331 struct net_device *dev, bool want_ref); --- 257 unchanged lines hidden --- | 335void neigh_table_init(int index, struct neigh_table *tbl); 336int neigh_table_clear(int index, struct neigh_table *tbl); 337struct neighbour *neigh_lookup(struct neigh_table *tbl, const void *pkey, 338 struct net_device *dev); 339struct neighbour *neigh_lookup_nodev(struct neigh_table *tbl, struct net *net, 340 const void *pkey); 341struct neighbour *__neigh_create(struct neigh_table *tbl, const void *pkey, 342 struct net_device *dev, bool want_ref); --- 257 unchanged lines hidden --- |