@@ -1074,7 +1074,18 @@ void ip6_protocol_deliver_rcu(struct net *net, struct sk_buff *skb, int nexthdr,
bool have_final);
int __ip6_local_out(struct net *net, struct sock *sk, struct sk_buff *skb);
-int ip6_local_out(struct net *net, struct sock *sk, struct sk_buff *skb);
+
+static inline int ip6_local_out(struct net *net, struct sock *sk,
+ struct sk_buff *skb)
+{
+ int err;
+
+ err = __ip6_local_out(net, sk, skb);
+ if (likely(err == 1))
+ err = dst_output(net, sk, skb);
+
+ return err;
+}
/*
* Extension header (options) processing
@@ -151,15 +151,3 @@ int __ip6_local_out(struct net *net, struct sock *sk, struct sk_buff *skb)
dst_output);
}
EXPORT_SYMBOL_GPL(__ip6_local_out);
-
-int ip6_local_out(struct net *net, struct sock *sk, struct sk_buff *skb)
-{
- int err;
-
- err = __ip6_local_out(net, sk, skb);
- if (likely(err == 1))
- err = dst_output(net, sk, skb);
-
- return err;
-}
-EXPORT_SYMBOL_GPL(ip6_local_out);
ip6_local_out() is simple, inline it. Signed-off-by: Pavel Begunkov <asml.silence@gmail.com> --- include/net/ipv6.h | 13 ++++++++++++- net/ipv6/output_core.c | 12 ------------ 2 files changed, 12 insertions(+), 13 deletions(-)