1c398230bSWarner Losh /*- 2*51369649SPedro F. Giffuni * SPDX-License-Identifier: BSD-3-Clause 3*51369649SPedro F. Giffuni * 4996c772fSJohn Dyson * Copyright (c) 1989, 1993, 1995 5df8bae1dSRodney W. Grimes * The Regents of the University of California. All rights reserved. 6df8bae1dSRodney W. Grimes * 7df8bae1dSRodney W. Grimes * This code is derived from software contributed to Berkeley by 8df8bae1dSRodney W. Grimes * Rick Macklem at The University of Guelph. 9df8bae1dSRodney W. Grimes * 10df8bae1dSRodney W. Grimes * Redistribution and use in source and binary forms, with or without 11df8bae1dSRodney W. Grimes * modification, are permitted provided that the following conditions 12df8bae1dSRodney W. Grimes * are met: 13df8bae1dSRodney W. Grimes * 1. Redistributions of source code must retain the above copyright 14df8bae1dSRodney W. Grimes * notice, this list of conditions and the following disclaimer. 15df8bae1dSRodney W. Grimes * 2. Redistributions in binary form must reproduce the above copyright 16df8bae1dSRodney W. Grimes * notice, this list of conditions and the following disclaimer in the 17df8bae1dSRodney W. Grimes * documentation and/or other materials provided with the distribution. 18fbbd9655SWarner Losh * 3. Neither the name of the University nor the names of its contributors 19df8bae1dSRodney W. Grimes * may be used to endorse or promote products derived from this software 20df8bae1dSRodney W. Grimes * without specific prior written permission. 21df8bae1dSRodney W. Grimes * 22df8bae1dSRodney W. Grimes * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 23df8bae1dSRodney W. Grimes * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 24df8bae1dSRodney W. Grimes * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 25df8bae1dSRodney W. Grimes * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 26df8bae1dSRodney W. Grimes * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 27df8bae1dSRodney W. Grimes * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 28df8bae1dSRodney W. Grimes * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 29df8bae1dSRodney W. Grimes * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 30df8bae1dSRodney W. Grimes * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 31df8bae1dSRodney W. Grimes * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 32df8bae1dSRodney W. Grimes * SUCH DAMAGE. 33df8bae1dSRodney W. Grimes */ 34df8bae1dSRodney W. Grimes 35eb25edbdSPeter Wemm #ifndef _NFSSERVER_NFS_H_ 36eb25edbdSPeter Wemm #define _NFSSERVER_NFS_H_ 3733420ec6SPaul Richards 38c4473420SPeter Wemm #ifdef _KERNEL 39df394affSJohn-Mark Gurney #include "opt_nfs.h" 4056786ee9SJohn-Mark Gurney #endif 41df394affSJohn-Mark Gurney 4245452edcSRick Macklem #include <nfs/nfssvc.h> 4345452edcSRick Macklem 44df8bae1dSRodney W. Grimes /* 45df8bae1dSRodney W. Grimes * Tunable constants for nfs 46df8bae1dSRodney W. Grimes */ 47df8bae1dSRodney W. Grimes 486df06172SPeter Wemm #define NFS_TICKINTVL 10 /* Desired time for a tick (msec) */ 49a62dc406SDoug Rabson #define NFS_HZ (hz / nfs_ticks) /* Ticks/sec */ 50df8bae1dSRodney W. Grimes #define NFS_TIMEO (1 * NFS_HZ) /* Default timeout = 1 second */ 51df8bae1dSRodney W. Grimes #define NFS_MINTIMEO (1 * NFS_HZ) /* Min timeout to use */ 52df8bae1dSRodney W. Grimes #define NFS_MAXTIMEO (60 * NFS_HZ) /* Max timeout to backoff to */ 53df8bae1dSRodney W. Grimes #define NFS_MINIDEMTIMEO (5 * NFS_HZ) /* Min timeout for non-idempotent ops*/ 54df8bae1dSRodney W. Grimes #define NFS_MAXUIDHASH 64 /* Max. # of hashed uid entries/mp */ 55a62dc406SDoug Rabson #ifndef NFS_GATHERDELAY 56a62dc406SDoug Rabson #define NFS_GATHERDELAY 10 /* Default write gather delay (msec) */ 57a62dc406SDoug Rabson #endif 58c4473420SPeter Wemm #ifdef _KERNEL 5900780cefSBruce Evans #define DIRBLKSIZ 512 /* XXX we used to use ufs's DIRBLKSIZ */ 6000780cefSBruce Evans #endif 61a62dc406SDoug Rabson 62a62dc406SDoug Rabson /* 63a62dc406SDoug Rabson * Oddballs 64a62dc406SDoug Rabson */ 65a62dc406SDoug Rabson #define NFS_SRVMAXDATA(n) \ 66a62dc406SDoug Rabson (((n)->nd_flag & ND_NFSV3) ? (((n)->nd_nam2) ? \ 67a62dc406SDoug Rabson NFS_MAXDGRAMDATA : NFS_MAXDATA) : NFS_V2MAXDATA) 68a62dc406SDoug Rabson 69a62dc406SDoug Rabson /* 70a62dc406SDoug Rabson * XXX 71a62dc406SDoug Rabson * The B_INVAFTERWRITE flag should be set to whatever is required by the 72a62dc406SDoug Rabson * buffer cache code to say "Invalidate the block after it is written back". 73a62dc406SDoug Rabson */ 74a62dc406SDoug Rabson #define B_INVAFTERWRITE B_NOCACHE 75a62dc406SDoug Rabson 76a62dc406SDoug Rabson /* 77a62dc406SDoug Rabson * The IO_METASYNC flag should be implemented for local filesystems. 78a62dc406SDoug Rabson * (Until then, it is nothin at all.) 79a62dc406SDoug Rabson */ 80a62dc406SDoug Rabson #ifndef IO_METASYNC 81a62dc406SDoug Rabson #define IO_METASYNC 0 82a62dc406SDoug Rabson #endif 83df8bae1dSRodney W. Grimes 84eb25edbdSPeter Wemm /* NFS state flags XXX -Wunused */ 85eb25edbdSPeter Wemm #define NFSRV_SNDLOCK 0x01000000 /* Send socket lock */ 86eb25edbdSPeter Wemm #define NFSRV_WANTSND 0x02000000 /* Want above */ 87996c772fSJohn Dyson 88a62dc406SDoug Rabson /* 89869652f6SMarius Strobl * Structures for the nfssvc(2) syscall. Not that anyone but nfsd and 90869652f6SMarius Strobl * mount_nfs should ever try and use it. 91df8bae1dSRodney W. Grimes */ 92a9148abdSDoug Rabson 93a9148abdSDoug Rabson /* 94a9148abdSDoug Rabson * Add a socket to monitor for NFS requests. 95a9148abdSDoug Rabson */ 96a9148abdSDoug Rabson struct nfsd_addsock_args { 97df8bae1dSRodney W. Grimes int sock; /* Socket to serve */ 98996c772fSJohn Dyson caddr_t name; /* Client addr for connection based sockets */ 99df8bae1dSRodney W. Grimes int namelen; /* Length of name */ 100df8bae1dSRodney W. Grimes }; 101df8bae1dSRodney W. Grimes 102df8bae1dSRodney W. Grimes /* 103a9148abdSDoug Rabson * Start processing requests. 104a9148abdSDoug Rabson */ 105a9148abdSDoug Rabson struct nfsd_nfsd_args { 106a9148abdSDoug Rabson const char *principal; /* GSS-API service principal name */ 107a9148abdSDoug Rabson int minthreads; /* minimum service thread count */ 108a9148abdSDoug Rabson int maxthreads; /* maximum service thread count */ 109a9148abdSDoug Rabson }; 110a9148abdSDoug Rabson 111a9148abdSDoug Rabson /* 112996c772fSJohn Dyson * XXX to allow amd to include nfs.h without nfsproto.h 113996c772fSJohn Dyson */ 114996c772fSJohn Dyson #ifdef NFS_NPROCS 115eb25edbdSPeter Wemm #include <nfsserver/nfsrvstats.h> 116996c772fSJohn Dyson #endif 117df8bae1dSRodney W. Grimes 118df8bae1dSRodney W. Grimes /* 119eb25edbdSPeter Wemm * vfs.nfsrv sysctl(3) identifiers 120b43e29afSGarrett Wollman */ 121eb25edbdSPeter Wemm #define NFS_NFSRVSTATS 1 /* struct: struct nfsrvstats */ 122394da4c1SGuido van Rooij #define NFS_NFSPRIVPORT 2 /* int: prohibit nfs to resvports */ 123b43e29afSGarrett Wollman 124c4473420SPeter Wemm #ifdef _KERNEL 125d9e91095SGarrett Wollman 1261ee624b3SRobert Watson extern struct mtx nfsd_mtx; 1271ee624b3SRobert Watson #define NFSD_LOCK_ASSERT() mtx_assert(&nfsd_mtx, MA_OWNED) 1281ee624b3SRobert Watson #define NFSD_UNLOCK_ASSERT() mtx_assert(&nfsd_mtx, MA_NOTOWNED) 1291ee624b3SRobert Watson #define NFSD_LOCK_DONTCARE() 1301ee624b3SRobert Watson #define NFSD_LOCK() mtx_lock(&nfsd_mtx) 1311ee624b3SRobert Watson #define NFSD_UNLOCK() mtx_unlock(&nfsd_mtx) 1321ee624b3SRobert Watson 133a1c995b6SPoul-Henning Kamp #ifdef MALLOC_DECLARE 134a1c995b6SPoul-Henning Kamp MALLOC_DECLARE(M_NFSRVDESC); 135a1c995b6SPoul-Henning Kamp MALLOC_DECLARE(M_NFSD); 1360d7d0fcfSPeter Wemm #endif 1370d7d0fcfSPeter Wemm 138eb25edbdSPeter Wemm /* Forward declarations */ 139eb25edbdSPeter Wemm struct nfssvc_sock; 140eb25edbdSPeter Wemm struct nfsrv_descript; 141eb25edbdSPeter Wemm struct uio; 142eb25edbdSPeter Wemm struct vattr; 143eb25edbdSPeter Wemm struct nameidata; 144a1c995b6SPoul-Henning Kamp 145fa3d2a12SAlexander Kabaev extern struct callout nfsrv_callout; 146eb25edbdSPeter Wemm extern struct nfsrvstats nfsrvstats; 147cae300beSBruce Evans 148b3a39c8aSMike Smith extern int nfsrv_ticks; 149eb25edbdSPeter Wemm extern int nfsrvw_procrastinate; 150eb25edbdSPeter Wemm extern int nfsrvw_procrastinate_v3; 151ae00154cSPeter Edwards extern int nfsrv_numnfsd; 152d9e91095SGarrett Wollman 153eb25edbdSPeter Wemm /* Various values converted to XDR form. */ 154b3a39c8aSMike Smith extern u_int32_t nfsrv_nfs_false, nfsrv_nfs_true, nfsrv_nfs_xdrneg1, 155b3a39c8aSMike Smith nfsrv_nfs_prog; 156b3a39c8aSMike Smith extern u_int32_t nfsrv_rpc_reply, nfsrv_rpc_msgdenied, nfsrv_rpc_mismatch, 157b3a39c8aSMike Smith nfsrv_rpc_vers; 158b3a39c8aSMike Smith extern u_int32_t nfsrv_rpc_auth_unix, nfsrv_rpc_msgaccepted, nfsrv_rpc_call, 159b3a39c8aSMike Smith nfsrv_rpc_autherr; 160df8bae1dSRodney W. Grimes 161eb25edbdSPeter Wemm /* Procedure table data */ 1621ee624b3SRobert Watson extern const int nfsrvv2_procid[NFS_NPROCS]; 1631ee624b3SRobert Watson extern const int nfsrv_nfsv3_procid[NFS_NPROCS]; 164eb25edbdSPeter Wemm extern int32_t (*nfsrv3_procs[NFS_NPROCS])(struct nfsrv_descript *nd, 1653daba5a6SAttilio Rao struct nfssvc_sock *slp, struct mbuf **mreqp); 166df8bae1dSRodney W. Grimes 167df8bae1dSRodney W. Grimes /* 168df8bae1dSRodney W. Grimes * A list of nfssvc_sock structures is maintained with all the sockets 169df8bae1dSRodney W. Grimes * that require service by the nfsd. 170df8bae1dSRodney W. Grimes */ 171a62dc406SDoug Rabson #ifndef NFS_WDELAYHASHSIZ 172a62dc406SDoug Rabson #define NFS_WDELAYHASHSIZ 16 /* and with this */ 173a62dc406SDoug Rabson #endif 174a62dc406SDoug Rabson #define NWDELAYHASH(sock, f) \ 1754152886fSPeter Wemm (&(sock)->ns_wdelayhashtbl[(*((u_int32_t *)(f))) % NFS_WDELAYHASHSIZ]) 176df8bae1dSRodney W. Grimes 177a9148abdSDoug Rabson /* 178a9148abdSDoug Rabson * This structure is used by the server for describing each request. 179a9148abdSDoug Rabson */ 180a9148abdSDoug Rabson struct nfsrv_descript { 181a9148abdSDoug Rabson struct mbuf *nd_mrep; /* Request mbuf list */ 182a9148abdSDoug Rabson struct mbuf *nd_md; /* Current dissect mbuf */ 183a9148abdSDoug Rabson struct mbuf *nd_mreq; /* Reply mbuf list */ 184a9148abdSDoug Rabson struct sockaddr *nd_nam; /* and socket addr */ 185a9148abdSDoug Rabson struct sockaddr *nd_nam2; /* return socket addr */ 186a9148abdSDoug Rabson caddr_t nd_dpos; /* Current dissect pos */ 187a9148abdSDoug Rabson u_int32_t nd_procnum; /* RPC # */ 188a9148abdSDoug Rabson int nd_stable; /* storage type */ 189a9148abdSDoug Rabson int nd_flag; /* nd_flag */ 190a9148abdSDoug Rabson int nd_repstat; /* Reply status */ 191a9148abdSDoug Rabson fhandle_t nd_fh; /* File handle */ 192a9148abdSDoug Rabson struct ucred *nd_cr; /* Credentials */ 193a9148abdSDoug Rabson int nd_credflavor; /* Security flavor */ 194a9148abdSDoug Rabson }; 195a9148abdSDoug Rabson 196a62dc406SDoug Rabson /* Bits for "nd_flag" */ 197a62dc406SDoug Rabson #define ND_NFSV3 0x08 198a62dc406SDoug Rabson 199e7756081SDoug Rabson /* 200e7756081SDoug Rabson * Defines for WebNFS 201e7756081SDoug Rabson */ 202e7756081SDoug Rabson 203e7756081SDoug Rabson #define WEBNFS_ESC_CHAR '%' 204e7756081SDoug Rabson #define WEBNFS_SPECCHAR_START 0x80 205e7756081SDoug Rabson 206e7756081SDoug Rabson #define WEBNFS_NATIVE_CHAR 0x80 207e7756081SDoug Rabson /* 208e7756081SDoug Rabson * .. 209e7756081SDoug Rabson * Possibly more here in the future. 210e7756081SDoug Rabson */ 211e7756081SDoug Rabson 212e7756081SDoug Rabson /* 213e7756081SDoug Rabson * Macro for converting escape characters in WebNFS pathnames. 214e7756081SDoug Rabson * Should really be in libkern. 215e7756081SDoug Rabson */ 216e7756081SDoug Rabson 217e7756081SDoug Rabson #define HEXTOC(c) \ 218e7756081SDoug Rabson ((c) >= 'a' ? ((c) - ('a' - 10)) : \ 219e7756081SDoug Rabson ((c) >= 'A' ? ((c) - ('A' - 10)) : ((c) - '0'))) 220e7756081SDoug Rabson #define HEXSTRTOI(p) \ 221e7756081SDoug Rabson ((HEXTOC(p[0]) << 4) + HEXTOC(p[1])) 222e7756081SDoug Rabson 2235ae0f718SDoug Rabson #ifdef NFS_DEBUG 2245ae0f718SDoug Rabson 2255ae0f718SDoug Rabson extern int nfs_debug; 2265ae0f718SDoug Rabson #define NFS_DEBUG_ASYNCIO 1 /* asynchronous i/o */ 2275ae0f718SDoug Rabson #define NFS_DEBUG_WG 2 /* server write gathering */ 2285ae0f718SDoug Rabson #define NFS_DEBUG_RC 4 /* server request caching */ 2295ae0f718SDoug Rabson 2305ae0f718SDoug Rabson #define NFS_DPF(cat, args) \ 2315ae0f718SDoug Rabson do { \ 2325ae0f718SDoug Rabson if (nfs_debug & NFS_DEBUG_##cat) printf args; \ 2335ae0f718SDoug Rabson } while (0) 2345ae0f718SDoug Rabson 2355ae0f718SDoug Rabson #else 2365ae0f718SDoug Rabson 2375ae0f718SDoug Rabson #define NFS_DPF(cat, args) 2385ae0f718SDoug Rabson 2395ae0f718SDoug Rabson #endif 240996c772fSJohn Dyson 2417ef95239SPawel Jakub Dawidek /* 2427ef95239SPawel Jakub Dawidek * The following flags can be passed to nfsrv_fhtovp() function. 2437ef95239SPawel Jakub Dawidek */ 2447ef95239SPawel Jakub Dawidek /* Leave file system busy on success. */ 2457ef95239SPawel Jakub Dawidek #define NFSRV_FLAG_BUSY 0x01 2467ef95239SPawel Jakub Dawidek 247a9148abdSDoug Rabson struct mbuf *nfs_rephead(int, struct nfsrv_descript *, int, struct mbuf **, 248a9148abdSDoug Rabson caddr_t *); 249eb25edbdSPeter Wemm void nfsm_srvfattr(struct nfsrv_descript *, struct vattr *, 250eb25edbdSPeter Wemm struct nfs_fattr *); 251eb25edbdSPeter Wemm void nfsm_srvwcc(struct nfsrv_descript *, int, struct vattr *, int, 252eb25edbdSPeter Wemm struct vattr *, struct mbuf **, char **); 253eb25edbdSPeter Wemm void nfsm_srvpostopattr(struct nfsrv_descript *, int, struct vattr *, 254eb25edbdSPeter Wemm struct mbuf **, char **); 255a9148abdSDoug Rabson int nfs_namei(struct nameidata *, struct nfsrv_descript *, fhandle_t *, 256a9148abdSDoug Rabson int, struct nfssvc_sock *, struct sockaddr *, struct mbuf **, 2573daba5a6SAttilio Rao caddr_t *, struct vnode **, int, struct vattr *, int *, int); 258eb25edbdSPeter Wemm void nfsm_adj(struct mbuf *, int, int); 259eb25edbdSPeter Wemm int nfsm_mbuftouio(struct mbuf **, struct uio *, int, caddr_t *); 260eb25edbdSPeter Wemm void nfsrv_init(int); 261eb25edbdSPeter Wemm int nfsrv_errmap(struct nfsrv_descript *, int); 262eb25edbdSPeter Wemm void nfsrvw_sort(gid_t *, int); 263473e9734SPoul-Henning Kamp 264eb25edbdSPeter Wemm int nfsrv3_access(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp, 2653daba5a6SAttilio Rao struct mbuf **mrq); 266eb25edbdSPeter Wemm int nfsrv_commit(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp, 2673daba5a6SAttilio Rao struct mbuf **mrq); 268eb25edbdSPeter Wemm int nfsrv_create(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp, 2693daba5a6SAttilio Rao struct mbuf **mrq); 2705050aa86SKonstantin Belousov int nfsrv_fhtovp(fhandle_t *, int, struct vnode **, 271a9148abdSDoug Rabson struct nfsrv_descript *, struct nfssvc_sock *, struct sockaddr *, 2727ef95239SPawel Jakub Dawidek int *); 273eb25edbdSPeter Wemm int nfsrv_setpublicfs(struct mount *, struct netexport *, 274eb25edbdSPeter Wemm struct export_args *); 275eb25edbdSPeter Wemm int nfs_ispublicfh(fhandle_t *); 276eb25edbdSPeter Wemm int nfsrv_fsinfo(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp, 2773daba5a6SAttilio Rao struct mbuf **mrq); 278eb25edbdSPeter Wemm int nfsrv_getattr(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp, 2793daba5a6SAttilio Rao struct mbuf **mrq); 280eb25edbdSPeter Wemm int nfsrv_link(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp, 2813daba5a6SAttilio Rao struct mbuf **mrq); 282eb25edbdSPeter Wemm int nfsrv_lookup(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp, 2833daba5a6SAttilio Rao struct mbuf **mrq); 284eb25edbdSPeter Wemm int nfsrv_mkdir(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp, 2853daba5a6SAttilio Rao struct mbuf **mrq); 286eb25edbdSPeter Wemm int nfsrv_mknod(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp, 2873daba5a6SAttilio Rao struct mbuf **mrq); 288eb25edbdSPeter Wemm int nfsrv_noop(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp, 2893daba5a6SAttilio Rao struct mbuf **mrq); 290eb25edbdSPeter Wemm int nfsrv_null(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp, 2913daba5a6SAttilio Rao struct mbuf **mrq); 292eb25edbdSPeter Wemm int nfsrv_pathconf(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp, 2933daba5a6SAttilio Rao struct mbuf **mrq); 294eb25edbdSPeter Wemm int nfsrv_read(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp, 2953daba5a6SAttilio Rao struct mbuf **mrq); 296eb25edbdSPeter Wemm int nfsrv_readdir(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp, 2973daba5a6SAttilio Rao struct mbuf **mrq); 298eb25edbdSPeter Wemm int nfsrv_readdirplus(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp, 2993daba5a6SAttilio Rao struct mbuf **mrq); 300eb25edbdSPeter Wemm int nfsrv_readlink(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp, 3013daba5a6SAttilio Rao struct mbuf **mrq); 302eb25edbdSPeter Wemm int nfsrv_remove(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp, 3033daba5a6SAttilio Rao struct mbuf **mrq); 304eb25edbdSPeter Wemm int nfsrv_rename(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp, 3053daba5a6SAttilio Rao struct mbuf **mrq); 306eb25edbdSPeter Wemm int nfsrv_rmdir(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp, 3073daba5a6SAttilio Rao struct mbuf **mrq); 308eb25edbdSPeter Wemm int nfsrv_setattr(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp, 3093daba5a6SAttilio Rao struct mbuf **mrq); 310eb25edbdSPeter Wemm int nfsrv_statfs(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp, 3113daba5a6SAttilio Rao struct mbuf **mrq); 312eb25edbdSPeter Wemm int nfsrv_symlink(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp, 3133daba5a6SAttilio Rao struct mbuf **mrq); 314eb25edbdSPeter Wemm int nfsrv_write(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp, 3153daba5a6SAttilio Rao struct mbuf **mrq); 31645452edcSRick Macklem /* 31745452edcSRick Macklem * #ifdef _SYS_SYSPROTO_H_ so that it is only defined when sysproto.h 31845452edcSRick Macklem * has been included, so that "struct nfssvc_args" is defined. 31945452edcSRick Macklem */ 32045452edcSRick Macklem #ifdef _SYS_SYSPROTO_H_ 32145452edcSRick Macklem int nfssvc_nfsserver(struct thread *, struct nfssvc_args *); 32245452edcSRick Macklem #endif 323c4473420SPeter Wemm #endif /* _KERNEL */ 32433420ec6SPaul Richards 32533420ec6SPaul Richards #endif 326