aboutsummaryrefslogtreecommitdiffstats
path: root/fs/cifs/file.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/cifs/file.c')
-rw-r--r--fs/cifs/file.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/fs/cifs/file.c b/fs/cifs/file.c
index 5790fab7349b..0b32377ef8b7 100644
--- a/fs/cifs/file.c
+++ b/fs/cifs/file.c
@@ -1769,6 +1769,21 @@ static ssize_t cifs_read(struct file *file, char *read_data, size_t read_size,
1769 return total_read; 1769 return total_read;
1770} 1770}
1771 1771
1772int cifs_file_strict_mmap(struct file *file, struct vm_area_struct *vma)
1773{
1774 int rc, xid;
1775 struct inode *inode = file->f_path.dentry->d_inode;
1776
1777 xid = GetXid();
1778
1779 if (!CIFS_I(inode)->clientCanCacheRead)
1780 cifs_invalidate_mapping(inode);
1781
1782 rc = generic_file_mmap(file, vma);
1783 FreeXid(xid);
1784 return rc;
1785}
1786
1772int cifs_file_mmap(struct file *file, struct vm_area_struct *vma) 1787int cifs_file_mmap(struct file *file, struct vm_area_struct *vma)
1773{ 1788{
1774 int rc, xid; 1789 int rc, xid;