summaryrefslogtreecommitdiffstats
path: root/net/ipv4/gre_offload.c
diff options
context:
space:
mode:
authorEric Dumazet <edumazet@google.com>2014-01-06 14:03:07 -0800
committerDavid S. Miller <davem@davemloft.net>2014-01-06 20:28:34 -0500
commit438e38fadca2f6e57eeecc08326c8a95758594d4 (patch)
tree8c71bf332c0827545b2ece7471c09a4489cba5dc /net/ipv4/gre_offload.c
parent0e5959346cb859851e99ed87bd07f76ed5bb3a37 (diff)
gre_offload: statically build GRE offloading support
GRO/GSO layers can be enabled on a node, even if said node is only forwarding packets. This patch permits GSO (and upcoming GRO) support for GRE encapsulated packets, even if the host has no GRE tunnel setup. Signed-off-by: Eric Dumazet <edumazet@google.com> Cc: H.K. Jerry Chu <hkchu@google.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/gre_offload.c')
-rw-r--r--net/ipv4/gre_offload.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/net/ipv4/gre_offload.c b/net/ipv4/gre_offload.c
index 2cd02f32f99..9138cfb1014 100644
--- a/net/ipv4/gre_offload.c
+++ b/net/ipv4/gre_offload.c
@@ -123,12 +123,15 @@ static const struct net_offload gre_offload = {
},
};
-int __init gre_offload_init(void)
+static int __init gre_offload_init(void)
{
return inet_add_offload(&gre_offload, IPPROTO_GRE);
}
-void __exit gre_offload_exit(void)
+static void __exit gre_offload_exit(void)
{
inet_del_offload(&gre_offload, IPPROTO_GRE);
}
+
+module_init(gre_offload_init);
+module_exit(gre_offload_exit);