recovery: recover from delegation stateid errors
delegation stateid arguments to DELEGRETURN and OPEN are now stateid_arg, for use with recover_stateid_delegation(). added a nfs41_delegation_state pointer to stateid_arg, for when a delegation stateid is used in the absence of nfs41_open_state (DELEGRETURN, SETATTR) recovery during a call to nfs41_delegation_to_open() requires special attention; recover_stateid_delegation() has to handle the case where recover_open() already reclaimed the open stateid. it does this by returning BAD_STATEID instead of retrying the OPEN (which would generate yet another open stateid) Signed-off-by: Casey Bodley <cbodley@citi.umich.edu>
This commit is contained in:
parent
4f47ae9a37
commit
d44470c877
7 changed files with 104 additions and 21 deletions
|
|
@ -287,6 +287,7 @@ typedef struct __stateid_arg {
|
|||
stateid4 stateid;
|
||||
enum stateid_type type;
|
||||
nfs41_open_state *open;
|
||||
nfs41_delegation_state *delegation;
|
||||
} stateid_arg;
|
||||
|
||||
|
||||
|
|
@ -374,7 +375,7 @@ typedef struct __nfs41_create_res {
|
|||
|
||||
/* OP_DELEGRETURN */
|
||||
typedef struct __nfs41_delegreturn_args {
|
||||
stateid4 *stateid;
|
||||
stateid_arg *stateid;
|
||||
} nfs41_delegreturn_args;
|
||||
|
||||
typedef struct __nfs41_delegreturn_res {
|
||||
|
|
@ -624,12 +625,12 @@ typedef struct __open_claim4 {
|
|||
} prev;
|
||||
/* case CLAIM_DELEGATE_CUR: */
|
||||
struct __open_claim_deleg_cur {
|
||||
stateid4 *delegate_stateid;
|
||||
stateid_arg *delegate_stateid;
|
||||
nfs41_component *name;
|
||||
} deleg_cur;
|
||||
/* case CLAIM_DELEG_CUR_FH: */
|
||||
struct __open_claim_deleg_cur_fh {
|
||||
stateid4 *delegate_stateid;
|
||||
stateid_arg *delegate_stateid;
|
||||
} deleg_cur_fh;
|
||||
/* case CLAIM_DELEGATE_PREV: */
|
||||
struct __open_claim_deleg_prev {
|
||||
|
|
@ -1154,7 +1155,7 @@ int nfs41_access(
|
|||
int nfs41_delegreturn(
|
||||
IN nfs41_session *session,
|
||||
IN nfs41_path_fh *file,
|
||||
IN stateid4 *stateid,
|
||||
IN stateid_arg *stateid,
|
||||
IN bool_t try_recovery);
|
||||
|
||||
enum nfsstat4 nfs41_fs_locations(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue