From: David S. Miller <davem@davemloft.net>
Date: Tue, 24 May 2011 05:11:51 +0000 (-0400)
Subject: ipv6: Fix return of xfrm6_tunnel_rcv()
X-Git-Tag: firefly_0821_release~7613^2~967^2~53
X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=6ac3f6649223d916bbdf1e823926f8f3b34b5d99;p=firefly-linux-kernel-4.4.55.git

ipv6: Fix return of xfrm6_tunnel_rcv()

Like ipv4, just return xfrm6_rcv_spi()'s return value directly.

Signed-off-by: David S. Miller <davem@davemloft.net>
---

diff --git a/net/ipv6/xfrm6_tunnel.c b/net/ipv6/xfrm6_tunnel.c
index a6770a04e3bd..4fe1db12d2a3 100644
--- a/net/ipv6/xfrm6_tunnel.c
+++ b/net/ipv6/xfrm6_tunnel.c
@@ -241,7 +241,7 @@ static int xfrm6_tunnel_rcv(struct sk_buff *skb)
 	__be32 spi;
 
 	spi = xfrm6_tunnel_spi_lookup(net, (const xfrm_address_t *)&iph->saddr);
-	return xfrm6_rcv_spi(skb, IPPROTO_IPV6, spi) > 0 ? : 0;
+	return xfrm6_rcv_spi(skb, IPPROTO_IPV6, spi);
 }
 
 static int xfrm6_tunnel_err(struct sk_buff *skb, struct inet6_skb_parm *opt,