aboutsummaryrefslogtreecommitdiffstats
path: root/fs/cifs/cifsglob.h
diff options
context:
space:
mode:
authorshirishpargaonkar@gmail.com <shirishpargaonkar@gmail.com>2010-08-24 12:53:48 -0400
committerSteve French <sfrench@us.ibm.com>2010-08-24 14:12:52 -0400
commit2d20ca835867d93ead6ce61780d883a4b128106d (patch)
tree519a2bff48470a78406e55428a8410ed63c63c48 /fs/cifs/cifsglob.h
parent24e6cf92fde1f140d8eb0bf7cd24c2c78149b6b2 (diff)
Eliminate sparse warning - bad constant expression
Eliminiate sparse warning during usage of crypto_shash_* APIs error: bad constant expression Allocate memory for shash descriptors once, so that we do not kmalloc/kfree it for every signature generation (shash descriptor for md5 hash). From ed7538619817777decc44b5660b52268077b74f3 Mon Sep 17 00:00:00 2001 From: Shirish Pargaonkar <shirishpargaonkar@gmail.com> Date: Tue, 24 Aug 2010 11:47:43 -0500 Subject: [PATCH] eliminate sparse warnings during crypto_shash_* APis usage Signed-off-by: Shirish Pargaonkar <shirishpargaonkar@gmail.com> Signed-off-by: Steve French <sfrench@us.ibm.com>
Diffstat (limited to 'fs/cifs/cifsglob.h')
-rw-r--r--fs/cifs/cifsglob.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/fs/cifs/cifsglob.h b/fs/cifs/cifsglob.h
index 49563e0c1725..c9d0cfc086eb 100644
--- a/fs/cifs/cifsglob.h
+++ b/fs/cifs/cifsglob.h
@@ -123,12 +123,19 @@ struct cifs_cred {
123 struct cifs_ace *aces; 123 struct cifs_ace *aces;
124}; 124};
125 125
126struct sdesc {
127 struct shash_desc shash;
128 char ctx[];
129};
130
126struct ntlmssp_auth { 131struct ntlmssp_auth {
127 __u32 client_flags; 132 __u32 client_flags;
128 __u32 server_flags; 133 __u32 server_flags;
129 unsigned char ciphertext[CIFS_CPHTXT_SIZE]; 134 unsigned char ciphertext[CIFS_CPHTXT_SIZE];
130 struct crypto_shash *hmacmd5; 135 struct crypto_shash *hmacmd5;
131 struct crypto_shash *md5; 136 struct crypto_shash *md5;
137 struct sdesc *sdeschmacmd5;
138 struct sdesc *sdescmd5;
132}; 139};
133 140
134/* 141/*