blob: 4cbca123f5df809ace602988b67281c8547320be [file] [log] [blame]
Ben Cheng655a7c02013-10-16 16:09:24 -07001/****************************************************************************
2 ****************************************************************************
3 ***
4 *** This header was automatically generated from a Linux kernel header
5 *** of the same name, to make information necessary for userspace to
6 *** call into the kernel available to libc. It contains only constants,
7 *** structures, and macros generated from the original header, and thus,
8 *** contains no copyrightable information.
9 ***
10 *** To edit the content of this header, modify the corresponding
11 *** source file (e.g. under external/kernel-headers/original/) then
12 *** run bionic/libc/kernel/tools/update_all.py
13 ***
14 *** Any manual change here will be lost the next time this script will
15 *** be run. You've been warned!
16 ***
17 ****************************************************************************
18 ****************************************************************************/
19#ifndef _LINUX_NFS2_H
20#define _LINUX_NFS2_H
21#define NFS2_PORT 2049
22#define NFS2_MAXDATA 8192
Ben Cheng655a7c02013-10-16 16:09:24 -070023#define NFS2_MAXPATHLEN 1024
24#define NFS2_MAXNAMLEN 255
25#define NFS2_MAXGROUPS 16
26#define NFS2_FHSIZE 32
Ben Cheng655a7c02013-10-16 16:09:24 -070027#define NFS2_COOKIESIZE 4
Tao Baod7db5942015-01-28 10:07:51 -080028#define NFS2_FIFO_DEV (- 1)
Ben Cheng655a7c02013-10-16 16:09:24 -070029#define NFS2MODE_FMT 0170000
30#define NFS2MODE_DIR 0040000
Ben Cheng655a7c02013-10-16 16:09:24 -070031#define NFS2MODE_CHR 0020000
32#define NFS2MODE_BLK 0060000
33#define NFS2MODE_REG 0100000
34#define NFS2MODE_LNK 0120000
Ben Cheng655a7c02013-10-16 16:09:24 -070035#define NFS2MODE_SOCK 0140000
36#define NFS2MODE_FIFO 0010000
37enum nfs2_ftype {
Tao Baod7db5942015-01-28 10:07:51 -080038 NF2NON = 0,
Tao Baod7db5942015-01-28 10:07:51 -080039 NF2REG = 1,
40 NF2DIR = 2,
41 NF2BLK = 3,
42 NF2CHR = 4,
Tao Baod7db5942015-01-28 10:07:51 -080043 NF2LNK = 5,
44 NF2SOCK = 6,
45 NF2BAD = 7,
46 NF2FIFO = 8
Ben Cheng655a7c02013-10-16 16:09:24 -070047};
48struct nfs2_fh {
Tao Baod7db5942015-01-28 10:07:51 -080049 char data[NFS2_FHSIZE];
Ben Cheng655a7c02013-10-16 16:09:24 -070050};
Ben Cheng655a7c02013-10-16 16:09:24 -070051#define NFS2_VERSION 2
52#define NFSPROC_NULL 0
53#define NFSPROC_GETATTR 1
54#define NFSPROC_SETATTR 2
Ben Cheng655a7c02013-10-16 16:09:24 -070055#define NFSPROC_ROOT 3
56#define NFSPROC_LOOKUP 4
57#define NFSPROC_READLINK 5
58#define NFSPROC_READ 6
Ben Cheng655a7c02013-10-16 16:09:24 -070059#define NFSPROC_WRITECACHE 7
60#define NFSPROC_WRITE 8
61#define NFSPROC_CREATE 9
62#define NFSPROC_REMOVE 10
Ben Cheng655a7c02013-10-16 16:09:24 -070063#define NFSPROC_RENAME 11
64#define NFSPROC_LINK 12
65#define NFSPROC_SYMLINK 13
66#define NFSPROC_MKDIR 14
Ben Cheng655a7c02013-10-16 16:09:24 -070067#define NFSPROC_RMDIR 15
68#define NFSPROC_READDIR 16
69#define NFSPROC_STATFS 17
70#endif