Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src Separate inet and inet6, allows inet6-only rump kernels.



details:   https://anonhg.NetBSD.org/src/rev/d302b88adbdc
branches:  trunk
changeset: 789313:d302b88adbdc
user:      pooka <pooka%NetBSD.org@localhost>
date:      Wed Aug 14 09:31:41 2013 +0000

description:
Separate inet and inet6, allows inet6-only rump kernels.

diffstat:

 distrib/sets/lists/base/shl.mi             |   5 ++-
 distrib/sets/lists/comp/mi                 |   4 +-
 distrib/sets/lists/comp/shl.mi             |   3 +-
 distrib/sets/lists/debug/mi                |   3 +-
 distrib/sets/lists/debug/shl.mi            |   3 +-
 sys/rump/net/Makefile.rumpnetcomp          |   4 +-
 sys/rump/net/lib/libnet/Makefile           |   3 +-
 sys/rump/net/lib/libnetinet/Makefile.inc   |  12 +-----
 sys/rump/net/lib/libnetinet/component.c    |   7 +--
 sys/rump/net/lib/libnetinet6/Makefile      |   9 +++++
 sys/rump/net/lib/libnetinet6/Makefile.inc  |  15 ++++++++
 sys/rump/net/lib/libnetinet6/component.c   |  52 ++++++++++++++++++++++++++++++
 sys/rump/net/lib/libnetinet6/shlib_version |   4 ++
 13 files changed, 102 insertions(+), 22 deletions(-)

diffs (281 lines):

diff -r 22ba8e153537 -r d302b88adbdc distrib/sets/lists/base/shl.mi
--- a/distrib/sets/lists/base/shl.mi    Wed Aug 14 09:20:55 2013 +0000
+++ b/distrib/sets/lists/base/shl.mi    Wed Aug 14 09:31:41 2013 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: shl.mi,v 1.670 2013/08/11 22:29:02 joerg Exp $
+# $NetBSD: shl.mi,v 1.671 2013/08/14 09:31:41 pooka Exp $
 #
 # Note:        Don't delete entries from here - mark them as "obsolete" instead,
 #      unless otherwise stated below.
@@ -663,6 +663,9 @@
 ./usr/lib/librumpnet_netinet.so                        base-rump-shlib rump
 ./usr/lib/librumpnet_netinet.so.0              base-rump-shlib rump
 ./usr/lib/librumpnet_netinet.so.0.0            base-rump-shlib rump
+./usr/lib/librumpnet_netinet6.so                       base-rump-shlib rump
+./usr/lib/librumpnet_netinet6.so.0             base-rump-shlib rump
+./usr/lib/librumpnet_netinet6.so.0.0           base-rump-shlib rump
 ./usr/lib/librumpnet_netmpls.so                        base-rump-shlib rump
 ./usr/lib/librumpnet_netmpls.so.0              base-rump-shlib rump
 ./usr/lib/librumpnet_netmpls.so.0.0            base-rump-shlib rump
diff -r 22ba8e153537 -r d302b88adbdc distrib/sets/lists/comp/mi
--- a/distrib/sets/lists/comp/mi        Wed Aug 14 09:20:55 2013 +0000
+++ b/distrib/sets/lists/comp/mi        Wed Aug 14 09:31:41 2013 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: mi,v 1.1831 2013/08/11 22:29:02 joerg Exp $
+#      $NetBSD: mi,v 1.1832 2013/08/14 09:31:41 pooka Exp $
 #
 # Note: don't delete entries from here - mark them as "obsolete" instead.
 #
@@ -3235,6 +3235,8 @@
 ./usr/lib/librumpnet_netbt_p.a                 comp-c-proflib          profile,rump
 ./usr/lib/librumpnet_netinet.a                 comp-c-lib              rump
 ./usr/lib/librumpnet_netinet_p.a               comp-c-proflib          profile,rump
+./usr/lib/librumpnet_netinet6.a                        comp-c-lib              rump
+./usr/lib/librumpnet_netinet6_p.a              comp-c-proflib          profile,rump
 ./usr/lib/librumpnet_netmpls.a                 comp-c-lib              rump
 ./usr/lib/librumpnet_netmpls_p.a               comp-c-proflib          profile,rump
 ./usr/lib/librumpnet_npf.a                     comp-c-lib              rump
