Author: rmacklem
Date: Mon Nov  1 01:55:15 2010
New Revision: 214614
URL: http://svn.freebsd.org/changeset/base/214614

Log:
  MFC: r214149
  Modify the experimental NFS server in a manner analagous to
  r214049 for the regular NFS server, so that it will not do
  a VOP_LOOKUP() of ".." when at the root of a file system
  when performing a ReaddirPlus RPC.

Modified:
  stable/8/sys/fs/nfsserver/nfs_nfsdport.c
Directory Properties:
  stable/8/sys/   (props changed)
  stable/8/sys/amd64/include/xen/   (props changed)
  stable/8/sys/cddl/contrib/opensolaris/   (props changed)
  stable/8/sys/contrib/dev/acpica/   (props changed)
  stable/8/sys/contrib/pf/   (props changed)
  stable/8/sys/dev/xen/xenpci/   (props changed)

Modified: stable/8/sys/fs/nfsserver/nfs_nfsdport.c
==============================================================================
--- stable/8/sys/fs/nfsserver/nfs_nfsdport.c    Mon Nov  1 01:51:47 2010        
(r214613)
+++ stable/8/sys/fs/nfsserver/nfs_nfsdport.c    Mon Nov  1 01:55:15 2010        
(r214614)
@@ -1933,7 +1933,15 @@ again:
                                                        vn_lock(vp,
                                                            LK_EXCLUSIVE |
                                                            LK_RETRY);
-                                               r = VOP_LOOKUP(vp, &nvp, &cn);
+                                               if ((vp->v_vflag & VV_ROOT) != 0
+                                                   && (cn.cn_flags & ISDOTDOT)
+                                                   != 0) {
+                                                       vref(vp);
+                                                       nvp = vp;
+                                                       r = 0;
+                                               } else
+                                                       r = VOP_LOOKUP(vp, &nvp,
+                                                           &cn);
                                        }
                                }
                                if (!r) {
_______________________________________________
[email protected] mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "[email protected]"

Reply via email to