aboutsummaryrefslogtreecommitdiffstats
path: root/fs/cifs/cifsfs.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/cifs/cifsfs.c')
-rw-r--r--fs/cifs/cifsfs.c25
1 files changed, 11 insertions, 14 deletions
diff --git a/fs/cifs/cifsfs.c b/fs/cifs/cifsfs.c
index e7931cc55d0c..de7f9168a118 100644
--- a/fs/cifs/cifsfs.c
+++ b/fs/cifs/cifsfs.c
@@ -54,7 +54,6 @@
54#endif 54#endif
55 55
56int cifsFYI = 0; 56int cifsFYI = 0;
57int cifsERROR = 1;
58int traceSMB = 0; 57int traceSMB = 0;
59bool enable_oplocks = true; 58bool enable_oplocks = true;
60unsigned int linuxExtEnabled = 1; 59unsigned int linuxExtEnabled = 1;
@@ -64,24 +63,23 @@ unsigned int global_secflags = CIFSSEC_DEF;
64unsigned int sign_CIFS_PDUs = 1; 63unsigned int sign_CIFS_PDUs = 1;
65static const struct super_operations cifs_super_ops; 64static const struct super_operations cifs_super_ops;
66unsigned int CIFSMaxBufSize = CIFS_MAX_MSGSIZE; 65unsigned int CIFSMaxBufSize = CIFS_MAX_MSGSIZE;
67module_param(CIFSMaxBufSize, int, 0); 66module_param(CIFSMaxBufSize, uint, 0);
68MODULE_PARM_DESC(CIFSMaxBufSize, "Network buffer size (not including header). " 67MODULE_PARM_DESC(CIFSMaxBufSize, "Network buffer size (not including header). "
69 "Default: 16384 Range: 8192 to 130048"); 68 "Default: 16384 Range: 8192 to 130048");
70unsigned int cifs_min_rcv = CIFS_MIN_RCV_POOL; 69unsigned int cifs_min_rcv = CIFS_MIN_RCV_POOL;
71module_param(cifs_min_rcv, int, 0); 70module_param(cifs_min_rcv, uint, 0);
72MODULE_PARM_DESC(cifs_min_rcv, "Network buffers in pool. Default: 4 Range: " 71MODULE_PARM_DESC(cifs_min_rcv, "Network buffers in pool. Default: 4 Range: "
73 "1 to 64"); 72 "1 to 64");
74unsigned int cifs_min_small = 30; 73unsigned int cifs_min_small = 30;
75module_param(cifs_min_small, int, 0); 74module_param(cifs_min_small, uint, 0);
76MODULE_PARM_DESC(cifs_min_small, "Small network buffers in pool. Default: 30 " 75MODULE_PARM_DESC(cifs_min_small, "Small network buffers in pool. Default: 30 "
77 "Range: 2 to 256"); 76 "Range: 2 to 256");
78unsigned int cifs_max_pending = CIFS_MAX_REQ; 77unsigned int cifs_max_pending = CIFS_MAX_REQ;
79module_param(cifs_max_pending, int, 0444); 78module_param(cifs_max_pending, uint, 0444);
80MODULE_PARM_DESC(cifs_max_pending, "Simultaneous requests to server. " 79MODULE_PARM_DESC(cifs_max_pending, "Simultaneous requests to server. "
81 "Default: 32767 Range: 2 to 32767."); 80 "Default: 32767 Range: 2 to 32767.");
82module_param(enable_oplocks, bool, 0644); 81module_param(enable_oplocks, bool, 0644);
83MODULE_PARM_DESC(enable_oplocks, "Enable or disable oplocks (bool). Default:" 82MODULE_PARM_DESC(enable_oplocks, "Enable or disable oplocks. Default: y/Y/1");
84 "y/Y/1");
85 83
86extern mempool_t *cifs_sm_req_poolp; 84extern mempool_t *cifs_sm_req_poolp;
87extern mempool_t *cifs_req_poolp; 85extern mempool_t *cifs_req_poolp;
@@ -540,8 +538,8 @@ cifs_get_root(struct smb_vol *vol, struct super_block *sb)
540 char *s, *p; 538 char *s, *p;
541 char sep; 539 char sep;
542 540
543 full_path = build_path_to_root(vol, cifs_sb, 541 full_path = cifs_build_path_to_root(vol, cifs_sb,
544 cifs_sb_master_tcon(cifs_sb)); 542 cifs_sb_master_tcon(cifs_sb));
545 if (full_path == NULL) 543 if (full_path == NULL)
546 return ERR_PTR(-ENOMEM); 544 return ERR_PTR(-ENOMEM);
547 545
@@ -695,13 +693,13 @@ static ssize_t cifs_file_aio_write(struct kiocb *iocb, const struct iovec *iov,
695 return written; 693 return written;
696} 694}
697 695
698static loff_t cifs_llseek(struct file *file, loff_t offset, int origin) 696static loff_t cifs_llseek(struct file *file, loff_t offset, int whence)
699{ 697{
700 /* 698 /*
701 * origin == SEEK_END || SEEK_DATA || SEEK_HOLE => we must revalidate 699 * whence == SEEK_END || SEEK_DATA || SEEK_HOLE => we must revalidate
702 * the cached file length 700 * the cached file length
703 */ 701 */
704 if (origin != SEEK_SET && origin != SEEK_CUR) { 702 if (whence != SEEK_SET && whence != SEEK_CUR) {
705 int rc; 703 int rc;
706 struct inode *inode = file->f_path.dentry->d_inode; 704 struct inode *inode = file->f_path.dentry->d_inode;
707 705
@@ -728,7 +726,7 @@ static loff_t cifs_llseek(struct file *file, loff_t offset, int origin)
728 if (rc < 0) 726 if (rc < 0)
729 return (loff_t)rc; 727 return (loff_t)rc;
730 } 728 }
731 return generic_file_llseek(file, offset, origin); 729 return generic_file_llseek(file, offset, whence);
732} 730}
733 731
734static int cifs_setlease(struct file *file, long arg, struct file_lock **lease) 732static int cifs_setlease(struct file *file, long arg, struct file_lock **lease)
@@ -1205,7 +1203,6 @@ exit_cifs(void)
1205 unregister_filesystem(&cifs_fs_type); 1203 unregister_filesystem(&cifs_fs_type);
1206 cifs_dfs_release_automount_timer(); 1204 cifs_dfs_release_automount_timer();
1207#ifdef CONFIG_CIFS_ACL 1205#ifdef CONFIG_CIFS_ACL
1208 cifs_destroy_idmaptrees();
1209 exit_cifs_idmap(); 1206 exit_cifs_idmap();
1210#endif 1207#endif
1211#ifdef CONFIG_CIFS_UPCALL 1208#ifdef CONFIG_CIFS_UPCALL