summaryrefslogtreecommitdiff
path: root/include/net/route.h
diff options
context:
space:
mode:
authorDavid Ahern <dsahern@gmail.com>2017-05-25 10:42:34 -0700
committerDavid S. Miller <davem@davemloft.net>2017-05-26 14:12:49 -0400
commit5510cdf7be042a1943222e19912f13a396c0b914 (patch)
tree4ad5b4a3628ef631a26d740eda811e74b830931f /include/net/route.h
parent3abd1ade6765e8edcccad6a9e1039cc709e65dde (diff)
net: ipv4: refactor ip_route_input_noref
A later patch wants access to the fib result on an input route lookup with the rcu lock held. Refactor ip_route_input_noref pushing the logic between rcu_read_lock ... rcu_read_unlock into a new helper that takes the fib_result as an input arg. Signed-off-by: David Ahern <dsahern@gmail.com> Signed-off-by: Roopa Prabhu <roopa@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net/route.h')
-rw-r--r--include/net/route.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/net/route.h b/include/net/route.h
index 89e4028cd063..08e689f23365 100644
--- a/include/net/route.h
+++ b/include/net/route.h
@@ -178,6 +178,9 @@ static inline struct rtable *ip_route_output_gre(struct net *net, struct flowi4
int ip_route_input_noref(struct sk_buff *skb, __be32 dst, __be32 src,
u8 tos, struct net_device *devin);
+int ip_route_input_rcu(struct sk_buff *skb, __be32 dst, __be32 src,
+ u8 tos, struct net_device *devin,
+ struct fib_result *res);
static inline int ip_route_input(struct sk_buff *skb, __be32 dst, __be32 src,
u8 tos, struct net_device *devin)