Review request for NFS readdirplus change.

John Baldwin jhb at freebsd.org
Mon Sep 14 13:13:29 UTC 2009


On Sunday 13 September 2009 4:23:50 pm Pawel Jakub Dawidek wrote:
> Hi.
> 
> I'm looking for a review of the following patch:
> 
> 	http://people.freebsd.org/~pjd/patches/nfs_serv.c.3.patch
> 
> The main purpose of this patch is to support stuff like ZFS, where using
> VFS_VGET() might be tricky on .zfs/ directory and friends. When
> VFS_VGET() is not supported be the underlying file system, we switch to
> VOP_LOOKUP(). Note that OpenSolaris NFS server implementation always
> uses lookup for readdirplus.
> 
> I also modified the code to use shared-locking, there is no need to
> exclusively lock the vnodes.
> 
> The patch removes an assert which doesn't hold for ZFS when we go into
> .zfs/snapshot/<name>/ directory, which is separate mount point, but we
> don't want to export it separately, so we still return it on lookup.

I don't think you need the trailing '\' before a split expression when 
building cn_flags.  Other than that I think it looks ok from what I can see 
(but I am far less familiar with the NFS server than the NFS client).  Also, 
you might want to patch the new NFS server as well as the old one (or ask 
Rick about the new one).

-- 
John Baldwin


More information about the freebsd-fs mailing list