summaryrefslogtreecommitdiffstats
path: root/sys/fs/portalfs
diff options
context:
space:
mode:
authorattilio <attilio@FreeBSD.org>2009-05-11 15:33:26 +0000
committerattilio <attilio@FreeBSD.org>2009-05-11 15:33:26 +0000
commit1dcb84131b6679f5d53452314d4ca1dfe2d8c5f0 (patch)
tree6591f00318da636f44a6ceb26f517e7795eb1b44 /sys/fs/portalfs
parentebcb20267286e4ffadb3f603af56bd7a1df1f422 (diff)
downloadFreeBSD-src-1dcb84131b6679f5d53452314d4ca1dfe2d8c5f0.zip
FreeBSD-src-1dcb84131b6679f5d53452314d4ca1dfe2d8c5f0.tar.gz
Remove the thread argument from the FSD (File-System Dependent) parts of
the VFS. Now all the VFS_* functions and relating parts don't want the context as long as it always refers to curthread. In some points, in particular when dealing with VOPs and functions living in the same namespace (eg. vflush) which still need to be converted, pass curthread explicitly in order to retain the old behaviour. Such loose ends will be fixed ASAP. While here fix a bug: now, UFS_EXTATTR can be compiled alone without the UFS_EXTATTR_AUTOSTART option. VFS KPI is heavilly changed by this commit so thirdy parts modules needs to be recompiled. Bump __FreeBSD_version in order to signal such situation.
Diffstat (limited to 'sys/fs/portalfs')
-rw-r--r--sys/fs/portalfs/portal_vfsops.c17
1 files changed, 8 insertions, 9 deletions
diff --git a/sys/fs/portalfs/portal_vfsops.c b/sys/fs/portalfs/portal_vfsops.c
index c2057c6..a8c16c4 100644
--- a/sys/fs/portalfs/portal_vfsops.c
+++ b/sys/fs/portalfs/portal_vfsops.c
@@ -68,7 +68,7 @@ static const char *portal_opts[] = {
};
static int
-portal_cmount(struct mntarg *ma, void *data, int flags, struct thread *td)
+portal_cmount(struct mntarg *ma, void *data, int flags)
{
struct portal_args args;
int error;
@@ -90,16 +90,18 @@ portal_cmount(struct mntarg *ma, void *data, int flags, struct thread *td)
* Mount the per-process file descriptors (/dev/fd)
*/
static int
-portal_mount(struct mount *mp, struct thread *td)
+portal_mount(struct mount *mp)
{
struct file *fp;
struct portalmount *fmp;
struct socket *so;
struct vnode *rvp;
+ struct thread *td;
struct portalnode *pn;
int error, v;
char *p;
+ td = curthread;
if (vfs_filteropt(mp->mnt_optnew, portal_opts))
return (EINVAL);
@@ -165,10 +167,9 @@ portal_mount(struct mount *mp, struct thread *td)
}
static int
-portal_unmount(mp, mntflags, td)
+portal_unmount(mp, mntflags)
struct mount *mp;
int mntflags;
- struct thread *td;
{
int error, flags = 0;
@@ -187,7 +188,7 @@ portal_unmount(mp, mntflags, td)
return (EBUSY);
#endif
/* There is 1 extra root vnode reference (pm_root). */
- error = vflush(mp, 1, flags, td);
+ error = vflush(mp, 1, flags, curthread);
if (error)
return (error);
@@ -211,11 +212,10 @@ portal_unmount(mp, mntflags, td)
}
static int
-portal_root(mp, flags, vpp, td)
+portal_root(mp, flags, vpp)
struct mount *mp;
int flags;
struct vnode **vpp;
- struct thread *td;
{
struct vnode *vp;
@@ -230,10 +230,9 @@ portal_root(mp, flags, vpp, td)
}
static int
-portal_statfs(mp, sbp, td)
+portal_statfs(mp, sbp)
struct mount *mp;
struct statfs *sbp;
- struct thread *td;
{
sbp->f_flags = 0;
OpenPOWER on IntegriCloud