locking questions (regarding file systems)
R. B. Riddick
arne_woerner at yahoo.com
Wed Aug 2 19:34:10 UTC 2006
--- Eric Anderson <anderson at centtech.com> wrote:
> Here's basically what I do:
> in the mount function for the FS, I do something like this:
> error = g_vfs_open(devvp, &cp, "fsname", 0);
> What is needed in my unmount function to release those locks? I've
> tried some combinations of things, like:
> # wedges here
> g_vfs_close(cp, td);
So the first un-mount works fine?
And the second un-mount wedges _before_ g_vfs_close?
I cannot find anything really suspicious in ur code...
Just 2 thoughts:
1. Do we really hold GIANT, when we mount and un-mount something?
2. R u sure, that we need vrele()? I mean: Why doesn't g_vfs_close() call
vrele(), if g_vfs_open() increases that use-count variable? Can u print the
use-count variable in the beginning and the end of the mount/un-mount
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
More information about the freebsd-fs