Lines Matching refs:pctx
204 struct rng_parent_ctx *pctx;
207 pctx = kzalloc(sizeof(*pctx), GFP_KERNEL);
208 if (!pctx)
213 kfree(pctx);
217 pctx->drng = rng;
218 return pctx;
223 struct rng_parent_ctx *pctx = private;
225 if (unlikely(!pctx))
227 crypto_free_rng(pctx->drng);
228 kfree_sensitive(pctx->entropy);
229 kfree_sensitive(pctx);
245 struct rng_parent_ctx *pctx = private;
263 ctx->drng = pctx->drng;
268 * Non NULL pctx->entropy means that CAVP test has been initiated on
271 if (IS_ENABLED(CONFIG_CRYPTO_USER_API_RNG_CAVP) && pctx->entropy)
279 struct rng_parent_ctx *pctx = private;
284 return crypto_rng_reset(pctx->drng, seed, seedlen);
290 struct rng_parent_ctx *pctx = private;
296 if (pctx->entropy)
308 crypto_rng_alg(pctx->drng)->set_ent(pctx->drng, kentropy, len);
311 * buffer, save kentropy pointer to pctx now to free it after use.
313 pctx->entropy = kentropy;