From owner-freebsd-net@FreeBSD.ORG Fri Sep 21 09:15:01 2012 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id ED5EA106566C for ; Fri, 21 Sep 2012 09:15:00 +0000 (UTC) (envelope-from anshukla@juniper.net) Received: from exprod7og102.obsmtp.com (exprod7og102.obsmtp.com [64.18.2.157]) by mx1.freebsd.org (Postfix) with ESMTP id 831ED8FC0C for ; Fri, 21 Sep 2012 09:15:00 +0000 (UTC) Received: from P-EMHUB02-HQ.jnpr.net ([66.129.224.36]) (using TLSv1) by exprod7ob102.postini.com ([64.18.6.12]) with SMTP ID DSNKUFwwB8s5lxDsNJ8yku6hx5iW1+wjK/Zz@postini.com; Fri, 21 Sep 2012 02:15:00 PDT Received: from EMBX02-HQ.jnpr.net ([fe80::18fe:d666:b43e:f97e]) by P-EMHUB02-HQ.jnpr.net ([fe80::88f9:77fd:dfc:4d51%11]) with mapi; Fri, 21 Sep 2012 02:12:50 -0700 From: Anuranjan Shukla To: George Neville-Neil Date: Fri, 21 Sep 2012 02:12:47 -0700 Thread-Topic: Proposal for changes to network device drivers and network stack (RFC) Thread-Index: Ac2X2UV16qmg6bzeRjWvEbm5INbL3Q== Message-ID: In-Reply-To: <5F3C03B6-01D0-42DE-BE9E-323DBDC90C8E@neville-neil.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: user-agent: Microsoft-MacOutlook/14.2.3.120616 acceptlanguage: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Cc: "freebsd-net@freebsd.org" Subject: Re: Proposal for changes to network device drivers and network stack (RFC) X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 21 Sep 2012 09:15:01 -0000 Hi George, On 9/5/12 1:15 PM, "George Neville-Neil" wrote: > >> Building FreeBSD without the network stack (network stack as a module) >> ---------------------------------------------------------------------- >> Today, not compiling networking stack related files in the kernel breaks >> the kernel build due to dependencies the OS has on the network stack >> (calling into functions in the network stack). Network stack module >>isn't >> there. We've added these in JUNOS. The benefits for us are obvious (we >>can >> load our own version of network stack if we desire!), but most likely >>this >> functionality will benefit others too. >>=20 >> The detailed implementation is indicated later in this email. In short >>the >> changes are: >>=20 >> - Load network stack as a module. For now via loader, not dynamically >> loaded. (Is there interest in dynamic loading?). >> - To facilitate calling network stack functionality from the generic >> kernel, a new interface has been defined with the kobj framework. >> - Some files and tunables needed to move to generic kernel areas (accept >> filters) >> - Generic socket code calls into network stack for interface and route >> related ioctls. Network stack now registers these ioctl groups >> - Other changes: uuid generation (register/query uuid sources), fib/sctp >> system calls (moved to network stack code, with system calls register >> dynamically). >>=20 > >This would be interesting for many reasons, and I think it would be a good >contribution. Does the work you've done in this area handle the VNET >stuff that is in the stack as well? That is, how well does the network >stack >as a module play with the vnet architecture? Full VNET friendliness is expected by the time we finalize this work. In the diff provided, vnet support (vent.c) is already made optional additionally for netstack option. We plan to validate these changes with VIMAGE. We should have the broken down diffs by next week. Thanks for your input.