diff -r 22ba8e153537 -r d302b88adbdc distrib/sets/lists/comp/shl.mi
--- a/distrib/sets/lists/comp/shl.mi    Wed Aug 14 09:20:55 2013 +0000
+++ b/distrib/sets/lists/comp/shl.mi    Wed Aug 14 09:31:41 2013 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: shl.mi,v 1.252 2013/08/11 22:29:02 joerg Exp $
+# $NetBSD: shl.mi,v 1.253 2013/08/14 09:31:41 pooka Exp $
 #
 # Note: don't delete entries from here - mark them as "obsolete" instead.
 #
@@ -203,6 +203,7 @@
 ./usr/lib/librumpnet_net_pic.a                 comp-c-piclib           rump
 ./usr/lib/librumpnet_netbt_pic.a               comp-c-piclib           rump
 ./usr/lib/librumpnet_netinet_pic.a             comp-c-piclib           rump
+./usr/lib/librumpnet_netinet6_pic.a            comp-c-piclib           rump
 ./usr/lib/librumpnet_netmpls_pic.a             comp-c-piclib           rump
 ./usr/lib/librumpnet_npf_pic.a                 comp-c-piclib           rump
 ./usr/lib/librumpnet_pic.a                     comp-c-piclib           rump
diff -r 22ba8e153537 -r d302b88adbdc distrib/sets/lists/debug/mi
--- a/distrib/sets/lists/debug/mi       Wed Aug 14 09:20:55 2013 +0000
+++ b/distrib/sets/lists/debug/mi       Wed Aug 14 09:31:41 2013 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: mi,v 1.29 2013/08/11 22:29:02 joerg Exp $
+# $NetBSD: mi,v 1.30 2013/08/14 09:31:41 pooka Exp $
 
 ./etc/mtree/set.debug                           comp-sys-root
 ./usr/lib/i18n/libBIG5_g.a                     -unknown-               debuglib
@@ -199,6 +199,7 @@
 ./usr/lib/librumpnet_net_g.a                   -unknown-               debuglib,rump
 ./usr/lib/librumpnet_netbt_g.a                 -unknown-               debuglib,rump
 ./usr/lib/librumpnet_netinet_g.a               -unknown-               debuglib,rump
+./usr/lib/librumpnet_netinet6_g.a              -unknown-               debuglib,rump
 ./usr/lib/librumpnet_npf_g.a                   -unknown-               debuglib,rump
 ./usr/lib/librumpnet_shmif_g.a                 -unknown-               debuglib,rump
 ./usr/lib/librumpnet_sockin_g.a                        -unknown-               debuglib,rump
diff -r 22ba8e153537 -r d302b88adbdc distrib/sets/lists/debug/shl.mi
--- a/distrib/sets/lists/debug/shl.mi   Wed Aug 14 09:20:55 2013 +0000
+++ b/distrib/sets/lists/debug/shl.mi   Wed Aug 14 09:31:41 2013 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: shl.mi,v 1.30 2013/08/11 22:29:03 joerg Exp $
+# $NetBSD: shl.mi,v 1.31 2013/08/14 09:31:41 pooka Exp $
 ./usr/libdata/debug/lib/libc.so.12.185.debug           comp-sys-debug  debug
 ./usr/libdata/debug/lib/libcrypt.so.1.0.debug          comp-sys-debug  debug
 ./usr/libdata/debug/lib/libcrypto.so.8.1.debug         comp-sys-debug  debug
@@ -219,6 +219,7 @@
 ./usr/libdata/debug/usr/lib/librumpnet_net80211.so.0.0.debug   comp-rump-debug debug,rump
 ./usr/libdata/debug/usr/lib/librumpnet_netbt.so.0.0.debug      comp-rump-debug debug,rump
 ./usr/libdata/debug/usr/lib/librumpnet_netinet.so.0.0.debug    comp-rump-debug debug,rump
+./usr/libdata/debug/usr/lib/librumpnet_netinet6.so.0.0.debug   comp-rump-debug debug,rump
 ./usr/libdata/debug/usr/lib/librumpnet_netmpls.so.0.0.debug    comp-rump-debug debug,rump
 ./usr/libdata/debug/usr/lib/librumpnet_npf.so.0.0.debug                comp-rump-debug npf,debug,rump
 ./usr/libdata/debug/usr/lib/librumpnet_shmif.so.0.0.debug      comp-rump-debug debug,rump
