Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 223083
b: refs/heads/master
c: c1ac3ff
h: refs/heads/master
i:
  223081: 3f29d91
  223079: f0de87f
v: v3
  • Loading branch information
Neil Brown authored and J. Bruce Fields committed Dec 8, 2010
1 parent fb7147c commit ebf81a0
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 14 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: ed2849d3ecfa339435818eeff28f6c3424300cec
refs/heads/master: c1ac3ffcd0bc7e9617f62be8c7043d53ab84deac
6 changes: 4 additions & 2 deletions trunk/fs/nfsd/nfs3xdr.c
Original file line number Diff line number Diff line change
Expand Up @@ -260,9 +260,11 @@ void fill_post_wcc(struct svc_fh *fhp)
err = vfs_getattr(fhp->fh_export->ex_path.mnt, fhp->fh_dentry,
&fhp->fh_post_attr);
fhp->fh_post_change = fhp->fh_dentry->d_inode->i_version;
if (err)
if (err) {
fhp->fh_post_saved = 0;
else
/* Grab the ctime anyway - set_change_info might use it */
fhp->fh_post_attr.ctime = fhp->fh_dentry->d_inode->i_ctime;
} else
fhp->fh_post_saved = 1;
}

Expand Down
21 changes: 10 additions & 11 deletions trunk/fs/nfsd/xdr4.h
Original file line number Diff line number Diff line change
Expand Up @@ -484,18 +484,17 @@ static inline bool nfsd4_not_cached(struct nfsd4_compoundres *resp)
static inline void
set_change_info(struct nfsd4_change_info *cinfo, struct svc_fh *fhp)
{
BUG_ON(!fhp->fh_pre_saved || !fhp->fh_post_saved);
cinfo->atomic = 1;
BUG_ON(!fhp->fh_pre_saved);
cinfo->atomic = fhp->fh_post_saved;
cinfo->change_supported = IS_I_VERSION(fhp->fh_dentry->d_inode);
if (cinfo->change_supported) {
cinfo->before_change = fhp->fh_pre_change;
cinfo->after_change = fhp->fh_post_change;
} else {
cinfo->before_ctime_sec = fhp->fh_pre_ctime.tv_sec;
cinfo->before_ctime_nsec = fhp->fh_pre_ctime.tv_nsec;
cinfo->after_ctime_sec = fhp->fh_post_attr.ctime.tv_sec;
cinfo->after_ctime_nsec = fhp->fh_post_attr.ctime.tv_nsec;
}

cinfo->before_change = fhp->fh_pre_change;
cinfo->after_change = fhp->fh_post_change;
cinfo->before_ctime_sec = fhp->fh_pre_ctime.tv_sec;
cinfo->before_ctime_nsec = fhp->fh_pre_ctime.tv_nsec;
cinfo->after_ctime_sec = fhp->fh_post_attr.ctime.tv_sec;
cinfo->after_ctime_nsec = fhp->fh_post_attr.ctime.tv_nsec;

}

int nfs4svc_encode_voidres(struct svc_rqst *, __be32 *, void *);
Expand Down

0 comments on commit ebf81a0

Please sign in to comment.