Lines Matching defs:hmacctx
111 return &ctx->crypto_ctx->hmacctx;
1566 struct hmac_ctx *hmacctx = HMAC_CTX(ctx);
1618 hmacctx->opad, param->alg_prm.result_size);
2204 struct hmac_ctx *hmacctx = HMAC_CTX(h_ctx(tfm));
2209 SHASH_DESC_ON_STACK(shash, hmacctx->base_hash);
2213 * ipad in hmacctx->ipad and opad in hmacctx->opad location
2215 shash->tfm = hmacctx->base_hash;
2218 hmacctx->ipad);
2223 memcpy(hmacctx->ipad, key, keylen);
2225 memset(hmacctx->ipad + keylen, 0, bs - keylen);
2226 unsafe_memcpy(hmacctx->opad, hmacctx->ipad, bs,
2230 *((unsigned int *)(&hmacctx->ipad) + i) ^= IPAD_DATA;
2231 *((unsigned int *)(&hmacctx->opad) + i) ^= OPAD_DATA;
2239 err = chcr_compute_partial_hash(shash, hmacctx->ipad,
2240 hmacctx->ipad, digestsize);
2243 chcr_change_order(hmacctx->ipad, updated_digestsize);
2245 err = chcr_compute_partial_hash(shash, hmacctx->opad,
2246 hmacctx->opad, digestsize);
2249 chcr_change_order(hmacctx->opad, updated_digestsize);
2325 struct hmac_ctx *hmacctx = HMAC_CTX(h_ctx(rtfm));
2333 memcpy(req_ctx->partial_hash, hmacctx->ipad,
2336 memcpy(req_ctx->partial_hash, hmacctx->ipad,
2339 memcpy(req_ctx->partial_hash, hmacctx->ipad,
2348 struct hmac_ctx *hmacctx = HMAC_CTX(ctx);
2354 hmacctx->base_hash = chcr_alloc_shash(digestsize);
2355 if (IS_ERR(hmacctx->base_hash))
2356 return PTR_ERR(hmacctx->base_hash);
2363 struct hmac_ctx *hmacctx = HMAC_CTX(ctx);
2365 if (hmacctx->base_hash) {
2366 chcr_free_shash(hmacctx->base_hash);
2367 hmacctx->base_hash = NULL;