From owner-freebsd-net@FreeBSD.ORG Tue Sep 4 20:57:49 2007 Return-Path: Delivered-To: net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C171416A468; Tue, 4 Sep 2007 20:57:49 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.freebsd.org (Postfix) with ESMTP id AEF1413C45E; Tue, 4 Sep 2007 20:57:49 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: by elvis.mu.org (Postfix, from userid 1192) id 0E3D91A4D9B; Tue, 4 Sep 2007 13:54:54 -0700 (PDT) Date: Tue, 4 Sep 2007 13:54:54 -0700 From: Alfred Perlstein To: Randall Stewart Message-ID: <20070904205454.GY87451@elvis.mu.org> References: <20070821232956.GT87451@elvis.mu.org> <46CC45F0.3000105@FreeBSD.org> <20070902211945.GQ87451@elvis.mu.org> <46DC1E51.3040707@FreeBSD.org> <20070903201133.GU87451@elvis.mu.org> <46DD2F3A.20904@FreeBSD.org> <20070904124224.GF87451@elvis.mu.org> <46DDB9E9.4010408@cisco.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <46DDB9E9.4010408@cisco.com> User-Agent: Mutt/1.4.2.3i Cc: Max Laier , "Bruce M. Simpson" , net@freebsd.org Subject: Re: Allocating AF constants for vendors. 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: Tue, 04 Sep 2007 20:57:49 -0000 * Randall Stewart [070904 13:22] wrote: > Alfred Perlstein wrote: > >* Bruce M. Simpson [070904 03:08] wrote: > > > >>>As you can see we are defering the "bloat". > >>>Does that make sense? > >>> > >> > >>I follow but it still doesn't really make sense. > >> > >>Granted, you are deferring the growth of arrays sized off AF_MAX but > >>only ever by 1 slot. > >>What if Vendor Z wants to add 25 entries at once? > > > > > >Then as long as they allocate odd numbered entries they should > >be fine. FreeBSD's AF_MAX does not need to change to accomidate > >a vendor, it only has to restrict itself to even numbered slots. > > > > > >>We would also be tying ourselves down to the notion of a vendor in any > >>AF_ allocation. Is this an avenue that people are happy to pursue? > > > > > >Yes, until the "horrific" problem of the statically sized arrays > >is "fixed". Then the allocation policy can change. > > > > > So basically in this scheme we only have to "stumble" across an > additional slot when we add a new one to FreeBSD.. i.e. some > random vendor may assign 50 slots (in odd numbers) but FreeBSD > would not see the growth until really 2 new AF_XXX's are added. > Then you would have to bump it from by 3, to cover the two > new ones (reserving the vendor specific slots and thus causing > allocations of unused things). YES! Exactly. > > This seems like a reasonable compromise to me... I can't imagine > where we would need to add a lont of new AF_XXX's.. of course > maybe I just lack imagination :-D Well, Freebsd or 5 added bluetooth, and freebsd 7 has some IEEE thing added... sooo... the array is growing, but slowly. -- - Alfred Perlstein