diff options
author | Pavel Shilovsky <piastryyy@gmail.com> | 2010-12-12 05:11:13 -0500 |
---|---|---|
committer | Steve French <sfrench@us.ibm.com> | 2011-01-20 16:42:21 -0500 |
commit | 8be7e6ba142423e6ad98fed293c96f196f685229 (patch) | |
tree | 25bd7ce4aed4740082f0a472a8eed35127d9d61e /fs/cifs/cifsfs.h | |
parent | 4f8ba8a0c095933dd54a2c281750c8a85b329b26 (diff) |
CIFS: Implement cifs_strict_fsync
Invalidate inode mapping if we don't have at least Level II oplock in
cifs_strict_fsync. Also remove filemap_write_and_wait call from cifs_fsync
because it is previously called from vfs_fsync_range. Add file operations'
structures for strict cache mode.
Reviewed-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Pavel Shilovsky <piastryyy@gmail.com>
Signed-off-by: Steve French <sfrench@us.ibm.com>
Diffstat (limited to 'fs/cifs/cifsfs.h')
-rw-r--r-- | fs/cifs/cifsfs.h | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/fs/cifs/cifsfs.h b/fs/cifs/cifsfs.h index 4739a531cded..10c4303c282d 100644 --- a/fs/cifs/cifsfs.h +++ b/fs/cifs/cifsfs.h | |||
@@ -61,6 +61,7 @@ extern int cifs_rename(struct inode *, struct dentry *, struct inode *, | |||
61 | struct dentry *); | 61 | struct dentry *); |
62 | extern int cifs_revalidate_file(struct file *filp); | 62 | extern int cifs_revalidate_file(struct file *filp); |
63 | extern int cifs_revalidate_dentry(struct dentry *); | 63 | extern int cifs_revalidate_dentry(struct dentry *); |
64 | extern void cifs_invalidate_mapping(struct inode *inode); | ||
64 | extern int cifs_getattr(struct vfsmount *, struct dentry *, struct kstat *); | 65 | extern int cifs_getattr(struct vfsmount *, struct dentry *, struct kstat *); |
65 | extern int cifs_setattr(struct dentry *, struct iattr *); | 66 | extern int cifs_setattr(struct dentry *, struct iattr *); |
66 | 67 | ||
@@ -72,8 +73,10 @@ extern const struct inode_operations cifs_dfs_referral_inode_operations; | |||
72 | /* Functions related to files and directories */ | 73 | /* Functions related to files and directories */ |
73 | extern const struct file_operations cifs_file_ops; | 74 | extern const struct file_operations cifs_file_ops; |
74 | extern const struct file_operations cifs_file_direct_ops; /* if directio mnt */ | 75 | extern const struct file_operations cifs_file_direct_ops; /* if directio mnt */ |
75 | extern const struct file_operations cifs_file_nobrl_ops; | 76 | extern const struct file_operations cifs_file_strict_ops; /* if strictio mnt */ |
76 | extern const struct file_operations cifs_file_direct_nobrl_ops; /* no brlocks */ | 77 | extern const struct file_operations cifs_file_nobrl_ops; /* no brlocks */ |
78 | extern const struct file_operations cifs_file_direct_nobrl_ops; | ||
79 | extern const struct file_operations cifs_file_strict_nobrl_ops; | ||
77 | extern int cifs_open(struct inode *inode, struct file *file); | 80 | extern int cifs_open(struct inode *inode, struct file *file); |
78 | extern int cifs_close(struct inode *inode, struct file *file); | 81 | extern int cifs_close(struct inode *inode, struct file *file); |
79 | extern int cifs_closedir(struct inode *inode, struct file *file); | 82 | extern int cifs_closedir(struct inode *inode, struct file *file); |
@@ -83,6 +86,7 @@ extern ssize_t cifs_user_write(struct file *file, const char __user *write_data, | |||
83 | size_t write_size, loff_t *poffset); | 86 | size_t write_size, loff_t *poffset); |
84 | extern int cifs_lock(struct file *, int, struct file_lock *); | 87 | extern int cifs_lock(struct file *, int, struct file_lock *); |
85 | extern int cifs_fsync(struct file *, int); | 88 | extern int cifs_fsync(struct file *, int); |
89 | extern int cifs_strict_fsync(struct file *, int); | ||
86 | extern int cifs_flush(struct file *, fl_owner_t id); | 90 | extern int cifs_flush(struct file *, fl_owner_t id); |
87 | extern int cifs_file_mmap(struct file * , struct vm_area_struct *); | 91 | extern int cifs_file_mmap(struct file * , struct vm_area_struct *); |
88 | extern const struct file_operations cifs_dir_ops; | 92 | extern const struct file_operations cifs_dir_ops; |