diff options
author | Herbert Xu <herbert@gondor.apana.org.au> | 2009-07-09 21:27:13 +0800 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2009-07-11 18:23:33 +0800 |
commit | e2a7ce4e185a94462698cc0e5192495ee3d22a2f (patch) | |
tree | 33013f177e48a3b4b191bfccfdb969cf0eeb8dbb /include | |
parent | 8267adab9433593adb09d94626475c2a5921f111 (diff) | |
download | linux-e2a7ce4e185a94462698cc0e5192495ee3d22a2f.tar.bz2 |
crypto: sha1_generic - Add export/import support
This patch adds export/import support to sha1_generic. The exported
type is defined by struct sha1_state, which is basically the entire
descriptor state of sha1_generic.
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'include')
-rw-r--r-- | include/crypto/sha.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/include/crypto/sha.h b/include/crypto/sha.h index c0ccc2b1a2d8..922a248bd04d 100644 --- a/include/crypto/sha.h +++ b/include/crypto/sha.h @@ -5,6 +5,8 @@ #ifndef _CRYPTO_SHA_H #define _CRYPTO_SHA_H +#include <linux/types.h> + #define SHA1_DIGEST_SIZE 20 #define SHA1_BLOCK_SIZE 64 @@ -62,4 +64,10 @@ #define SHA512_H6 0x1f83d9abfb41bd6bULL #define SHA512_H7 0x5be0cd19137e2179ULL +struct sha1_state { + u64 count; + u32 state[SHA1_DIGEST_SIZE / 4]; + u8 buffer[SHA1_BLOCK_SIZE]; +}; + #endif |