Skip to content

Commit a2d382a

Browse files
committed
crypto: skcipher - Add helper to retrieve driver name
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>
1 parent c1e9b3b commit a2d382a

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

include/crypto/skcipher.h

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -231,6 +231,12 @@ static inline int crypto_has_skcipher(const char *alg_name, u32 type,
231231
crypto_skcipher_mask(mask));
232232
}
233233

234+
static inline const char *crypto_skcipher_driver_name(
235+
struct crypto_skcipher *tfm)
236+
{
237+
return crypto_tfm_alg_name(crypto_skcipher_tfm(tfm));
238+
}
239+
234240
/**
235241
* crypto_skcipher_ivsize() - obtain IV size
236242
* @tfm: cipher handle

0 commit comments

Comments
 (0)