aboutsummaryrefslogtreecommitdiffstats
path: root/include/net/inetpeer.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/net/inetpeer.h')
-rw-r--r--include/net/inetpeer.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/net/inetpeer.h b/include/net/inetpeer.h
index 2af0c63d3975..61f2c66edb2a 100644
--- a/include/net/inetpeer.h
+++ b/include/net/inetpeer.h
@@ -51,6 +51,13 @@ struct inet_peer {
51 51
52void inet_initpeers(void) __init; 52void inet_initpeers(void) __init;
53 53
54#define INETPEER_METRICS_NEW (~(u32) 0)
55
56static inline bool inet_metrics_new(const struct inet_peer *p)
57{
58 return p->metrics[RTAX_LOCK-1] == INETPEER_METRICS_NEW;
59}
60
54/* can be called with or without local BH being disabled */ 61/* can be called with or without local BH being disabled */
55struct inet_peer *inet_getpeer(struct inetpeer_addr *daddr, int create); 62struct inet_peer *inet_getpeer(struct inetpeer_addr *daddr, int create);
56 63