diff options
Diffstat (limited to 'net/ipv4/ip_gre.c')
-rw-r--r-- | net/ipv4/ip_gre.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/net/ipv4/ip_gre.c b/net/ipv4/ip_gre.c index 2b53a1f7abf6..38673d2860e2 100644 --- a/net/ipv4/ip_gre.c +++ b/net/ipv4/ip_gre.c | |||
@@ -65,7 +65,7 @@ | |||
65 | it is infeasible task. The most general solutions would be | 65 | it is infeasible task. The most general solutions would be |
66 | to keep skb->encapsulation counter (sort of local ttl), | 66 | to keep skb->encapsulation counter (sort of local ttl), |
67 | and silently drop packet when it expires. It is a good | 67 | and silently drop packet when it expires. It is a good |
68 | solution, but it supposes maintaing new variable in ALL | 68 | solution, but it supposes maintaining new variable in ALL |
69 | skb, even if no tunneling is used. | 69 | skb, even if no tunneling is used. |
70 | 70 | ||
71 | Current solution: xmit_recursion breaks dead loops. This is a percpu | 71 | Current solution: xmit_recursion breaks dead loops. This is a percpu |
@@ -91,14 +91,14 @@ | |||
91 | 91 | ||
92 | One of them is to parse packet trying to detect inner encapsulation | 92 | One of them is to parse packet trying to detect inner encapsulation |
93 | made by our node. It is difficult or even impossible, especially, | 93 | made by our node. It is difficult or even impossible, especially, |
94 | taking into account fragmentation. TO be short, tt is not solution at all. | 94 | taking into account fragmentation. TO be short, ttl is not solution at all. |
95 | 95 | ||
96 | Current solution: The solution was UNEXPECTEDLY SIMPLE. | 96 | Current solution: The solution was UNEXPECTEDLY SIMPLE. |
97 | We force DF flag on tunnels with preconfigured hop limit, | 97 | We force DF flag on tunnels with preconfigured hop limit, |
98 | that is ALL. :-) Well, it does not remove the problem completely, | 98 | that is ALL. :-) Well, it does not remove the problem completely, |
99 | but exponential growth of network traffic is changed to linear | 99 | but exponential growth of network traffic is changed to linear |
100 | (branches, that exceed pmtu are pruned) and tunnel mtu | 100 | (branches, that exceed pmtu are pruned) and tunnel mtu |
101 | fastly degrades to value <68, where looping stops. | 101 | rapidly degrades to value <68, where looping stops. |
102 | Yes, it is not good if there exists a router in the loop, | 102 | Yes, it is not good if there exists a router in the loop, |
103 | which does not force DF, even when encapsulating packets have DF set. | 103 | which does not force DF, even when encapsulating packets have DF set. |
104 | But it is not our problem! Nobody could accuse us, we made | 104 | But it is not our problem! Nobody could accuse us, we made |
@@ -422,6 +422,10 @@ static struct ip_tunnel *ipgre_tunnel_locate(struct net *net, | |||
422 | if (register_netdevice(dev) < 0) | 422 | if (register_netdevice(dev) < 0) |
423 | goto failed_free; | 423 | goto failed_free; |
424 | 424 | ||
425 | /* Can use a lockless transmit, unless we generate output sequences */ | ||
426 | if (!(nt->parms.o_flags & GRE_SEQ)) | ||
427 | dev->features |= NETIF_F_LLTX; | ||
428 | |||
425 | dev_hold(dev); | 429 | dev_hold(dev); |
426 | ipgre_tunnel_link(ign, nt); | 430 | ipgre_tunnel_link(ign, nt); |
427 | return nt; | 431 | return nt; |
@@ -453,8 +457,8 @@ static void ipgre_err(struct sk_buff *skb, u32 info) | |||
453 | GRE tunnels with enabled checksum. Tell them "thank you". | 457 | GRE tunnels with enabled checksum. Tell them "thank you". |
454 | 458 | ||
455 | Well, I wonder, rfc1812 was written by Cisco employee, | 459 | Well, I wonder, rfc1812 was written by Cisco employee, |
456 | what the hell these idiots break standrads established | 460 | what the hell these idiots break standards established |
457 | by themself??? | 461 | by themselves??? |
458 | */ | 462 | */ |
459 | 463 | ||
460 | const struct iphdr *iph = (const struct iphdr *)skb->data; | 464 | const struct iphdr *iph = (const struct iphdr *)skb->data; |