brintos

brintos / linux-shallow public Read only

0
0
Text · 1.4 KiB · e0237e0 Raw
69 lines · c
1/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */2/*3 * NFS protocol definitions4 *5 * This file contains constants for Version 2 of the protocol.6 */7#ifndef _LINUX_NFS2_H8#define _LINUX_NFS2_H9 10#define NFS2_PORT	204911#define NFS2_MAXDATA	819212#define NFS2_MAXPATHLEN	102413#define NFS2_MAXNAMLEN	25514#define NFS2_MAXGROUPS	1615#define NFS2_FHSIZE	3216#define NFS2_COOKIESIZE	417#define NFS2_FIFO_DEV	(-1)18#define NFS2MODE_FMT	017000019#define NFS2MODE_DIR	004000020#define NFS2MODE_CHR	002000021#define NFS2MODE_BLK	006000022#define NFS2MODE_REG	010000023#define NFS2MODE_LNK	012000024#define NFS2MODE_SOCK	014000025#define NFS2MODE_FIFO	001000026 27 28/* NFSv2 file types - beware, these are not the same in NFSv3 */29enum nfs2_ftype {30	NF2NON = 0,31	NF2REG = 1,32	NF2DIR = 2,33	NF2BLK = 3,34	NF2CHR = 4,35	NF2LNK = 5,36	NF2SOCK = 6,37	NF2BAD = 7,38	NF2FIFO = 839};40 41struct nfs2_fh {42	char			data[NFS2_FHSIZE];43};44 45/*46 * Procedure numbers for NFSv247 */48#define NFS2_VERSION		249#define NFSPROC_NULL		050#define NFSPROC_GETATTR		151#define NFSPROC_SETATTR		252#define NFSPROC_ROOT		353#define NFSPROC_LOOKUP		454#define NFSPROC_READLINK	555#define NFSPROC_READ		656#define NFSPROC_WRITECACHE	757#define NFSPROC_WRITE		858#define NFSPROC_CREATE		959#define NFSPROC_REMOVE		1060#define NFSPROC_RENAME		1161#define NFSPROC_LINK		1262#define NFSPROC_SYMLINK		1363#define NFSPROC_MKDIR		1464#define NFSPROC_RMDIR		1565#define NFSPROC_READDIR		1666#define NFSPROC_STATFS		1767 68#endif /* _LINUX_NFS2_H */69