summaryrefslogtreecommitdiffstats
path: root/fs/cifs/cifssmb.c
diff options
context:
space:
mode:
authorSteve French <sfrench@us.ibm.com>2005-06-23 02:13:47 +0200
committerSteve French <sfrench@hera.kernel.org>2005-06-23 02:13:47 +0200
commitdfb7533b5f157ac7135da23883e80d895227d965 (patch)
tree6a09f6d0945653bb21a2cdc8f050b82a4671227c /fs/cifs/cifssmb.c
parentMerge master.kernel.org:/home/rmk/linux-2.6-arm (diff)
downloadlinux-dfb7533b5f157ac7135da23883e80d895227d965.tar.xz
linux-dfb7533b5f157ac7135da23883e80d895227d965.zip
[CIFS] Add stats for findfirst, findnext, findclose
Signed-off-by: Steve French (sfrench@us.ibm.com)
Diffstat (limited to 'fs/cifs/cifssmb.c')
-rw-r--r--fs/cifs/cifssmb.c13
1 files changed, 12 insertions, 1 deletions
diff --git a/fs/cifs/cifssmb.c b/fs/cifs/cifssmb.c
index 3c628bf667a5..b31158a2643d 100644
--- a/fs/cifs/cifssmb.c
+++ b/fs/cifs/cifssmb.c
@@ -2396,7 +2396,9 @@ findUniqueRetry:
if (rc) {
cFYI(1, ("Send error in FindFileDirInfo = %d", rc));
} else { /* decode response */
-
+#ifdef CONFIG_CIFS_STATS
+ atomic_inc(&tcon->num_ffirst);
+#endif
/* BB fill in */
}
@@ -2509,6 +2511,9 @@ findFirstRetry:
if (rc == -EAGAIN)
goto findFirstRetry;
} else { /* decode response */
+#ifdef CONFIG_CIFS_STATS
+ atomic_inc(&tcon->num_ffirst);
+#endif
/* BB remember to free buffer if error BB */
rc = validate_t2((struct smb_t2_rsp *)pSMBr);
if(rc == 0) {
@@ -2622,6 +2627,9 @@ int CIFSFindNext(const int xid, struct cifsTconInfo *tcon,
} else
cFYI(1, ("FindNext returned = %d", rc));
} else { /* decode response */
+#ifdef CONFIG_CIFS_STATS
+ atomic_inc(&tcon->num_fnext);
+#endif
rc = validate_t2((struct smb_t2_rsp *)pSMBr);
if(rc == 0) {
@@ -2691,6 +2699,9 @@ CIFSFindClose(const int xid, struct cifsTconInfo *tcon, const __u16 searchHandle
if (rc) {
cERROR(1, ("Send error in FindClose = %d", rc));
}
+#ifdef CONFIG_CIFS_STATS
+ atomic_inc(&tcon->num_fclose);
+#endif
cifs_small_buf_release(pSMB);
/* Since session is dead, search handle closed on server already */