Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 17 Apr 1998 13:59:14 +0900 (JST)
From:      Michael Hancock <michaelh@cet.co.jp>
To:        freebsd-current@FreeBSD.ORG
Cc:        freebsd-fs@FreeBSD.ORG
Subject:   Updated vfs patches
Message-ID:  <Pine.SV4.3.95.980417133824.17216A-100000@parkplace.cet.co.jp>

next in thread | raw e-mail | index | archive | help
I've separated the layering fixes and the VFS_VRELE framework into
separate projects.  Here is an updated patch for making *both* refcounting
and locking of vnodes reflexive using the current framework.

http://www.freebsd.org/~mch/vop1a.diff

For a testing tool see http://www.freebsd.org/~mch

Some things I should note in this patch are listed below:

1) In the original code, ext2_rmdir and msdosfs_rmdir release the lock
across the truncate call but ufs_rmdir doesn't.  The ufs_rmdir
implementation make it clean for me because I just delete the vput(), but
in ext2_rmdir and msdosfs_rmdir I must reacquire the lock so the generic
layer can do the vput() (phew!).  I'm not sure if we should be holding a
lock across truncate and I have yet to review the logs yet to see why.
Perhaps someone can shed some light on this.

2) In the union filesystem, there are a also a few case where I have to
reacquire the lock.  However, it appears that there is an invariant that
says if the upper vnode is held by me I can "diddle with the union vnode
locking state at will", see UN_KLOCK and UN_ULOCK.  I take advantage of
this and reacquire the lock by just twiddling a bit instead of calling
vn_lock(). 

Otherwise, this patch consists of mostly deleting vrele and vput calls in
underlying filesystems and moving them to the generic layer.

Regards,



Mike Hancock


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-fs" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.SV4.3.95.980417133824.17216A-100000>