From owner-freebsd-arch Fri Feb 22 16:10:39 2002 Delivered-To: freebsd-arch@freebsd.org Received: from mail12.speakeasy.net (mail12.speakeasy.net [216.254.0.212]) by hub.freebsd.org (Postfix) with ESMTP id AECD337B400 for ; Fri, 22 Feb 2002 16:10:35 -0800 (PST) Received: (qmail 21666 invoked from network); 23 Feb 2002 00:10:33 -0000 Received: from unknown (HELO laptop.baldwin.cx) ([65.91.137.227]) (envelope-sender ) by mail12.speakeasy.net (qmail-ldap-1.03) with SMTP for ; 23 Feb 2002 00:10:33 -0000 Message-ID: X-Mailer: XFMail 1.4.0 on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 In-Reply-To: <200202221835.g1MIZsZ18088@apollo.backplane.com> Date: Fri, 22 Feb 2002 19:10:32 -0500 (EST) From: John Baldwin To: Matthew Dillon Subject: Re: RE: that INVARIANT/ucred freeing stuff. Cc: arch@FreeBSD.ORG, Julian Elischer Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On 22-Feb-02 Matthew Dillon wrote: > >:>:John Baldwin <>< http://www.FreeBSD.org/~jhb/ >:> >:> Don't try to overengineer the problem. Unless you believe there is >:> a serious problem, there is no need to put a check in every single >:> conceivable place an error might occur. Just putting a few safety >:> checks >:> in a few critical places should be sufficient. >: >:I don't know where all the places we might look at a ucred wrongly are. >:That's >:why I wanted the much simpler solution of just clearing td_ucred to NULL so >:we >:had an implicit KASSERT for us in all those places. >: >:-- >: >:John Baldwin <>< http://www.FreeBSD.org/~jhb/ > > This doesn't make any sense whatsoever. *NOTHING* was using td_ucred > until just a few days ago, so unless *you* are blindly changing all > p->p_ucred's into td->td_ucred's, I don't see how it can become an issue. Yes, almost all the p_ucred's are changing to td_ucred. That is why we have td_ucred. td_ucred doesn't need a lock, but accessing p_ucred does. Did you read the description of td_ucred back when it was first proposed? > -Matt -- John Baldwin <>< http://www.FreeBSD.org/~jhb/ "Power Users Use the Power to Serve!" - http://www.FreeBSD.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message