Bignum: add missing limb qualifiers
Signed-off-by: Janos Follath <janos.follath@arm.com>
This commit is contained in:
parent
6b8e0c2884
commit
c459641ad1
2 changed files with 6 additions and 6 deletions
|
@ -130,11 +130,11 @@ static mbedtls_mpi_uint mpi_bigendian_to_host( mbedtls_mpi_uint a )
|
||||||
}
|
}
|
||||||
|
|
||||||
void mbedtls_mpi_core_bigendian_to_host( mbedtls_mpi_uint *A,
|
void mbedtls_mpi_core_bigendian_to_host( mbedtls_mpi_uint *A,
|
||||||
size_t limbs )
|
size_t A_limbs )
|
||||||
{
|
{
|
||||||
mbedtls_mpi_uint *cur_limb_left;
|
mbedtls_mpi_uint *cur_limb_left;
|
||||||
mbedtls_mpi_uint *cur_limb_right;
|
mbedtls_mpi_uint *cur_limb_right;
|
||||||
if( limbs == 0 )
|
if( A_limbs == 0 )
|
||||||
return;
|
return;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -146,7 +146,7 @@ void mbedtls_mpi_core_bigendian_to_host( mbedtls_mpi_uint *A,
|
||||||
* than the right index (it's not a problem if limbs is odd and the
|
* than the right index (it's not a problem if limbs is odd and the
|
||||||
* indices coincide in the last iteration).
|
* indices coincide in the last iteration).
|
||||||
*/
|
*/
|
||||||
for( cur_limb_left = A, cur_limb_right = A + ( limbs - 1 );
|
for( cur_limb_left = A, cur_limb_right = A + ( A_limbs - 1 );
|
||||||
cur_limb_left <= cur_limb_right;
|
cur_limb_left <= cur_limb_right;
|
||||||
cur_limb_left++, cur_limb_right-- )
|
cur_limb_left++, cur_limb_right-- )
|
||||||
{
|
{
|
||||||
|
|
|
@ -45,7 +45,7 @@ size_t mbedtls_mpi_core_clz( const mbedtls_mpi_uint a );
|
||||||
* \note This function returns 0 if all the limbs of \p A are 0.
|
* \note This function returns 0 if all the limbs of \p A are 0.
|
||||||
*
|
*
|
||||||
* \param[in] A The address of the MPI.
|
* \param[in] A The address of the MPI.
|
||||||
* \param a_limbs The number of limbs of \p A.
|
* \param A_limbs The number of limbs of \p A.
|
||||||
*
|
*
|
||||||
* \return The number of bits in \p A.
|
* \return The number of bits in \p A.
|
||||||
*/
|
*/
|
||||||
|
@ -55,10 +55,10 @@ size_t mbedtls_mpi_core_bitlen( const mbedtls_mpi_uint *A, size_t A_limbs );
|
||||||
* into the storage form used by mbedtls_mpi.
|
* into the storage form used by mbedtls_mpi.
|
||||||
*
|
*
|
||||||
* \param[in,out] A The address of the MPI.
|
* \param[in,out] A The address of the MPI.
|
||||||
* \param limbs The number of limbs of \p A.
|
* \param A_limbs The number of limbs of \p A.
|
||||||
*/
|
*/
|
||||||
void mbedtls_mpi_core_bigendian_to_host( mbedtls_mpi_uint *A,
|
void mbedtls_mpi_core_bigendian_to_host( mbedtls_mpi_uint *A,
|
||||||
size_t limbs );
|
size_t A_limbs );
|
||||||
|
|
||||||
/** Import X from unsigned binary data, little-endian.
|
/** Import X from unsigned binary data, little-endian.
|
||||||
*
|
*
|
||||||
|
|
Loading…
Reference in a new issue