aboutsummaryrefslogtreecommitdiffstats
path: root/fs/cifs/cifsfs.c
diff options
context:
space:
mode:
authorPavel Shilovsky <piastry@etersoft.ru>2011-03-10 02:11:05 -0500
committerSteve French <sfrench@us.ibm.com>2011-05-19 10:10:51 -0400
commit0b81c1c405c063f3ecea66c2f5e9c3aefc5359c8 (patch)
treeb284b86c0e17c24affff9f6d1e1f2ab2d217021f /fs/cifs/cifsfs.c
parentbe8e3b0044a68e1f1002c432f6b40d290cf0701d (diff)
CIFS: directio read/write cleanups
Recently introduced strictcache mode brought a new code that can be efficiently used by directio part. That's let us add vectored operations and break unnecessary cifs_user_read and cifs_user_write. Signed-off-by: Pavel Shilovsky <piastry@etersoft.ru> Reviewed-by: Jeff Layton <jlayton@redhat.com> Signed-off-by: Steve French <sfrench@us.ibm.com>
Diffstat (limited to 'fs/cifs/cifsfs.c')
-rw-r--r--fs/cifs/cifsfs.c18
1 files changed, 10 insertions, 8 deletions
diff --git a/fs/cifs/cifsfs.c b/fs/cifs/cifsfs.c
index 6c1d738418f1..f736d8a2e771 100644
--- a/fs/cifs/cifsfs.c
+++ b/fs/cifs/cifsfs.c
@@ -760,10 +760,11 @@ const struct file_operations cifs_file_strict_ops = {
760}; 760};
761 761
762const struct file_operations cifs_file_direct_ops = { 762const struct file_operations cifs_file_direct_ops = {
763 /* no aio, no readv - 763 /* BB reevaluate whether they can be done with directio, no cache */
764 BB reevaluate whether they can be done with directio, no cache */ 764 .read = do_sync_read,
765 .read = cifs_user_read, 765 .write = do_sync_write,
766 .write = cifs_user_write, 766 .aio_read = cifs_user_readv,
767 .aio_write = cifs_user_writev,
767 .open = cifs_open, 768 .open = cifs_open,
768 .release = cifs_close, 769 .release = cifs_close,
769 .lock = cifs_lock, 770 .lock = cifs_lock,
@@ -815,10 +816,11 @@ const struct file_operations cifs_file_strict_nobrl_ops = {
815}; 816};
816 817
817const struct file_operations cifs_file_direct_nobrl_ops = { 818const struct file_operations cifs_file_direct_nobrl_ops = {
818 /* no mmap, no aio, no readv - 819 /* BB reevaluate whether they can be done with directio, no cache */
819 BB reevaluate whether they can be done with directio, no cache */ 820 .read = do_sync_read,
820 .read = cifs_user_read, 821 .write = do_sync_write,
821 .write = cifs_user_write, 822 .aio_read = cifs_user_readv,
823 .aio_write = cifs_user_writev,
822 .open = cifs_open, 824 .open = cifs_open,
823 .release = cifs_close, 825 .release = cifs_close,
824 .fsync = cifs_fsync, 826 .fsync = cifs_fsync,