From owner-freebsd-current Fri Jul 30 0:16: 8 1999 Delivered-To: freebsd-current@freebsd.org Received: from implode.root.com (root.com [209.102.106.178]) by hub.freebsd.org (Postfix) with ESMTP id 8ED0414BFE for ; Fri, 30 Jul 1999 00:16:04 -0700 (PDT) (envelope-from root@implode.root.com) Received: from implode.root.com (localhost [127.0.0.1]) by implode.root.com (8.8.8/8.8.5) with ESMTP id AAA12928; Fri, 30 Jul 1999 00:12:04 -0700 (PDT) Message-Id: <199907300712.AAA12928@implode.root.com> To: Matthew Dillon Cc: Bill Paul , peter@netplex.com.au, crossd@cs.rpi.edu, current@FreeBSD.ORG Subject: Re: readdirplus client side fix (was Re: IRIX 6.5.4 NFS v3 TCP client + FreeBSD server = bewm) In-reply-to: Your message of "Thu, 29 Jul 1999 20:31:38 PDT." <199907300331.UAA81350@apollo.backplane.com> From: David Greenman Reply-To: dg@root.com Date: Fri, 30 Jul 1999 00:12:04 -0700 Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG > Look up a bit in the code. If bigenough is not true, cnp does not > get initialized. This could lead to the bogus length -- or rather, > it would be the cnp that is bogus, not the 'len'. > > The question is how to fix it. I think we can safely avoid doing the > cache_enter so try changing the 'if (doit)' to 'if (doit && bigenough)'. > I've included the patch below. ... > In order to accomplish this, the underlying vnode representing each > directory entry is retrieved and locked. However, there is a special > case: We *already* have a reference on the directory vnode itself, > and one of the directory entries, ".", will be the same vnode. Our > reference vnode, vp is *NOT* locked. In fact, we *can't* lock it > without creating a potential deadlock situation (at least that is my > take). I good bit of detective work...excellent job. -DG David Greenman Co-founder/Principal Architect, The FreeBSD Project - http://www.freebsd.org Creator of high-performance Internet servers - http://www.terasolutions.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message