Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

crypto: skcipher - Add new helper function crypto_skcipher_tested

Add a new helper function crypto_skcipher_tested() which evaluates
the CRYPTO_ALG_TESTED flag from the tfm base cra_flags field.

Signed-off-by: Harald Freudenberger <freude@linux.ibm.com>
Reviewed-by: Holger Dengler <dengler@linux.ibm.com>
Reviewed-by: Ingo Franzki <ifranzki@linux.ibm.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>

authored by

Harald Freudenberger and committed by
Herbert Xu
cf0840cc 9c5582db

+7
+7
include/crypto/internal/skcipher.h
··· 242 242 return crypto_tfm_ctx_dma(&tfm->base); 243 243 } 244 244 245 + static inline bool crypto_skcipher_tested(struct crypto_skcipher *tfm) 246 + { 247 + struct crypto_tfm *tfm_base = crypto_skcipher_tfm(tfm); 248 + 249 + return tfm_base->__crt_alg->cra_flags & CRYPTO_ALG_TESTED; 250 + } 251 + 245 252 static inline void *skcipher_request_ctx(struct skcipher_request *req) 246 253 { 247 254 return req->__ctx;