mirror of
https://github.com/adulau/aha.git
synced 2025-01-04 07:03:38 +00:00
NFS: Allow files that are open for write to invalidate caches
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
This commit is contained in:
parent
16c32b71bc
commit
bec273b491
1 changed files with 0 additions and 4 deletions
|
@ -1057,15 +1057,11 @@ int nfs_open(struct inode *inode, struct file *filp)
|
||||||
ctx->mode = filp->f_mode;
|
ctx->mode = filp->f_mode;
|
||||||
nfs_file_set_open_context(filp, ctx);
|
nfs_file_set_open_context(filp, ctx);
|
||||||
put_nfs_open_context(ctx);
|
put_nfs_open_context(ctx);
|
||||||
if ((filp->f_mode & FMODE_WRITE) != 0)
|
|
||||||
nfs_begin_data_update(inode);
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
int nfs_release(struct inode *inode, struct file *filp)
|
int nfs_release(struct inode *inode, struct file *filp)
|
||||||
{
|
{
|
||||||
if ((filp->f_mode & FMODE_WRITE) != 0)
|
|
||||||
nfs_end_data_update(inode);
|
|
||||||
nfs_file_clear_open_context(filp);
|
nfs_file_clear_open_context(filp);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue