netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] vti: remove GRE_KEY flag for vti tunnel
@ 2013-12-04  8:48 Hangbin Liu
  2013-12-04 12:46 ` Christophe Gouault
  0 siblings, 1 reply; 8+ messages in thread
From: Hangbin Liu @ 2013-12-04  8:48 UTC (permalink / raw)
  To: network dev; +Cc: Cong Wang, Saurabh Mohan, Hangbin Liu

vti tunnel use IPPROTO_IPIP instead of IPPROTO_GRE, and keys are not allowed
with ipip tunnel. So there is no reason to set GRE_KEY flag for vti.

Signed-off-by: Hangbin Liu <liuhangbin@gmail.com>
---
 net/ipv4/ip_vti.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/net/ipv4/ip_vti.c b/net/ipv4/ip_vti.c
index 52b802a..58c4e6a 100644
--- a/net/ipv4/ip_vti.c
+++ b/net/ipv4/ip_vti.c
@@ -185,10 +185,8 @@ vti_tunnel_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd)
 	if (err)
 		return err;
 
-	if (cmd != SIOCDELTUNNEL) {
-		p.i_flags |= GRE_KEY | VTI_ISVTI;
-		p.o_flags |= GRE_KEY;
-	}
+	if (cmd != SIOCDELTUNNEL)
+		p.i_flags |= VTI_ISVTI;
 
 	if (copy_to_user(ifr->ifr_ifru.ifru_data, &p, sizeof(p)))
 		return -EFAULT;
-- 
1.8.1.4

^ permalink raw reply related	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2013-12-05 16:15 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-12-04  8:48 [PATCH] vti: remove GRE_KEY flag for vti tunnel Hangbin Liu
2013-12-04 12:46 ` Christophe Gouault
2013-12-05  8:47   ` Steffen Klassert
2013-12-05  9:47     ` Hangbin Liu
2013-12-05 10:51       ` Steffen Klassert
2013-12-05 16:15         ` Hangbin Liu
2013-12-05  9:47   ` Hangbin Liu
2013-12-05 10:58     ` Steffen Klassert

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).