Commit | Line | Data |
---|---|---|
a2907882 KM |
1 | /* |
2 | * Copyright (c) 1989 The Regents of the University of California. | |
3 | * All rights reserved. | |
4 | * | |
5 | * This code is derived from software contributed to Berkeley by | |
6 | * Rick Macklem at The University of Guelph. | |
7 | * | |
dbf0c423 | 8 | * %sccs.include.redist.c% |
a2907882 | 9 | * |
9580c523 | 10 | * @(#)nfsmount.h 7.11 (Berkeley) %G% |
a2907882 KM |
11 | */ |
12 | ||
13 | /* | |
14 | * Mount structure. | |
ecfaf81a KM |
15 | * One allocated on every NFS mount. |
16 | * Holds NFS specific information for mount. | |
a2907882 KM |
17 | */ |
18 | struct nfsmount { | |
19 | int nm_flag; /* Flags for soft/hard... */ | |
ecfaf81a | 20 | struct mount *nm_mountp; /* Vfs structure for this filesystem */ |
2c5b44a2 | 21 | int nm_numgrps; /* Max. size of groupslist */ |
a2907882 | 22 | nfsv2fh_t nm_fh; /* File handle of root dir */ |
f0f1cbaa KM |
23 | struct socket *nm_so; /* Rpc socket */ |
24 | int nm_sotype; /* Type of socket */ | |
25 | int nm_soproto; /* and protocol */ | |
26 | int nm_soflags; /* pr_flags for socket protocol */ | |
27 | struct mbuf *nm_nam; /* Addr of server */ | |
2c5b44a2 KM |
28 | int nm_timeo; /* Init timer for NFSMNT_DUMBTIMR */ |
29 | int nm_retry; /* Max retries */ | |
30 | int nm_srtt[4]; /* Timers for rpcs */ | |
31 | int nm_sdrtt[4]; | |
32 | int nm_sent; /* Request send count */ | |
33 | int nm_cwnd; /* Request send window */ | |
34 | int nm_timeouts; /* Request timeouts */ | |
35 | int nm_deadthresh; /* Threshold of timeouts-->dead server*/ | |
a2907882 KM |
36 | int nm_rsize; /* Max size of read rpc */ |
37 | int nm_wsize; /* Max size of write rpc */ | |
2c5b44a2 KM |
38 | int nm_readahead; /* Num. of blocks to readahead */ |
39 | int nm_leaseterm; /* Term (sec) for NQNFS lease */ | |
40 | struct nfsnode *nm_tnext; /* Head of lease timer queue */ | |
41 | struct nfsnode *nm_tprev; | |
42 | struct vnode *nm_inprog; /* Vnode in prog by nqnfs_clientd() */ | |
43 | uid_t nm_authuid; /* Uid for authenticator */ | |
44 | int nm_authtype; /* Authenticator type */ | |
45 | int nm_authlen; /* and length */ | |
46 | char *nm_authstr; /* Authenticator string */ | |
ecfaf81a KM |
47 | }; |
48 | ||
54fb9dc2 KM |
49 | #ifdef KERNEL |
50 | /* | |
51 | * Convert mount ptr to nfsmount ptr. | |
52 | */ | |
53 | #define VFSTONFS(mp) ((struct nfsmount *)((mp)->mnt_data)) | |
54 | #endif /* KERNEL */ | |
4dbea688 KM |
55 | |
56 | /* | |
57 | * Prototypes for NFS mount operations | |
58 | */ | |
59 | int nfs_mount __P(( | |
60 | struct mount *mp, | |
61 | char *path, | |
62 | caddr_t data, | |
63 | struct nameidata *ndp, | |
64 | struct proc *p)); | |
65 | int nfs_start __P(( | |
66 | struct mount *mp, | |
67 | int flags, | |
68 | struct proc *p)); | |
69 | int nfs_unmount __P(( | |
70 | struct mount *mp, | |
71 | int mntflags, | |
72 | struct proc *p)); | |
73 | int nfs_root __P(( | |
74 | struct mount *mp, | |
75 | struct vnode **vpp)); | |
76 | int nfs_quotactl __P(( | |
77 | struct mount *mp, | |
78 | int cmds, | |
4861d2f1 | 79 | uid_t uid, |
4dbea688 KM |
80 | caddr_t arg, |
81 | struct proc *p)); | |
82 | int nfs_statfs __P(( | |
83 | struct mount *mp, | |
84 | struct statfs *sbp, | |
85 | struct proc *p)); | |
86 | int nfs_sync __P(( | |
87 | struct mount *mp, | |
4861d2f1 KM |
88 | int waitfor, |
89 | struct ucred *cred, | |
90 | struct proc *p)); | |
4dbea688 KM |
91 | int nfs_fhtovp __P(( |
92 | struct mount *mp, | |
93 | struct fid *fhp, | |
9580c523 KM |
94 | struct mbuf *nam, |
95 | struct vnode **vpp, | |
96 | int *exflagsp, | |
97 | struct ucred **credanonp)); | |
4dbea688 KM |
98 | int nfs_vptofh __P(( |
99 | struct vnode *vp, | |
100 | struct fid *fhp)); | |
101 | int nfs_init __P(()); |