diff options
author | Herbert Xu <herbert@gondor.apana.org.au> | 2008-11-02 08:38:11 -0500 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2008-12-24 19:01:30 -0500 |
commit | dec8b78606ebd5f309c38f2fb10196ce996dd18d (patch) | |
tree | 005ef526f1b0e953a3a57e6c991e0921fcd5234b /include/crypto/internal/hash.h | |
parent | 3b2f6df08258e2875f42bd630eece7e7241a053b (diff) |
crypto: hash - Add import/export interface
It is often useful to save the partial state of a hash function
so that it can be used as a base for two or more computations.
The most prominent example is HMAC where all hashes start from
a base determined by the key. Having an import/export interface
means that we only have to compute that base once rather than
for each message.
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'include/crypto/internal/hash.h')
-rw-r--r-- | include/crypto/internal/hash.h | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/include/crypto/internal/hash.h b/include/crypto/internal/hash.h index 32d3a8ed06de..92fbe7385856 100644 --- a/include/crypto/internal/hash.h +++ b/include/crypto/internal/hash.h | |||
@@ -66,11 +66,6 @@ static inline struct ahash_request *ahash_dequeue_request( | |||
66 | return ahash_request_cast(crypto_dequeue_request(queue)); | 66 | return ahash_request_cast(crypto_dequeue_request(queue)); |
67 | } | 67 | } |
68 | 68 | ||
69 | static inline void *ahash_request_ctx(struct ahash_request *req) | ||
70 | { | ||
71 | return req->__ctx; | ||
72 | } | ||
73 | |||
74 | static inline int ahash_tfm_in_queue(struct crypto_queue *queue, | 69 | static inline int ahash_tfm_in_queue(struct crypto_queue *queue, |
75 | struct crypto_ahash *tfm) | 70 | struct crypto_ahash *tfm) |
76 | { | 71 | { |