linux-crypto.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] crypto: api - Clear CRYPTO_ALG_DEAD bit before registering an alg
@ 2017-01-13 11:54 Salvatore Benedetto
  2017-01-23 14:57 ` Herbert Xu
  0 siblings, 1 reply; 4+ messages in thread
From: Salvatore Benedetto @ 2017-01-13 11:54 UTC (permalink / raw)
  To: herbert; +Cc: salvatore.benedetto, linux-crypto

Make sure CRYPTO_ALG_DEAD bit is cleared before proceeding with
the algorithm registration. This fixes qat-dh registration when
driver is restarted

Signed-off-by: Salvatore Benedetto <salvatore.benedetto@intel.com>
---
 crypto/algapi.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/crypto/algapi.c b/crypto/algapi.c
index df939b5..1fad2a6 100644
--- a/crypto/algapi.c
+++ b/crypto/algapi.c
@@ -356,6 +356,7 @@ int crypto_register_alg(struct crypto_alg *alg)
 	struct crypto_larval *larval;
 	int err;
 
+	alg->cra_flags &= ~CRYPTO_ALG_DEAD;
 	err = crypto_check_alg(alg);
 	if (err)
 		return err;
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2017-02-01 14:06 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-01-13 11:54 [PATCH] crypto: api - Clear CRYPTO_ALG_DEAD bit before registering an alg Salvatore Benedetto
2017-01-23 14:57 ` Herbert Xu
2017-01-23 17:06   ` Benedetto, Salvatore
2017-02-01 14:06     ` Herbert Xu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).