Searched refs:bn_ctx (Results 1 – 2 of 2) sorted by relevance
/openbmc/linux/tools/testing/selftests/sgx/ |
H A D | sigstruct.c | 27 BN_CTX *bn_ctx; member 37 BN_CTX_free(ctx->bn_ctx); in free_q1q2_ctx() 48 ctx->bn_ctx = BN_CTX_new(); in alloc_q1q2_ctx() 55 if (!ctx->bn_ctx || !ctx->s || !ctx->m || !ctx->q1 || !ctx->qr || in alloc_q1q2_ctx() 91 if (!BN_mul(ctx.q1, ctx.s, ctx.s, ctx.bn_ctx)) in calc_q1q2() 94 if (!BN_div(ctx.q1, ctx.qr, ctx.q1, ctx.m, ctx.bn_ctx)) in calc_q1q2() 103 if (!BN_mul(ctx.q2, ctx.s, ctx.qr, ctx.bn_ctx)) in calc_q1q2() 106 if (!BN_div(ctx.q2, NULL, ctx.q2, ctx.m, ctx.bn_ctx)) in calc_q1q2()
|
/openbmc/u-boot/lib/rsa/ |
H A D | rsa-sign.c | 590 BN_CTX *bn_ctx = BN_CTX_new(); in rsa_get_params() local 617 if (!BN_exp(big2_32, big2, big32, bn_ctx)) in rsa_get_params() 621 if (!BN_mod_inverse(tmp, n, big2_32, bn_ctx) || in rsa_get_params() 628 !BN_exp(r, big2, tmp, bn_ctx)) in rsa_get_params() 633 !BN_mul(tmp, r_squared, r, bn_ctx) || in rsa_get_params() 634 !BN_mod(r_squared, tmp, n, bn_ctx)) in rsa_get_params()
|