diff -r 22ba8e153537 -r d302b88adbdc sys/rump/net/Makefile.rumpnetcomp
--- a/sys/rump/net/Makefile.rumpnetcomp Wed Aug 14 09:20:55 2013 +0000
+++ b/sys/rump/net/Makefile.rumpnetcomp Wed Aug 14 09:31:41 2013 +0000
@@ -1,9 +1,9 @@
-#      $NetBSD: Makefile.rumpnetcomp,v 1.7 2013/08/01 13:11:22 pooka Exp $
+#      $NetBSD: Makefile.rumpnetcomp,v 1.8 2013/08/14 09:31:41 pooka Exp $
 #
 
 .include <bsd.own.mk>
 
-RUMPNETCOMP=   agr bridge net net80211 netbt netinet netmpls npf
+RUMPNETCOMP=   agr bridge net net80211 netbt netinet netinet6 netmpls npf
 RUMPNETCOMP+=  local shmif
 
 .if ${RUMP_VIRTIF:Uyes} == "yes"
diff -r 22ba8e153537 -r d302b88adbdc sys/rump/net/lib/libnet/Makefile
--- a/sys/rump/net/lib/libnet/Makefile  Wed Aug 14 09:20:55 2013 +0000
+++ b/sys/rump/net/lib/libnet/Makefile  Wed Aug 14 09:31:41 2013 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: Makefile,v 1.18 2013/07/18 15:59:28 kefren Exp $
+#      $NetBSD: Makefile,v 1.19 2013/08/14 09:31:42 pooka Exp $
 #
 
 .PATH: ${.CURDIR}/../../../../net ${.CURDIR}/../../../../compat/common
@@ -15,6 +15,7 @@
 CPPFLAGS+=     -DCOMPAT_OIFREQ -DCOMPAT_OIFDATA
 
 .include "${.CURDIR}/../libnetinet/Makefile.inc"
+.include "${.CURDIR}/../libnetinet6/Makefile.inc"
 .include "${.CURDIR}/../libnetmpls/Makefile.inc"
 
 .include <bsd.lib.mk>
diff -r 22ba8e153537 -r d302b88adbdc sys/rump/net/lib/libnetinet/Makefile.inc
--- a/sys/rump/net/lib/libnetinet/Makefile.inc  Wed Aug 14 09:20:55 2013 +0000
+++ b/sys/rump/net/lib/libnetinet/Makefile.inc  Wed Aug 14 09:31:41 2013 +0000
@@ -1,20 +1,13 @@
-#      $NetBSD: Makefile.inc,v 1.10 2013/06/01 11:02:42 pooka Exp $
+#      $NetBSD: Makefile.inc,v 1.11 2013/08/14 09:31:42 pooka Exp $
 #
 
-.PATH: ${.CURDIR}/../../../../netinet ${.CURDIR}/../../../../netinet6
+.PATH: ${.CURDIR}/../../../../netinet
 
 # INET
 SRCS+= in_proto.c igmp.c in.c in_offload.c in_pcb.c ip_carp.c ip_icmp.c\
        ip_flow.c ip_id.c ip_input.c ip_reass.c ip_output.c raw_ip.c    \
        in_cksum.c cpu_in_cksum.c in4_cksum.c ip_encap.c portalgo.c
 
-# INET6
-SRCS+= dest6.c frag6.c icmp6.c in6.c in6_cksum.c in6_ifattach.c        \
-       in6_offload.c in6_pcb.c in6_proto.c in6_src.c ip6_flow.c        \
-       ip6_forward.c ip6_id.c ip6_input.c ip6_mroute.c ip6_output.c    \
-       mld6.c nd6.c nd6_nbr.c nd6_rtr.c raw_ip6.c route6.c scope6.c    \
-       udp6_output.c udp6_usrreq.c
-
 # ARP
 SRCS+= if_arp.c
 
@@ -28,7 +21,6 @@
 CPPFLAGS+=     -I${.CURDIR}/opt -I${.CURDIR}/../libnet/opt
 
 CPPFLAGS+=     -DPORTALGO_INET4_DEFAULT=PORTALGO_RANDOM_START
-CPPFLAGS+=     -DPORTALGO_INET6_DEFAULT=PORTALGO_RANDOM_START
 
 # TCP debugging
 #SRCS+=                tcp_debug.c
