2 * Cryptographic API for algorithms (i.e., low-level API).
4 * Copyright (c) 2006 Herbert Xu <herbert@gondor.apana.org.au>
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)
12 #ifndef _CRYPTO_ALGAPI_H
13 #define _CRYPTO_ALGAPI_H
15 #include <linux/crypto.h>
18 unsigned int (*ctxsize)(struct crypto_alg *alg, u32 type, u32 mask);
19 unsigned int (*extsize)(struct crypto_alg *alg);
20 int (*init)(struct crypto_tfm *tfm, u32 type, u32 mask);
21 int (*init_tfm)(struct crypto_tfm *tfm);
29 extern const struct crypto_type crypto_blkcipher_type;
31 static inline void *crypto_blkcipher_ctx(struct crypto_blkcipher *tfm)
33 return crypto_tfm_ctx(&tfm->base);
36 #endif /* _CRYPTO_ALGAPI_H */