From owner-freebsd-arch Wed Feb 7 10:44:48 2001 Delivered-To: freebsd-arch@freebsd.org Received: from syncopation-03.iinet.net.au (syncopation-03.iinet.net.au [203.59.24.49]) by hub.freebsd.org (Postfix) with SMTP id 0549C37B491 for ; Wed, 7 Feb 2001 10:44:30 -0800 (PST) Received: (qmail 20921 invoked by uid 666); 7 Feb 2001 18:52:00 -0000 Received: from reggae-22-100.nv.iinet.net.au (HELO elischer.org) (203.59.87.100) by mail.m.iinet.net.au with SMTP; 7 Feb 2001 18:52:00 -0000 Message-ID: <3A819788.DA35F78C@elischer.org> Date: Wed, 07 Feb 2001 10:44:24 -0800 From: Julian Elischer X-Mailer: Mozilla 4.7 [en] (X11; U; FreeBSD 5.0-CURRENT i386) X-Accept-Language: en, hu MIME-Version: 1.0 To: Poul-Henning Kamp Cc: "Brian F. Feldman" , arch@FreeBSD.ORG Subject: Re: xucred introduction References: <2711.981570785@critter> Content-Type: text/plain; charset=iso-8859-15 Content-Transfer-Encoding: 7bit Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Poul-Henning Kamp wrote: > > In message <200102071828.f17ISLr17637@green.dyndns.org>, "Brian F. Feldman" wri > tes: > > >The only question is whether or not to add some spare fields to > >xucred now in case we /do/ want to expand it in the future, and also whether > >it's appropriate to make some of the field type changes (for example, > >sockaddr length type -> u_char, since that _IS_ what is defined by the > >sockaddr interface). > > Have you already put a version number in it ? Otherwise please > do so. That is the best way to ensure that we don't get too many > problems in the future. > > I think in general all structures shared between the kernel and userland > should be equipped with a version number as the first element. this brings up whether we should have 'rules' for kernel structures in general.. for example "Always start with a version number followed by a magic number followed by the reference count and the lock" or something like that. I know some systems DO impoes such rules and seem to get advantages from it. (you can add debug code to check the magic numbers really easily for example). Not a REALLY serious suggestion but something to consider. what would YOU like to see as a standard part of kernel structures? reference count? magic number? generation count? lock (pointer?) version number? I leads to a general discussion about kernel architecture eventually :-) > > -- > Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 > phk@FreeBSD.ORG | TCP/IP since RFC 956 > FreeBSD committer | BSD since 4.3-tahoe > Never attribute to malice what can adequately be explained by incompetence. > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-arch" in the body of the message -- __--_|\ Julian Elischer / \ julian@elischer.org ( OZ ) World tour 2000-2001 ---> X_.---._/ v To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message