vnconfig -l support patch (Re: vn(4) RFC Misc.)

Matthew Dillon dillon at apollo.backplane.com
Mon Jan 14 07:51:49 PST 2008


::   Also, I'm not sure if I needed to lock anything before using
::   the vfs cache, so there might be problems there.
:
:    I'd suggest just constructing the path by hand and assuming the
:    form "/dev/vn*".  The namecache reference is not guarenteed
:    to exist... for example, the namecache can get flushed.

    Oh, scratch that comment.  You were trying to get the path to the
    file VN was covering.

    Use vn_fullpath() and pass 'curproc' as the process, though, instead
    of cache_fullpath(), and note that it might fail (maybe have it print
    '?' for the filename if it fails).  If the process is non-NULL
    vn_fullpath()/cache_fullpath() will truncate the path properly to
    the process's chroot.

						-Matt






More information about the Submit mailing list