crypto: api - Change crypto_unregister_instance argument type

This patch makes crypto_unregister_instance take a crypto_instance
instead of a crypto_alg.  This allows us to remove a duplicate
CRYPTO_ALG_INSTANCE check in crypto_unregister_instance.

Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
This commit is contained in:
Herbert Xu
2015-04-02 22:39:40 +08:00
parent 1f72371099
commit 87b1675634
3 changed files with 4 additions and 8 deletions

View File

@@ -316,7 +316,7 @@ static int crypto_del_alg(struct sk_buff *skb, struct nlmsghdr *nlh,
if (atomic_read(&alg->cra_refcnt) != 1)
return -EBUSY;
return crypto_unregister_instance(alg);
return crypto_unregister_instance((struct crypto_instance *)alg);
}
static struct crypto_alg *crypto_user_skcipher_alg(const char *name, u32 type,