libata-sff: ap->[last_]ctl are SFF specific
[safe/jmp/linux-2.6] / include / crypto / sha.h
index 0686e1f..069e85b 100644 (file)
@@ -5,9 +5,14 @@
 #ifndef _CRYPTO_SHA_H
 #define _CRYPTO_SHA_H
 
+#include <linux/types.h>
+
 #define SHA1_DIGEST_SIZE        20
 #define SHA1_BLOCK_SIZE         64
 
+#define SHA224_DIGEST_SIZE     28
+#define SHA224_BLOCK_SIZE      64
+
 #define SHA256_DIGEST_SIZE      32
 #define SHA256_BLOCK_SIZE       64
 
 #define SHA1_H3                0x10325476UL
 #define SHA1_H4                0xc3d2e1f0UL
 
+#define SHA224_H0      0xc1059ed8UL
+#define SHA224_H1      0x367cd507UL
+#define SHA224_H2      0x3070dd17UL
+#define SHA224_H3      0xf70e5939UL
+#define SHA224_H4      0xffc00b31UL
+#define SHA224_H5      0x68581511UL
+#define SHA224_H6      0x64f98fa7UL
+#define SHA224_H7      0xbefa4fa4UL
+
 #define SHA256_H0      0x6a09e667UL
 #define SHA256_H1      0xbb67ae85UL
 #define SHA256_H2      0x3c6ef372UL
 #define SHA512_H6      0x1f83d9abfb41bd6bULL
 #define SHA512_H7      0x5be0cd19137e2179ULL
 
+struct sha1_state {
+       u64 count;
+       u32 state[SHA1_DIGEST_SIZE / 4];
+       u8 buffer[SHA1_BLOCK_SIZE];
+};
+
+struct sha256_state {
+       u64 count;
+       u32 state[SHA256_DIGEST_SIZE / 4];
+       u8 buf[SHA256_BLOCK_SIZE];
+};
+
+struct sha512_state {
+       u64 count[2];
+       u64 state[SHA512_DIGEST_SIZE / 8];
+       u8 buf[SHA512_BLOCK_SIZE];
+};
+
 #endif