Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 2 Aug 2010 17:57:43 GMT
From:      Efstratios Karatzas <gpf@FreeBSD.org>
To:        Perforce Change Reviews <perforce@FreeBSD.org>
Subject:   PERFORCE change 181734 for review
Message-ID:  <201008021757.o72Hvh2h026769@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
http://p4web.freebsd.org/@@181734?ac=10

Change 181734 by gpf@gpf_desktop on 2010/08/02 17:57:28

	- minor changes for VOP_GETPARENT(9)
	- man pages for VOP_GETPARENT(9), VFS_FHHINT(9) & vn_fullpath_nocache(9).
	Note that these man pages are not formatted, just plain text and that's 
	why I'm adding them to the base of my depot path. Feel free to comment!
	I'll give my nonexistant mdoc skills a chance in a week or so, at which point 
	the man pages will be placed at the correct location.
	- man page update for VOP_VPTOFH(9)

Affected files ...

.. //depot/projects/soc2010/gpf_audit/freebsd/src/share/man/man9/VOP_VPTOFH.9#2 edit
.. //depot/projects/soc2010/gpf_audit/freebsd/src/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c#5 edit
.. //depot/projects/soc2010/gpf_audit/freebsd/src/sys/ufs/ffs/ffs_vnops.c#9 edit
.. //depot/projects/soc2010/gpf_audit/vfs_fhhint.txt#1 add
.. //depot/projects/soc2010/gpf_audit/vn_fullpath_nocache.txt#1 add
.. //depot/projects/soc2010/gpf_audit/vop_getparent.txt#1 add

Differences ...

==== //depot/projects/soc2010/gpf_audit/freebsd/src/share/man/man9/VOP_VPTOFH.9#2 (text+ko) ====

@@ -38,7 +38,7 @@
 .In sys/param.h
 .In sys/vnode.h
 .Ft int
-.Fn VOP_VPTOFH "struct vnode *vp" "struct fid *fhp"
+.Fn VOP_VPTOFH "struct vnode *vp" "struct fid *fhp" "struct vnode *dvp"
 .Sh DESCRIPTION
 This is used by the NFS server to create an opaque filehandle which
 uniquely identifies the file and which can be used by an NFS client
@@ -50,10 +50,15 @@
 The vnode to make a filehandle for.
 .It Fa fhp
 Return parameter for the filehandle.
+.It Fa dvp
+The directory vnode that contains a dirent for vp, NULL otherwise.
+This is used to store a hint that will facilitate the work of
+.Xr vn_fullpath_nocache 9 .
 .El
 .Sh SEE ALSO
 .Xr VFS 9 ,
 .Xr VFS_FHTOVP 9 ,
+.Xr vn_fullpath_nocache 9 ,
 .Xr vnode 9
 .Sh AUTHORS
 This manual page was written by

==== //depot/projects/soc2010/gpf_audit/freebsd/src/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c#5 (text+ko) ====

@@ -5081,7 +5081,7 @@
 						len = strlen(pch);
 
 						if (len >= *(ap->a_buflen)) {
-							error = EOVERFLOW;
+							error = ENOMEM;
 							goto out;
 						}
 

==== //depot/projects/soc2010/gpf_audit/freebsd/src/sys/ufs/ffs/ffs_vnops.c#9 (text+ko) ====

@@ -1892,7 +1892,7 @@
 					len = strlen(pch);
 				
 					if (len >= *namelen) {
-						error = EOVERFLOW;
+						error = ENOMEM;
 						goto out;
 					}
 
@@ -2018,8 +2018,8 @@
 	}
 
 	/* 
-	 * if our target is not a directory and we haven't found 'a' parent directory, 
-	 * do an exhaustive search on the filesystem
+	 * if owe haven't found 'a' parent directory, do an exhaustive search on 
+	 * the filesystem
 	 */
 	if ((flags & EXHAUSTSEARCH) && dvp == NULL) {
 		error = VFS_VGET(mp, ROOTINO, LK_SHARED, &startdvp);
@@ -2030,14 +2030,12 @@
 				vput(startdvp);
 			}
 		}
-		if (error) {
+		else
 			error = ENOENT;
-		}
 	}	
 	/* we failed to find a directory that contains the vnode, exit */
-	else if (dvp == NULL) {
+	else if (dvp == NULL)
 		error = ENOENT;
-	}
 
 out:
 	if (error == 0 && dvp != NULL)



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201008021757.o72Hvh2h026769>