diff -r 22ba8e153537 -r d302b88adbdc sys/rump/net/lib/libnetinet/component.c
--- a/sys/rump/net/lib/libnetinet/component.c   Wed Aug 14 09:20:55 2013 +0000
+++ b/sys/rump/net/lib/libnetinet/component.c   Wed Aug 14 09:31:41 2013 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: component.c,v 1.6 2013/06/30 16:04:36 pooka Exp $      */
+/*     $NetBSD: component.c,v 1.7 2013/08/14 09:31:42 pooka Exp $      */
 
 /*
  * Copyright (c) 2009 Antti Kantee.  All Rights Reserved.
@@ -28,7 +28,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: component.c,v 1.6 2013/06/30 16:04:36 pooka Exp $");
+__KERNEL_RCSID(0, "$NetBSD: component.c,v 1.7 2013/08/14 09:31:42 pooka Exp $");
 
 #include <sys/param.h>
 #include <sys/domain.h>
@@ -46,11 +46,10 @@
 
 RUMP_COMPONENT(RUMP_COMPONENT_NET)
 {
-       extern struct domain arpdomain, inetdomain, inet6domain;
+       extern struct domain arpdomain, inetdomain;
 
        DOMAINADD(arpdomain);
        DOMAINADD(inetdomain);
-       DOMAINADD(inet6domain);
 
        carpattach(1);
 }
diff -r 22ba8e153537 -r d302b88adbdc sys/rump/net/lib/libnetinet6/Makefile
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/sys/rump/net/lib/libnetinet6/Makefile     Wed Aug 14 09:31:41 2013 +0000
@@ -0,0 +1,9 @@
+#      $NetBSD: Makefile,v 1.1 2013/08/14 09:31:42 pooka Exp $
+#
+
+LIB=   rumpnet_netinet6
+
+SRCS=  component.c
+
+.include <bsd.lib.mk>
+.include <bsd.klinks.mk>
diff -r 22ba8e153537 -r d302b88adbdc sys/rump/net/lib/libnetinet6/Makefile.inc
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/sys/rump/net/lib/libnetinet6/Makefile.inc Wed Aug 14 09:31:41 2013 +0000
@@ -0,0 +1,15 @@
+#      $NetBSD: Makefile.inc,v 1.1 2013/08/14 09:31:42 pooka Exp $
+#
+
+.PATH: ${.CURDIR}/../../../../netinet6
+
+# INET6
+SRCS+= dest6.c frag6.c icmp6.c in6.c in6_cksum.c in6_ifattach.c        \
+       in6_offload.c in6_pcb.c in6_proto.c in6_src.c ip6_flow.c        \
+       ip6_forward.c ip6_id.c ip6_input.c ip6_mroute.c ip6_output.c    \
+       mld6.c nd6.c nd6_nbr.c nd6_rtr.c raw_ip6.c route6.c scope6.c    \
+       udp6_output.c udp6_usrreq.c
+
+CPPFLAGS+=     -I${.CURDIR}/opt -I${.CURDIR}/../libnet/opt
+
+CPPFLAGS+=     -DPORTALGO_INET6_DEFAULT=PORTALGO_RANDOM_START
diff -r 22ba8e153537 -r d302b88adbdc sys/rump/net/lib/libnetinet6/component.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/sys/rump/net/lib/libnetinet6/component.c  Wed Aug 14 09:31:41 2013 +0000
@@ -0,0 +1,52 @@
+/*     $NetBSD: component.c,v 1.1 2013/08/14 09:31:42 pooka Exp $      */
+
+/*
+ * Copyright (c) 2013 Antti Kantee.  All Rights Reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS
+ * OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+ * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+
+#include <sys/cdefs.h>
+__KERNEL_RCSID(0, "$NetBSD: component.c,v 1.1 2013/08/14 09:31:42 pooka Exp $");
+
+#include <sys/param.h>
+#include <sys/domain.h>
+#include <sys/protosw.h>
+#include <sys/socketvar.h>
+
+#include <net/if.h>
+
+#include "rump_private.h"
+#include "rump_net_private.h"
+
+RUMP_COMPONENT(RUMP_COMPONENT_NET)
+{
+       extern struct domain inet6domain;
+
+       DOMAINADD(inet6domain);
+}
+
+RUMP_COMPONENT(RUMP_COMPONENT_NET_IFCFG)
+{
+
+       if_up(lo0ifp);
+}
diff -r 22ba8e153537 -r d302b88adbdc sys/rump/net/lib/libnetinet6/shlib_version
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/sys/rump/net/lib/libnetinet6/shlib_version        Wed Aug 14 09:31:41 2013 +0000
@@ -0,0 +1,4 @@
+#      $NetBSD: shlib_version,v 1.1 2013/08/14 09:31:42 pooka Exp $
+#
+major=0
+minor=0



Home | Main Index | Thread Index | Old Index