Deleted Added
full compact
fdesc_vfsops.c (132093) fdesc_vfsops.c (132902)
1/*
2 * Copyright (c) 1992, 1993, 1995
3 * The Regents of the University of California. All rights reserved.
4 *
5 * This code is derived from software donated to Berkeley by
6 * Jan-Simon Pendry.
7 *
8 * Redistribution and use in source and binary forms, with or without

--- 17 unchanged lines hidden (view full) ---

26 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
27 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
28 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
29 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
30 * SUCH DAMAGE.
31 *
32 * @(#)fdesc_vfsops.c 8.4 (Berkeley) 1/21/94
33 *
1/*
2 * Copyright (c) 1992, 1993, 1995
3 * The Regents of the University of California. All rights reserved.
4 *
5 * This code is derived from software donated to Berkeley by
6 * Jan-Simon Pendry.
7 *
8 * Redistribution and use in source and binary forms, with or without

--- 17 unchanged lines hidden (view full) ---

26 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
27 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
28 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
29 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
30 * SUCH DAMAGE.
31 *
32 * @(#)fdesc_vfsops.c 8.4 (Berkeley) 1/21/94
33 *
34 * $FreeBSD: head/sys/fs/fdescfs/fdesc_vfsops.c 132093 2004-07-13 09:46:46Z phk $
34 * $FreeBSD: head/sys/fs/fdescfs/fdesc_vfsops.c 132902 2004-07-30 22:08:52Z phk $
35 */
36
37/*
38 * /dev/fd Filesystem
39 */
40
41#include <sys/param.h>
42#include <sys/systm.h>

--- 6 unchanged lines hidden (view full) ---

49#include <sys/proc.h>
50#include <sys/resourcevar.h>
51#include <sys/vnode.h>
52
53#include <fs/fdescfs/fdesc.h>
54
55static MALLOC_DEFINE(M_FDESCMNT, "FDESC mount", "FDESC mount structure");
56
35 */
36
37/*
38 * /dev/fd Filesystem
39 */
40
41#include <sys/param.h>
42#include <sys/systm.h>

--- 6 unchanged lines hidden (view full) ---

49#include <sys/proc.h>
50#include <sys/resourcevar.h>
51#include <sys/vnode.h>
52
53#include <fs/fdescfs/fdesc.h>
54
55static MALLOC_DEFINE(M_FDESCMNT, "FDESC mount", "FDESC mount structure");
56
57static vfs_nmount_t fdesc_mount;
57static vfs_mount_t fdesc_mount;
58static vfs_unmount_t fdesc_unmount;
59static vfs_statfs_t fdesc_statfs;
60
61/*
62 * Mount the per-process file descriptors (/dev/fd)
63 */
64static int
58static vfs_unmount_t fdesc_unmount;
59static vfs_statfs_t fdesc_statfs;
60
61/*
62 * Mount the per-process file descriptors (/dev/fd)
63 */
64static int
65fdesc_mount(mp, ndp, td)
66 struct mount *mp;
67 struct nameidata *ndp;
68 struct thread *td;
65fdesc_mount(struct mount *mp, struct thread *td)
69{
70 int error = 0;
71 struct fdescmount *fmp;
72 struct vnode *rvp;
73
74 /*
75 * Update is a no-op
76 */

--- 121 unchanged lines hidden (view full) ---

198 bcopy(mp->mnt_stat.f_mntonname, sbp->f_mntonname, MNAMELEN);
199 bcopy(mp->mnt_stat.f_mntfromname, sbp->f_mntfromname, MNAMELEN);
200 }
201 return (0);
202}
203
204static struct vfsops fdesc_vfsops = {
205 .vfs_init = fdesc_init,
66{
67 int error = 0;
68 struct fdescmount *fmp;
69 struct vnode *rvp;
70
71 /*
72 * Update is a no-op
73 */

--- 121 unchanged lines hidden (view full) ---

195 bcopy(mp->mnt_stat.f_mntonname, sbp->f_mntonname, MNAMELEN);
196 bcopy(mp->mnt_stat.f_mntfromname, sbp->f_mntfromname, MNAMELEN);
197 }
198 return (0);
199}
200
201static struct vfsops fdesc_vfsops = {
202 .vfs_init = fdesc_init,
206 .vfs_nmount = fdesc_mount,
203 .vfs_mount = fdesc_mount,
207 .vfs_root = fdesc_root,
208 .vfs_statfs = fdesc_statfs,
209 .vfs_unmount = fdesc_unmount,
210};
211
212VFS_SET(fdesc_vfsops, fdescfs, VFCF_SYNTHETIC);
204 .vfs_root = fdesc_root,
205 .vfs_statfs = fdesc_statfs,
206 .vfs_unmount = fdesc_unmount,
207};
208
209VFS_SET(fdesc_vfsops, fdescfs, VFCF_SYNTHETIC);