ReactOS 0.4.15-dev-7788-g1ad9096
nfs41_types.h
Go to the documentation of this file.
1/* NFSv4.1 client for Windows
2 * Copyright © 2012 The Regents of the University of Michigan
3 *
4 * Olga Kornievskaia <aglo@umich.edu>
5 * Casey Bodley <cbodley@umich.edu>
6 *
7 * This library is free software; you can redistribute it and/or modify it
8 * under the terms of the GNU Lesser General Public License as published by
9 * the Free Software Foundation; either version 2.1 of the License, or (at
10 * your option) any later version.
11 *
12 * This library is distributed in the hope that it will be useful, but
13 * without any warranty; without even the implied warranty of merchantability
14 * or fitness for a particular purpose. See the GNU Lesser General Public
15 * License for more details.
16 *
17 * You should have received a copy of the GNU Lesser General Public License
18 * along with this library; if not, write to the Free Software Foundation,
19 * Inc., 51 Franklin Street, Fifth Floor, Boston, MA
20 */
21
22#ifndef __NFS41_DAEMON_TYPES_H__
23#define __NFS41_DAEMON_TYPES_H__
24
25#include "wintirpc.h"
26#include "rpc/xdr.h"
27#include "nfs41_const.h"
28
29typedef char* caddr_t;
30
31static const int64_t NFS4_INT64_MAX = 0x7fffffffffffffff;
32static const uint64_t NFS4_UINT64_MAX = 0xffffffffffffffff;
33static const int32_t NFS4_INT32_MAX = 0x7fffffff;
34static const uint32_t NFS4_UINT32_MAX = 0xffffffff;
35
36static const uint64_t NFS4_MAXFILELEN = 0xffffffffffffffff;
37static const uint64_t NFS4_MAXFILEOFF = 0xfffffffffffffffe;
38
39
40/* common nfs types */
41typedef struct __nfs41_abs_path {
43 unsigned short len;
44 SRWLOCK lock;
46
47typedef struct __nfs41_component {
48 const char *name;
49 unsigned short len;
51
52typedef struct __nfs41_fh {
53 unsigned char fh[NFS4_FHSIZE];
58
59typedef struct __nfs41_path_fh {
64
65typedef struct __nfs41_fsid {
69
70typedef struct __nfs41_readdir_cookie {
72 unsigned char verf[NFS4_VERIFIER_SIZE];
74
75typedef struct __nfs41_write_verf {
76 unsigned char verf[NFS4_VERIFIER_SIZE];
78#ifdef __REACTOS__
80#else
82#endif
84
85typedef struct __netaddr4 {
89
90typedef struct __multi_addr4 {
94
95typedef struct __bitmap4 {
99
100typedef struct __nfstime4 {
104
105typedef struct __client_owner4 {
110
111typedef struct __server_owner4 {
116
117typedef struct __state_owner4 {
119 unsigned char owner[NFS4_OPAQUE_LIMIT];
121
122typedef struct __nfs_impl_id4 {
124 unsigned char *nii_domain;
126 unsigned char *nii_name;
129
130typedef struct __nfsace4 {
136
137typedef struct __nfsacl41 {
142
143typedef struct __stateid4 {
145 unsigned char other[NFS4_STATEID_OTHER];
147
148typedef struct __open_delegation4 {
151#ifdef __REACTOS__
153#else
155#endif
158
159typedef struct __fattr4 {
164
165typedef struct __change_info4 {
170
171typedef struct __fs_location_server {
172 /* 'address' represents one of a traditional DNS host name,
173 * IPv4 address, IPv6 address, or a zero-length string */
176
177typedef struct __fs_location4 {
178 nfs41_abs_path path; /* path to fs from referred server's root */
182
183typedef struct __fs_locations4 {
184 nfs41_abs_path path; /* path to fs from referring server's root */
188
189enum {
194
197typedef struct __threshold_item4 {
201
202#define MAX_MDSTHRESHOLD_ITEMS 1
203typedef struct __mdsthreshold4 {
207
208typedef struct __nfs41_file_info {
215 nfstime4 *time_delta; /* XXX: per-fs */
217 bitmap4 *supported_attrs; /* XXX: per-fs */
218 bitmap4 *suppattr_exclcreat; /* XXX: per-fs */
219 uint64_t maxread; /* XXX: per-fs */
220 uint64_t maxwrite; /* XXX: per-fs */
224 uint64_t space_avail; /* XXX: per-fs */
225 uint64_t space_free; /* XXX: per-fs */
226 uint64_t space_total; /* XXX: per-fs */
232 fs_locations4 *fs_locations; /* XXX: per-fs */
233 uint32_t lease_time; /* XXX: per-server */
234 uint32_t fs_layout_types; /* pnfs, XXX: per-fs */
238 bool_t cansettime; /* XXX: per-fs */
244 char *owner;
248
249#endif /* !__NFS41_DAEMON_TYPES_H__ */
int32_t bool_t
Definition: types.h:101
INT32 int32_t
Definition: types.h:71
UINT32 uint32_t
Definition: types.h:75
UINT64 uint64_t
Definition: types.h:77
INT64 int64_t
Definition: types.h:72
GLuint address
Definition: glext.h:9393
#define NFS41_MAX_PATH_LEN
Definition: nfs41_const.h:46
#define NFS41_ADDRS_PER_SERVER
Definition: nfs41_const.h:49
#define NFS41_HOSTNAME_LEN
Definition: nfs41_const.h:48
#define NFS41_UNIVERSAL_ADDR_LEN
Definition: nfs41_const.h:53
#define NFS4_STATEID_OTHER
Definition: nfs41_const.h:33
#define NFS4_FHSIZE
Definition: nfs41_const.h:29
#define NFS4_VERIFIER_SIZE
Definition: nfs41_const.h:30
#define NFS41_NETWORK_ID_LEN
Definition: nfs41_const.h:56
#define NFS4_OPAQUE_LIMIT
Definition: nfs41_const.h:31
open_delegation_type4
Definition: nfs41_ops.h:585
stable_how4
Definition: nfs41_ops.h:835
struct __nfs41_write_verf nfs41_write_verf
struct __nfs41_readdir_cookie nfs41_readdir_cookie
static const int32_t NFS4_INT32_MAX
Definition: nfs41_types.h:33
struct __nfs41_fsid nfs41_fsid
struct __nfsacl41 nfsacl41
struct __stateid4 stateid4
static const uint64_t NFS4_MAXFILEOFF
Definition: nfs41_types.h:37
struct __nfs41_component nfs41_component
struct __nfs41_file_info nfs41_file_info
struct __change_info4 change_info4
struct __threshold_item4 threshold_item4
static const int64_t NFS4_INT64_MAX
Definition: nfs41_types.h:31
struct __fs_location_server fs_location_server
struct __nfstime4 nfstime4
struct __state_owner4 state_owner4
struct __open_delegation4 open_delegation4
#define MAX_MDSTHRESHOLD_ITEMS
Definition: nfs41_types.h:202
@ MDSTHRESH_READ
Definition: nfs41_types.h:190
@ MDSTHRESH_READ_IO
Definition: nfs41_types.h:192
@ MDSTHRESH_WRITE
Definition: nfs41_types.h:191
@ MDSTHRESH_WRITE_IO
Definition: nfs41_types.h:193
@ MAX_MDSTHRESH_HINTS
Definition: nfs41_types.h:195
static const uint64_t NFS4_UINT64_MAX
Definition: nfs41_types.h:32
struct __nfs41_path_fh nfs41_path_fh
char * caddr_t
Definition: nfs41_types.h:29
static const uint64_t NFS4_MAXFILELEN
Definition: nfs41_types.h:36
struct __bitmap4 bitmap4
struct __fs_locations4 fs_locations4
struct __fs_location4 fs_location4
struct __nfs_impl_id4 nfs_impl_id4
struct __fattr4 fattr4
struct __client_owner4 client_owner4
struct __mdsthreshold4 mdsthreshold4
struct __netaddr4 netaddr4
struct __nfs41_fh nfs41_fh
struct __server_owner4 server_owner4
static const uint32_t NFS4_UINT32_MAX
Definition: nfs41_types.h:34
struct __nfs41_abs_path nfs41_abs_path
struct __nfsace4 nfsace4
struct __multi_addr4 multi_addr4
uint32_t count
Definition: nfs41_types.h:96
uint32_t arr[3]
Definition: nfs41_types.h:97
uint64_t after
Definition: nfs41_types.h:168
uint64_t before
Definition: nfs41_types.h:167
unsigned char co_ownerid[NFS4_OPAQUE_LIMIT]
Definition: nfs41_types.h:108
uint32_t co_ownerid_len
Definition: nfs41_types.h:107
unsigned char co_verifier[NFS4_VERIFIER_SIZE]
Definition: nfs41_types.h:106
uint32_t attr_vals_len
Definition: nfs41_types.h:161
unsigned char attr_vals[NFS4_OPAQUE_LIMIT]
Definition: nfs41_types.h:162
bitmap4 attrmask
Definition: nfs41_types.h:160
nfs41_abs_path path
Definition: nfs41_types.h:178
uint32_t server_count
Definition: nfs41_types.h:180
fs_location_server * servers
Definition: nfs41_types.h:179
fs_location4 * locations
Definition: nfs41_types.h:185
nfs41_abs_path path
Definition: nfs41_types.h:184
uint32_t location_count
Definition: nfs41_types.h:186
uint32_t count
Definition: nfs41_types.h:204
threshold_item4 items[MAX_MDSTHRESHOLD_ITEMS]
Definition: nfs41_types.h:205
netaddr4 arr[NFS41_ADDRS_PER_SERVER]
Definition: nfs41_types.h:91
uint32_t count
Definition: nfs41_types.h:92
char netid[NFS41_NETWORK_ID_LEN+1]
Definition: nfs41_types.h:86
char uaddr[NFS41_UNIVERSAL_ADDR_LEN+1]
Definition: nfs41_types.h:87
unsigned short len
Definition: nfs41_types.h:43
const char * name
Definition: nfs41_types.h:48
unsigned short len
Definition: nfs41_types.h:49
struct __nfs41_superblock * superblock
Definition: nfs41_types.h:56
uint32_t len
Definition: nfs41_types.h:54
unsigned char fh[NFS4_FHSIZE]
Definition: nfs41_types.h:53
uint64_t fileid
Definition: nfs41_types.h:55
nfsacl41 * acl
Definition: nfs41_types.h:214
fs_locations4 * fs_locations
Definition: nfs41_types.h:232
nfstime4 time_modify
Definition: nfs41_types.h:213
uint64_t space_total
Definition: nfs41_types.h:226
nfstime4 time_create
Definition: nfs41_types.h:212
nfs41_fsid fsid
Definition: nfs41_types.h:209
uint32_t fs_layout_types
Definition: nfs41_types.h:234
bitmap4 * suppattr_exclcreat
Definition: nfs41_types.h:218
bitmap4 * supported_attrs
Definition: nfs41_types.h:217
uint32_t lease_time
Definition: nfs41_types.h:233
bool_t case_insensitive
Definition: nfs41_types.h:239
bool_t symlink_support
Definition: nfs41_types.h:242
mdsthreshold4 mdsthreshold
Definition: nfs41_types.h:210
uint32_t rdattr_error
Definition: nfs41_types.h:229
nfstime4 time_access
Definition: nfs41_types.h:211
nfstime4 * time_delta
Definition: nfs41_types.h:215
uint32_t aclsupport
Definition: nfs41_types.h:246
uint32_t mode_mask
Definition: nfs41_types.h:231
bool_t case_preserving
Definition: nfs41_types.h:240
uint64_t space_avail
Definition: nfs41_types.h:224
uint64_t space_free
Definition: nfs41_types.h:225
uint64_t major
Definition: nfs41_types.h:66
uint64_t minor
Definition: nfs41_types.h:67
nfs41_component name
Definition: nfs41_types.h:61
nfs41_abs_path * path
Definition: nfs41_types.h:60
enum stable_how4 committed
Definition: nfs41_types.h:81
unsigned char verf[NFS4_VERIFIER_SIZE]
Definition: nfs41_types.h:76
unsigned char expected[NFS4_VERIFIER_SIZE]
Definition: nfs41_types.h:77
nfstime4 nii_date
Definition: nfs41_types.h:127
unsigned char * nii_name
Definition: nfs41_types.h:126
uint32_t nii_name_len
Definition: nfs41_types.h:125
uint32_t nii_domain_len
Definition: nfs41_types.h:123
unsigned char * nii_domain
Definition: nfs41_types.h:124
uint32_t acemask
Definition: nfs41_types.h:133
uint32_t aceflag
Definition: nfs41_types.h:132
char who[NFS4_OPAQUE_LIMIT]
Definition: nfs41_types.h:134
uint32_t acetype
Definition: nfs41_types.h:131
nfsace4 * aces
Definition: nfs41_types.h:139
uint32_t count
Definition: nfs41_types.h:140
uint32_t flag
Definition: nfs41_types.h:138
int64_t seconds
Definition: nfs41_types.h:101
uint32_t nseconds
Definition: nfs41_types.h:102
enum open_delegation_type4 type
Definition: nfs41_types.h:154
uint64_t so_minor_id
Definition: nfs41_types.h:112
uint32_t so_major_id_len
Definition: nfs41_types.h:113
char so_major_id[NFS4_OPAQUE_LIMIT]
Definition: nfs41_types.h:114
unsigned char owner[NFS4_OPAQUE_LIMIT]
Definition: nfs41_types.h:119
uint32_t owner_len
Definition: nfs41_types.h:118
unsigned char other[NFS4_STATEID_OTHER]
Definition: nfs41_types.h:145
uint32_t seqid
Definition: nfs41_types.h:144
uint64_t hints[MAX_MDSTHRESH_HINTS]
Definition: nfs41_types.h:199