Lines Matching refs:ctx
31 struct __sha512_ctx ctx = *ctx0; in __crypto_sha512_export() local
35 partial = ctx.bytecount_lo % SHA512_BLOCK_SIZE; in __crypto_sha512_export()
36 ctx.bytecount_lo -= partial; in __crypto_sha512_export()
37 memcpy(p, &ctx, sizeof(ctx)); in __crypto_sha512_export()
38 p += sizeof(ctx); in __crypto_sha512_export()
43 static int __crypto_sha512_import(struct __sha512_ctx *ctx, const void *in) in __crypto_sha512_import() argument
47 memcpy(ctx, p, sizeof(*ctx)); in __crypto_sha512_import()
48 p += sizeof(*ctx); in __crypto_sha512_import()
49 ctx->bytecount_lo += *p; in __crypto_sha512_import()
95 return __crypto_sha512_export(&SHA384_CTX(desc)->ctx, out); in crypto_sha384_export()
100 return __crypto_sha512_import(&SHA384_CTX(desc)->ctx, in); in crypto_sha384_import()
147 return __crypto_sha512_export(&SHA512_CTX(desc)->ctx, out); in crypto_sha512_export()
152 return __crypto_sha512_import(&SHA512_CTX(desc)->ctx, in); in crypto_sha512_import()
196 return __crypto_sha512_export(&HMAC_SHA384_CTX(desc)->ctx.sha_ctx, out); in crypto_hmac_sha384_export()
201 struct hmac_sha384_ctx *ctx = HMAC_SHA384_CTX(desc); in crypto_hmac_sha384_import() local
203 ctx->ctx.ostate = HMAC_SHA384_KEY(desc->tfm)->key.ostate; in crypto_hmac_sha384_import()
204 return __crypto_sha512_import(&ctx->ctx.sha_ctx, in); in crypto_hmac_sha384_import()
248 return __crypto_sha512_export(&HMAC_SHA512_CTX(desc)->ctx.sha_ctx, out); in crypto_hmac_sha512_export()
253 struct hmac_sha512_ctx *ctx = HMAC_SHA512_CTX(desc); in crypto_hmac_sha512_import() local
255 ctx->ctx.ostate = HMAC_SHA512_KEY(desc->tfm)->key.ostate; in crypto_hmac_sha512_import()
256 return __crypto_sha512_import(&ctx->ctx.sha_ctx, in); in crypto_hmac_sha512_import()