mirror of https://gitee.com/openkylin/linux.git
crypto: skcipher - add crypto_skcipher_min_keysize()
Add a helper function crypto_skcipher_min_keysize() to mirror crypto_skcipher_max_keysize(). This will be used by the self-tests. Signed-off-by: Eric Biggers <ebiggers@google.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
This commit is contained in:
parent
095be695e5
commit
7bada03311
|
@ -368,6 +368,12 @@ static inline int crypto_sync_skcipher_setkey(struct crypto_sync_skcipher *tfm,
|
|||
return crypto_skcipher_setkey(&tfm->base, key, keylen);
|
||||
}
|
||||
|
||||
static inline unsigned int crypto_skcipher_min_keysize(
|
||||
struct crypto_skcipher *tfm)
|
||||
{
|
||||
return crypto_skcipher_alg(tfm)->min_keysize;
|
||||
}
|
||||
|
||||
static inline unsigned int crypto_skcipher_max_keysize(
|
||||
struct crypto_skcipher *tfm)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue