Herbert Xu | 2003625 | 2008-07-07 22:19:53 +0800 | [diff] [blame^] | 1 | /* |
| 2 | * Hash algorithms. |
| 3 | * |
| 4 | * Copyright (c) 2008 Herbert Xu <herbert@gondor.apana.org.au> |
| 5 | * |
| 6 | * This program is free software; you can redistribute it and/or modify it |
| 7 | * under the terms of the GNU General Public License as published by the Free |
| 8 | * Software Foundation; either version 2 of the License, or (at your option) |
| 9 | * any later version. |
| 10 | * |
| 11 | */ |
| 12 | |
| 13 | #ifndef _CRYPTO_INTERNAL_HASH_H |
| 14 | #define _CRYPTO_INTERNAL_HASH_H |
| 15 | |
| 16 | #include <crypto/algapi.h> |
| 17 | |
| 18 | struct ahash_request; |
| 19 | struct scatterlist; |
| 20 | |
| 21 | struct crypto_hash_walk { |
| 22 | char *data; |
| 23 | |
| 24 | unsigned int offset; |
| 25 | unsigned int alignmask; |
| 26 | |
| 27 | struct page *pg; |
| 28 | unsigned int entrylen; |
| 29 | |
| 30 | unsigned int total; |
| 31 | struct scatterlist *sg; |
| 32 | |
| 33 | unsigned int flags; |
| 34 | }; |
| 35 | |
| 36 | int crypto_hash_walk_done(struct crypto_hash_walk *walk, int err); |
| 37 | int crypto_hash_walk_first(struct ahash_request *req, |
| 38 | struct crypto_hash_walk *walk); |
| 39 | |
| 40 | #endif /* _CRYPTO_INTERNAL_HASH_H */ |
| 41 | |