diff options
Diffstat (limited to 'fs/nfsd/state.h')
-rw-r--r-- | fs/nfsd/state.h | 19 |
1 files changed, 17 insertions, 2 deletions
diff --git a/fs/nfsd/state.h b/fs/nfsd/state.h index 39adc27b0685..2d31224b07bf 100644 --- a/fs/nfsd/state.h +++ b/fs/nfsd/state.h | |||
@@ -68,10 +68,12 @@ typedef struct { | |||
68 | struct nfsd4_callback { | 68 | struct nfsd4_callback { |
69 | void *cb_op; | 69 | void *cb_op; |
70 | struct nfs4_client *cb_clp; | 70 | struct nfs4_client *cb_clp; |
71 | struct list_head cb_per_client; | ||
71 | u32 cb_minorversion; | 72 | u32 cb_minorversion; |
72 | struct rpc_message cb_msg; | 73 | struct rpc_message cb_msg; |
73 | const struct rpc_call_ops *cb_ops; | 74 | const struct rpc_call_ops *cb_ops; |
74 | struct work_struct cb_work; | 75 | struct work_struct cb_work; |
76 | bool cb_done; | ||
75 | }; | 77 | }; |
76 | 78 | ||
77 | struct nfs4_delegation { | 79 | struct nfs4_delegation { |
@@ -81,7 +83,6 @@ struct nfs4_delegation { | |||
81 | atomic_t dl_count; /* ref count */ | 83 | atomic_t dl_count; /* ref count */ |
82 | struct nfs4_client *dl_client; | 84 | struct nfs4_client *dl_client; |
83 | struct nfs4_file *dl_file; | 85 | struct nfs4_file *dl_file; |
84 | struct file_lock *dl_flock; | ||
85 | u32 dl_type; | 86 | u32 dl_type; |
86 | time_t dl_time; | 87 | time_t dl_time; |
87 | /* For recall: */ | 88 | /* For recall: */ |
@@ -95,6 +96,7 @@ struct nfs4_delegation { | |||
95 | struct nfs4_cb_conn { | 96 | struct nfs4_cb_conn { |
96 | /* SETCLIENTID info */ | 97 | /* SETCLIENTID info */ |
97 | struct sockaddr_storage cb_addr; | 98 | struct sockaddr_storage cb_addr; |
99 | struct sockaddr_storage cb_saddr; | ||
98 | size_t cb_addrlen; | 100 | size_t cb_addrlen; |
99 | u32 cb_prog; /* used only in 4.0 case; | 101 | u32 cb_prog; /* used only in 4.0 case; |
100 | per-session otherwise */ | 102 | per-session otherwise */ |
@@ -146,6 +148,11 @@ struct nfsd4_create_session { | |||
146 | u32 gid; | 148 | u32 gid; |
147 | }; | 149 | }; |
148 | 150 | ||
151 | struct nfsd4_bind_conn_to_session { | ||
152 | struct nfs4_sessionid sessionid; | ||
153 | u32 dir; | ||
154 | }; | ||
155 | |||
149 | /* The single slot clientid cache structure */ | 156 | /* The single slot clientid cache structure */ |
150 | struct nfsd4_clid_slot { | 157 | struct nfsd4_clid_slot { |
151 | u32 sl_seqid; | 158 | u32 sl_seqid; |
@@ -235,9 +242,13 @@ struct nfs4_client { | |||
235 | unsigned long cl_cb_flags; | 242 | unsigned long cl_cb_flags; |
236 | struct rpc_clnt *cl_cb_client; | 243 | struct rpc_clnt *cl_cb_client; |
237 | u32 cl_cb_ident; | 244 | u32 cl_cb_ident; |
238 | atomic_t cl_cb_set; | 245 | #define NFSD4_CB_UP 0 |
246 | #define NFSD4_CB_UNKNOWN 1 | ||
247 | #define NFSD4_CB_DOWN 2 | ||
248 | int cl_cb_state; | ||
239 | struct nfsd4_callback cl_cb_null; | 249 | struct nfsd4_callback cl_cb_null; |
240 | struct nfsd4_session *cl_cb_session; | 250 | struct nfsd4_session *cl_cb_session; |
251 | struct list_head cl_callbacks; /* list of in-progress callbacks */ | ||
241 | 252 | ||
242 | /* for all client information that callback code might need: */ | 253 | /* for all client information that callback code might need: */ |
243 | spinlock_t cl_lock; | 254 | spinlock_t cl_lock; |
@@ -366,6 +377,9 @@ struct nfs4_file { | |||
366 | */ | 377 | */ |
367 | atomic_t fi_readers; | 378 | atomic_t fi_readers; |
368 | atomic_t fi_writers; | 379 | atomic_t fi_writers; |
380 | struct file *fi_deleg_file; | ||
381 | struct file_lock *fi_lease; | ||
382 | atomic_t fi_delegees; | ||
369 | struct inode *fi_inode; | 383 | struct inode *fi_inode; |
370 | u32 fi_id; /* used with stateowner->so_id | 384 | u32 fi_id; /* used with stateowner->so_id |
371 | * for stateid_hashtbl hash */ | 385 | * for stateid_hashtbl hash */ |
@@ -454,6 +468,7 @@ extern __be32 nfs4_check_open_reclaim(clientid_t *clid); | |||
454 | extern void nfs4_free_stateowner(struct kref *kref); | 468 | extern void nfs4_free_stateowner(struct kref *kref); |
455 | extern int set_callback_cred(void); | 469 | extern int set_callback_cred(void); |
456 | extern void nfsd4_probe_callback(struct nfs4_client *clp); | 470 | extern void nfsd4_probe_callback(struct nfs4_client *clp); |
471 | extern void nfsd4_probe_callback_sync(struct nfs4_client *clp); | ||
457 | extern void nfsd4_change_callback(struct nfs4_client *clp, struct nfs4_cb_conn *); | 472 | extern void nfsd4_change_callback(struct nfs4_client *clp, struct nfs4_cb_conn *); |
458 | extern void nfsd4_do_callback_rpc(struct work_struct *); | 473 | extern void nfsd4_do_callback_rpc(struct work_struct *); |
459 | extern void nfsd4_cb_recall(struct nfs4_delegation *dp); | 474 | extern void nfsd4_cb_recall(struct nfs4_delegation *dp); |