All the mail mirrored from lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] crypto: skcipher - Add helper to retrieve driver name
@ 2016-01-26 14:14 Herbert Xu
  0 siblings, 0 replies; only message in thread
From: Herbert Xu @ 2016-01-26 14:14 UTC (permalink / raw
  To: Linux Crypto Mailing List

This patch adds the helper crypto_skcipher_driver_name which returns
the driver name of the alg object for a given tfm.  This is needed by
ecryptfs.

Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>

diff --git a/include/crypto/skcipher.h b/include/crypto/skcipher.h
index f7a03a1..5bb7056 100644
--- a/include/crypto/skcipher.h
+++ b/include/crypto/skcipher.h
@@ -231,6 +231,12 @@ static inline int crypto_has_skcipher(const char *alg_name, u32 type,
 			      crypto_skcipher_mask(mask));
 }
 
+static inline const char *crypto_skcipher_driver_name(
+	struct crypto_skcipher *tfm)
+{
+	return crypto_tfm_alg_name(crypto_skcipher_tfm(tfm));
+}
+
 /**
  * crypto_skcipher_ivsize() - obtain IV size
  * @tfm: cipher handle
-- 
Email: Herbert Xu <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2016-01-26 14:14 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-01-26 14:14 [PATCH] crypto: skcipher - Add helper to retrieve driver name Herbert Xu

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.