diff options
Diffstat (limited to 'include/linux/nfs_fs_sb.h')
-rw-r--r-- | include/linux/nfs_fs_sb.h | 32 |
1 files changed, 19 insertions, 13 deletions
diff --git a/include/linux/nfs_fs_sb.h b/include/linux/nfs_fs_sb.h index c82ee7cd6288..87694ca86914 100644 --- a/include/linux/nfs_fs_sb.h +++ b/include/linux/nfs_fs_sb.h | |||
@@ -30,6 +30,8 @@ struct nfs_client { | |||
30 | #define NFS_CS_CALLBACK 1 /* - callback started */ | 30 | #define NFS_CS_CALLBACK 1 /* - callback started */ |
31 | #define NFS_CS_IDMAP 2 /* - idmap started */ | 31 | #define NFS_CS_IDMAP 2 /* - idmap started */ |
32 | #define NFS_CS_RENEWD 3 /* - renewd started */ | 32 | #define NFS_CS_RENEWD 3 /* - renewd started */ |
33 | #define NFS_CS_STOP_RENEW 4 /* no more state to renew */ | ||
34 | #define NFS_CS_CHECK_LEASE_TIME 5 /* need to check lease time */ | ||
33 | struct sockaddr_storage cl_addr; /* server identifier */ | 35 | struct sockaddr_storage cl_addr; /* server identifier */ |
34 | size_t cl_addrlen; | 36 | size_t cl_addrlen; |
35 | char * cl_hostname; /* hostname of server */ | 37 | char * cl_hostname; /* hostname of server */ |
@@ -45,13 +47,9 @@ struct nfs_client { | |||
45 | 47 | ||
46 | #ifdef CONFIG_NFS_V4 | 48 | #ifdef CONFIG_NFS_V4 |
47 | u64 cl_clientid; /* constant */ | 49 | u64 cl_clientid; /* constant */ |
50 | nfs4_verifier cl_confirm; /* Clientid verifier */ | ||
48 | unsigned long cl_state; | 51 | unsigned long cl_state; |
49 | 52 | ||
50 | struct rb_root cl_openowner_id; | ||
51 | struct rb_root cl_lockowner_id; | ||
52 | |||
53 | struct list_head cl_delegations; | ||
54 | struct rb_root cl_state_owners; | ||
55 | spinlock_t cl_lock; | 53 | spinlock_t cl_lock; |
56 | 54 | ||
57 | unsigned long cl_lease_time; | 55 | unsigned long cl_lease_time; |
@@ -71,18 +69,16 @@ struct nfs_client { | |||
71 | */ | 69 | */ |
72 | char cl_ipaddr[48]; | 70 | char cl_ipaddr[48]; |
73 | unsigned char cl_id_uniquifier; | 71 | unsigned char cl_id_uniquifier; |
72 | u32 cl_cb_ident; /* v4.0 callback identifier */ | ||
74 | const struct nfs4_minor_version_ops *cl_mvops; | 73 | const struct nfs4_minor_version_ops *cl_mvops; |
75 | #endif /* CONFIG_NFS_V4 */ | ||
76 | 74 | ||
77 | #ifdef CONFIG_NFS_V4_1 | ||
78 | /* clientid returned from EXCHANGE_ID, used by session operations */ | ||
79 | u64 cl_ex_clid; | ||
80 | /* The sequence id to use for the next CREATE_SESSION */ | 75 | /* The sequence id to use for the next CREATE_SESSION */ |
81 | u32 cl_seqid; | 76 | u32 cl_seqid; |
82 | /* The flags used for obtaining the clientid during EXCHANGE_ID */ | 77 | /* The flags used for obtaining the clientid during EXCHANGE_ID */ |
83 | u32 cl_exchange_flags; | 78 | u32 cl_exchange_flags; |
84 | struct nfs4_session *cl_session; /* sharred session */ | 79 | struct nfs4_session *cl_session; /* sharred session */ |
85 | #endif /* CONFIG_NFS_V4_1 */ | 80 | struct list_head cl_layouts; |
81 | #endif /* CONFIG_NFS_V4 */ | ||
86 | 82 | ||
87 | #ifdef CONFIG_NFS_FSCACHE | 83 | #ifdef CONFIG_NFS_FSCACHE |
88 | struct fscache_cookie *fscache; /* client index cache cookie */ | 84 | struct fscache_cookie *fscache; /* client index cache cookie */ |
@@ -124,6 +120,7 @@ struct nfs_server { | |||
124 | 120 | ||
125 | struct nfs_fsid fsid; | 121 | struct nfs_fsid fsid; |
126 | __u64 maxfilesize; /* maximum file size */ | 122 | __u64 maxfilesize; /* maximum file size */ |
123 | struct timespec time_delta; /* smallest time granularity */ | ||
127 | unsigned long mount_time; /* when this fs was mounted */ | 124 | unsigned long mount_time; /* when this fs was mounted */ |
128 | dev_t s_dev; /* superblock dev numbers */ | 125 | dev_t s_dev; /* superblock dev numbers */ |
129 | 126 | ||
@@ -144,7 +141,15 @@ struct nfs_server { | |||
144 | u32 acl_bitmask; /* V4 bitmask representing the ACEs | 141 | u32 acl_bitmask; /* V4 bitmask representing the ACEs |
145 | that are supported on this | 142 | that are supported on this |
146 | filesystem */ | 143 | filesystem */ |
144 | struct pnfs_layoutdriver_type *pnfs_curr_ld; /* Active layout driver */ | ||
145 | struct rpc_wait_queue roc_rpcwaitq; | ||
146 | |||
147 | /* the following fields are protected by nfs_client->cl_lock */ | ||
148 | struct rb_root state_owners; | ||
149 | struct rb_root openowner_id; | ||
150 | struct rb_root lockowner_id; | ||
147 | #endif | 151 | #endif |
152 | struct list_head delegations; | ||
148 | void (*destroy)(struct nfs_server *); | 153 | void (*destroy)(struct nfs_server *); |
149 | 154 | ||
150 | atomic_t active; /* Keep trace of any activity to this server */ | 155 | atomic_t active; /* Keep trace of any activity to this server */ |
@@ -173,12 +178,13 @@ struct nfs_server { | |||
173 | #define NFS_CAP_CTIME (1U << 12) | 178 | #define NFS_CAP_CTIME (1U << 12) |
174 | #define NFS_CAP_MTIME (1U << 13) | 179 | #define NFS_CAP_MTIME (1U << 13) |
175 | #define NFS_CAP_POSIX_LOCK (1U << 14) | 180 | #define NFS_CAP_POSIX_LOCK (1U << 14) |
181 | #define NFS_CAP_UIDGID_NOMAP (1U << 15) | ||
176 | 182 | ||
177 | 183 | ||
178 | /* maximum number of slots to use */ | 184 | /* maximum number of slots to use */ |
179 | #define NFS4_MAX_SLOT_TABLE RPC_MAX_SLOT_TABLE | 185 | #define NFS4_MAX_SLOT_TABLE RPC_MAX_SLOT_TABLE |
180 | 186 | ||
181 | #if defined(CONFIG_NFS_V4_1) | 187 | #if defined(CONFIG_NFS_V4) |
182 | 188 | ||
183 | /* Sessions */ | 189 | /* Sessions */ |
184 | #define SLOT_TABLE_SZ (NFS4_MAX_SLOT_TABLE/(8*sizeof(long))) | 190 | #define SLOT_TABLE_SZ (NFS4_MAX_SLOT_TABLE/(8*sizeof(long))) |
@@ -192,6 +198,7 @@ struct nfs4_slot_table { | |||
192 | * op for dynamic resizing */ | 198 | * op for dynamic resizing */ |
193 | int target_max_slots; /* Set by CB_RECALL_SLOT as | 199 | int target_max_slots; /* Set by CB_RECALL_SLOT as |
194 | * the new max_slots */ | 200 | * the new max_slots */ |
201 | struct completion complete; | ||
195 | }; | 202 | }; |
196 | 203 | ||
197 | static inline int slot_idx(struct nfs4_slot_table *tbl, struct nfs4_slot *sp) | 204 | static inline int slot_idx(struct nfs4_slot_table *tbl, struct nfs4_slot *sp) |
@@ -208,7 +215,6 @@ struct nfs4_session { | |||
208 | unsigned long session_state; | 215 | unsigned long session_state; |
209 | u32 hash_alg; | 216 | u32 hash_alg; |
210 | u32 ssv_len; | 217 | u32 ssv_len; |
211 | struct completion complete; | ||
212 | 218 | ||
213 | /* The fore and back channel */ | 219 | /* The fore and back channel */ |
214 | struct nfs4_channel_attrs fc_attrs; | 220 | struct nfs4_channel_attrs fc_attrs; |
@@ -218,5 +224,5 @@ struct nfs4_session { | |||
218 | struct nfs_client *clp; | 224 | struct nfs_client *clp; |
219 | }; | 225 | }; |
220 | 226 | ||
221 | #endif /* CONFIG_NFS_V4_1 */ | 227 | #endif /* CONFIG_NFS_V4 */ |
222 | #endif | 228 | #endif |