Lines Matching refs:modp
115 uint32_t* modp; in multiprecision_lshift_mod() local
118 modp = curve.p; in multiprecision_lshift_mod()
120 modp = curve_p256.p; in multiprecision_lshift_mod()
126 multiprecision_sub(c, c, modp, keyLength); in multiprecision_lshift_mod()
127 } else if (multiprecision_compare(c, modp, keyLength) >= 0) { in multiprecision_lshift_mod()
128 multiprecision_sub(c, c, modp, keyLength); in multiprecision_lshift_mod()
172 uint32_t* modp; in multiprecision_add_mod() local
175 modp = curve.p; in multiprecision_add_mod()
177 modp = curve_p256.p; in multiprecision_add_mod()
183 multiprecision_sub(c, c, modp, keyLength); in multiprecision_add_mod()
184 } else if (multiprecision_compare(c, modp, keyLength) >= 0) { in multiprecision_add_mod()
185 multiprecision_sub(c, c, modp, keyLength); in multiprecision_add_mod()
193 uint32_t* modp; in multiprecision_sub_mod() local
196 modp = curve.p; in multiprecision_sub_mod()
198 modp = curve_p256.p; in multiprecision_sub_mod()
203 if (borrow) multiprecision_add(c, c, modp, keyLength); in multiprecision_sub_mod()
256 uint32_t* modp = curve.p; in multiprecision_fast_mod() local
318 multiprecision_sub(c, c, modp, KEY_LENGTH_DWORDS_P192); in multiprecision_fast_mod()
319 } else if (multiprecision_compare(c, modp, KEY_LENGTH_DWORDS_P192) >= 0) { in multiprecision_fast_mod()
320 multiprecision_sub(c, c, modp, KEY_LENGTH_DWORDS_P192); in multiprecision_fast_mod()
340 uint32_t* modp = curve_p256.p; in multiprecision_fast_mod_P256() local
544 multiprecision_add(c, c, modp, KEY_LENGTH_DWORDS_P256); in multiprecision_fast_mod_P256()
549 multiprecision_sub(c, c, modp, KEY_LENGTH_DWORDS_P256); in multiprecision_fast_mod_P256()
554 if (multiprecision_compare(c, modp, KEY_LENGTH_DWORDS_P256) >= 0) in multiprecision_fast_mod_P256()
555 multiprecision_sub(c, c, modp, KEY_LENGTH_DWORDS_P256); in multiprecision_fast_mod_P256()
562 uint32_t* modp; in multiprecision_inv_mod() local
565 modp = curve_p256.p; in multiprecision_inv_mod()
567 modp = curve.p; in multiprecision_inv_mod()
570 multiprecision_copy(v, modp, keyLength); in multiprecision_inv_mod()
582 A[keyLength] = multiprecision_add(A, A, modp, keyLength); // A =A+p in multiprecision_inv_mod()
595 C[keyLength] = multiprecision_add(C, C, modp, keyLength); // C =C+p in multiprecision_inv_mod()
610 if (multiprecision_compare(C, modp, keyLength) >= 0) in multiprecision_inv_mod()
611 multiprecision_sub(aminus, C, modp, keyLength); in multiprecision_inv_mod()