Lines Matching refs:M

1118     mbedtls_mpi M;  in ecp_mod_p521()  local
1128 M.s = 1; in ecp_mod_p521()
1129 M.n = N->n - ( P521_WIDTH - 1 ); in ecp_mod_p521()
1130 if( M.n > P521_WIDTH + 1 ) in ecp_mod_p521()
1131 M.n = P521_WIDTH + 1; in ecp_mod_p521()
1132 M.p = Mp; in ecp_mod_p521()
1133 memcpy( Mp, N->p + P521_WIDTH - 1, M.n * sizeof( mbedtls_mpi_uint ) ); in ecp_mod_p521()
1134 MBEDTLS_MPI_CHK( mbedtls_mpi_shift_r( &M, 521 % ( 8 * sizeof( mbedtls_mpi_uint ) ) ) ); in ecp_mod_p521()
1142 MBEDTLS_MPI_CHK( mbedtls_mpi_add_abs( N, N, &M ) ); in ecp_mod_p521()
1167 mbedtls_mpi M; in ecp_mod_p255() local
1174 M.s = 1; in ecp_mod_p255()
1175 M.n = N->n - ( P255_WIDTH - 1 ); in ecp_mod_p255()
1176 if( M.n > P255_WIDTH + 1 ) in ecp_mod_p255()
1177 M.n = P255_WIDTH + 1; in ecp_mod_p255()
1178 M.p = Mp; in ecp_mod_p255()
1180 memcpy( Mp, N->p + P255_WIDTH - 1, M.n * sizeof( mbedtls_mpi_uint ) ); in ecp_mod_p255()
1181 MBEDTLS_MPI_CHK( mbedtls_mpi_shift_r( &M, 255 % ( 8 * sizeof( mbedtls_mpi_uint ) ) ) ); in ecp_mod_p255()
1182 M.n++; /* Make room for multiplication by 19 */ in ecp_mod_p255()
1190 MBEDTLS_MPI_CHK( mbedtls_mpi_mul_int( &M, &M, 19 ) ); in ecp_mod_p255()
1191 MBEDTLS_MPI_CHK( mbedtls_mpi_add_abs( N, N, &M ) ); in ecp_mod_p255()
1215 mbedtls_mpi M, R; in ecp_mod_koblitz() local
1227 M.s = 1; in ecp_mod_koblitz()
1228 M.p = Mp; in ecp_mod_koblitz()
1231 M.n = N->n - ( p_limbs - adjust ); in ecp_mod_koblitz()
1232 if( M.n > p_limbs + adjust ) in ecp_mod_koblitz()
1233 M.n = p_limbs + adjust; in ecp_mod_koblitz()
1235 memcpy( Mp, N->p + p_limbs - adjust, M.n * sizeof( mbedtls_mpi_uint ) ); in ecp_mod_koblitz()
1237 MBEDTLS_MPI_CHK( mbedtls_mpi_shift_r( &M, shift ) ); in ecp_mod_koblitz()
1238 M.n += R.n - adjust; /* Make room for multiplication by R */ in ecp_mod_koblitz()
1247 MBEDTLS_MPI_CHK( mbedtls_mpi_mul_mpi( &M, &M, &R ) ); in ecp_mod_koblitz()
1248 MBEDTLS_MPI_CHK( mbedtls_mpi_add_abs( N, N, &M ) ); in ecp_mod_koblitz()
1253 M.n = N->n - ( p_limbs - adjust ); in ecp_mod_koblitz()
1254 if( M.n > p_limbs + adjust ) in ecp_mod_koblitz()
1255 M.n = p_limbs + adjust; in ecp_mod_koblitz()
1257 memcpy( Mp, N->p + p_limbs - adjust, M.n * sizeof( mbedtls_mpi_uint ) ); in ecp_mod_koblitz()
1259 MBEDTLS_MPI_CHK( mbedtls_mpi_shift_r( &M, shift ) ); in ecp_mod_koblitz()
1260 M.n += R.n - adjust; /* Make room for multiplication by R */ in ecp_mod_koblitz()
1269 MBEDTLS_MPI_CHK( mbedtls_mpi_mul_mpi( &M, &M, &R ) ); in ecp_mod_koblitz()
1270 MBEDTLS_MPI_CHK( mbedtls_mpi_add_abs( N, N, &M ) ); in ecp_mod_koblitz()