]> Pileus Git - ~andy/linux/commitdiff
openvswitch: Add Kconfig dependency on GRE-DEMUX.
authorPravin B Shelar <pshelar@nicira.com>
Fri, 28 Jun 2013 23:07:40 +0000 (16:07 -0700)
committerDavid S. Miller <davem@davemloft.net>
Mon, 1 Jul 2013 20:19:43 +0000 (13:19 -0700)
Openvswitch uses function from NET_IPGRE_DEMUX module.
Add Kconfig dependency to fix following compilation errors:
http://marc.info/?l=linux-netdev&m=137244035226634

CC: Jesse Gross <jesse@nicira.com>
Reported-by: Randy Dunlap <rdunlap@infradead.org>
Signed-off-by: Pravin Shelar <pshelar@nicira.com>
Acked-by: Randy Dunlap <rdunlap@infradead.org>
Acked-by: Jesse Gross <jesse@nicira.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/openvswitch/Kconfig
net/openvswitch/vport-gre.c
net/openvswitch/vport.c

index 9fbc04a31ed6d10e8c8a5e12e3401bcc0fd25f16..27ee56b688a39eea9650f1dd0b434a3c42aa515b 100644 (file)
@@ -19,8 +19,6 @@ config OPENVSWITCH
          which is able to accept configuration from a variety of sources and
          translate it into packet processing rules.
 
-         Open vSwitch GRE support depends on CONFIG_NET_IPGRE_DEMUX.
-
          See http://openvswitch.org for more information and userspace
          utilities.
 
@@ -28,3 +26,17 @@ config OPENVSWITCH
          called openvswitch.
 
          If unsure, say N.
+
+config OPENVSWITCH_GRE
+       bool "Open vSwitch GRE tunneling support"
+       depends on INET
+       depends on OPENVSWITCH
+       depends on NET_IPGRE_DEMUX && !(OPENVSWITCH=y && NET_IPGRE_DEMUX=m)
+       default y
+       ---help---
+         If you say Y here, then the Open vSwitch will be able create GRE
+         vport.
+
+         Say N to exclude this support and reduce the binary size.
+
+         If unsure, say Y.
index 943e5c4313543240c987f4168fdd6ca1bf2dd1c5..493e9775dcdadb90ea383a26403d8bd11fc6face 100644 (file)
@@ -16,7 +16,7 @@
  * 02110-1301, USA
  */
 
-#if IS_ENABLED(CONFIG_NET_IPGRE_DEMUX)
+#ifdef CONFIG_OPENVSWITCH_GRE
 #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
 
 #include <linux/if.h>
@@ -271,4 +271,5 @@ const struct vport_ops ovs_gre_vport_ops = {
        .get_name       = gre_get_name,
        .send           = gre_tnl_send,
 };
-#endif
+
+#endif /* OPENVSWITCH_GRE */
index ba81294219ac887fab0fb337b084a304f961fe32..d4c7fa04ce08c2a148c01488d518776c4fcbb066 100644 (file)
@@ -39,7 +39,7 @@ static const struct vport_ops *vport_ops_list[] = {
        &ovs_netdev_vport_ops,
        &ovs_internal_vport_ops,
 
-#if IS_ENABLED(CONFIG_NET_IPGRE_DEMUX)
+#ifdef CONFIG_OPENVSWITCH_GRE
        &ovs_gre_vport_ops,
 #endif
 };