summaryrefslogtreecommitdiffstats
path: root/fs/cifs/cifsglob.h
diff options
context:
space:
mode:
authorPavel Shilovsky2012-05-28 13:19:39 +0200
committerPavel Shilovsky2012-07-24 19:55:20 +0200
commitd60622eb5a23904facf4a4efac60f5bfa810d7d4 (patch)
tree9906729a6aa59d6191a715942a447837c79aa758 /fs/cifs/cifsglob.h
parentCIFS: Move clear/print_stats code to ops struct (diff)
downloadkernel-qcow2-linux-d60622eb5a23904facf4a4efac60f5bfa810d7d4.tar.gz
kernel-qcow2-linux-d60622eb5a23904facf4a4efac60f5bfa810d7d4.tar.xz
kernel-qcow2-linux-d60622eb5a23904facf4a4efac60f5bfa810d7d4.zip
CIFS: Allow SMB2 statistics to be tracked
Since there are only 19 command codes, it also is easier to track by exact command code than it was for cifs. Signed-off-by: Pavel Shilovsky <pshilovsky@samba.org> Signed-off-by: Steve French <smfrench@gmail.com>
Diffstat (limited to 'fs/cifs/cifsglob.h')
-rw-r--r--fs/cifs/cifsglob.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/fs/cifs/cifsglob.h b/fs/cifs/cifsglob.h
index 0896328418aa..12b1176b87b0 100644
--- a/fs/cifs/cifsglob.h
+++ b/fs/cifs/cifsglob.h
@@ -28,6 +28,9 @@
#include "cifsacl.h"
#include <crypto/internal/hash.h>
#include <linux/scatterlist.h>
+#ifdef CONFIG_CIFS_SMB2
+#include "smb2pdu.h"
+#endif
/*
* The sizes of various internal tables and strings
@@ -592,6 +595,12 @@ struct cifs_tcon {
atomic_t num_acl_get;
atomic_t num_acl_set;
} cifs_stats;
+#ifdef CONFIG_CIFS_SMB2
+ struct {
+ atomic_t smb2_com_sent[NUMBER_OF_SMB2_COMMANDS];
+ atomic_t smb2_com_failed[NUMBER_OF_SMB2_COMMANDS];
+ } smb2_stats;
+#endif /* CONFIG_CIFS_SMB2 */
} stats;
#ifdef CONFIG_CIFS_STATS2
unsigned long long time_writes;