Patchwork openvswitch: Make IPv6 packet parsing dependent on IPv6 config

login
register
mail settings
Submitter Vlad Yasevich
Date Nov. 16, 2012, 7:41 p.m.
Message ID <1353094881-28867-1-git-send-email-vyasevic@redhat.com>
Download mbox | patch
Permalink /patch/199720/
State Accepted
Delegated to: David Miller
Headers show

Comments

Vlad Yasevich - Nov. 16, 2012, 7:41 p.m.
On 11/16/2012 01:53 PM, David Miller wrote:> From: Jesse Gross <jesse@nicira.com>
> Date: Fri, 16 Nov 2012 10:46:17 -0800
> 
>> I guess the simplest thing to do seems to just make Open vSwitch
>> depend on CONFIG_INET seeing as it is practically useless without
>> upper layer protocol support anyways.
> 
> The reason we have the ipv6 extension header parsing in a seperate,
> always compiled statically into the kernel, module is exactly for
> situations like this.
> 
> We need to think seriously if we want to go down this road of only
> using INET as protection for every module that has some kind of ipv6
> component to it.

Ok.  How about this approach instead.  This keeps core functions we need
still dependent on CONFIG_NET and makes new GSO stuff depend on CONFIG_INET
since its quite useless without CONFIG_INET anyway...

-vlad

-- >8 --

Subject: [PATCH] ipv6: Preserve ipv6 functionality needed by NET

Some pieces of network use core pieces of IPv6 stack.  Keep
them available while letting new GSO offload pieces depend
on CONFIG_INET.

Signed-off-by: Vlad Yasevich <vyasevic@redhat.com>
---
 net/Makefile      |    2 +-
 net/ipv6/Makefile |    4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)
David Miller - Nov. 18, 2012, 7:34 a.m.
From: Vlad Yasevich <vyasevic@redhat.com>
Date: Fri, 16 Nov 2012 14:41:21 -0500

> Ok.  How about this approach instead.  This keeps core functions we need
> still dependent on CONFIG_NET and makes new GSO stuff depend on CONFIG_INET
> since its quite useless without CONFIG_INET anyway...
 ...
> Subject: [PATCH] ipv6: Preserve ipv6 functionality needed by NET
> 
> Some pieces of network use core pieces of IPv6 stack.  Keep
> them available while letting new GSO offload pieces depend
> on CONFIG_INET.
> 
> Signed-off-by: Vlad Yasevich <vyasevic@redhat.com>

Looks good, applied, thanks Vlad.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Patch

diff --git a/net/Makefile b/net/Makefile
index e050d9d..4f4ee08 100644
--- a/net/Makefile
+++ b/net/Makefile
@@ -19,7 +19,7 @@  obj-$(CONFIG_NETFILTER)		+= netfilter/
 obj-$(CONFIG_INET)		+= ipv4/
 obj-$(CONFIG_XFRM)		+= xfrm/
 obj-$(CONFIG_UNIX)		+= unix/
-obj-$(CONFIG_INET)		+= ipv6/
+obj-$(CONFIG_NET)		+= ipv6/
 obj-$(CONFIG_PACKET)		+= packet/
 obj-$(CONFIG_NET_KEY)		+= key/
 obj-$(CONFIG_BRIDGE)		+= bridge/
diff --git a/net/ipv6/Makefile b/net/ipv6/Makefile
index 04a475d..2068ac4 100644
--- a/net/ipv6/Makefile
+++ b/net/ipv6/Makefile
@@ -40,7 +40,7 @@  obj-$(CONFIG_IPV6_SIT) += sit.o
 obj-$(CONFIG_IPV6_TUNNEL) += ip6_tunnel.o
 obj-$(CONFIG_IPV6_GRE) += ip6_gre.o
 
-obj-y += addrconf_core.o exthdrs_core.o output_core.o protocol.o
-obj-y += $(ipv6-offload)
+obj-y += addrconf_core.o exthdrs_core.o
+obj-$(CONFIG_INET) += output_core.o protocol.o $(ipv6_offload)
 
 obj-$(subst m,y,$(CONFIG_IPV6)) += inet6_hashtables.o