summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatt Caswell <matt@openssl.org>2018-01-31 13:43:15 +0000
committerMatt Caswell <matt@openssl.org>2018-02-20 12:59:30 +0000
commitbd74eae1be6c11bbfa95542daa7d59d461464853 (patch)
tree22fb64b79f3cb79eeab0f65bd72d52416cd900c5
parent7e492f3372ed83af074a63d5920f13de7e3455b6 (diff)
Rename a function to avoid a clash
We already have a constant_time_select() function so, to avoid confusion/clashing we shouldn't have a second one. Reviewed-by: Bernd Edlinger <bernd.edlinger@hotmail.de> (Merged from https://github.com/openssl/openssl/pull/5105)
-rw-r--r--crypto/ec/curve448/constant_time.h12
-rw-r--r--crypto/ec/curve448/field.h2
2 files changed, 7 insertions, 7 deletions
diff --git a/crypto/ec/curve448/constant_time.h b/crypto/ec/curve448/constant_time.h
index 84ee02eb68..61389a2b21 100644
--- a/crypto/ec/curve448/constant_time.h
+++ b/crypto/ec/curve448/constant_time.h
@@ -258,12 +258,12 @@ static ossl_inline void constant_time_lookup(void *RESTRICT out_,
* Note that the output is not __restrict__, but if it overlaps either
* input, it must be equal and not partially overlap.
*/
-static ossl_inline void constant_time_select(void *a_,
- const void *bFalse_,
- const void *bTrue_,
- word_t elem_bytes,
- mask_t mask,
- size_t alignment_bytes)
+static ossl_inline void constant_time_select_c448(void *a_,
+ const void *bFalse_,
+ const void *bTrue_,
+ word_t elem_bytes,
+ mask_t mask,
+ size_t alignment_bytes)
{
unsigned char *a = (unsigned char *)a_;
const unsigned char *bTrue = (const unsigned char *)bTrue_;
diff --git a/crypto/ec/curve448/field.h b/crypto/ec/curve448/field.h
index b985d453e7..2b7fc2aa95 100644
--- a/crypto/ec/curve448/field.h
+++ b/crypto/ec/curve448/field.h
@@ -128,7 +128,7 @@ static ossl_inline void gf_mulw(gf c, const gf a, int32_t w)
/* Constant time, x = is_z ? z : y */
static ossl_inline void gf_cond_sel(gf x, const gf y, const gf z, mask_t is_z)
{
- constant_time_select(x, y, z, sizeof(gf), is_z, 0);
+ constant_time_select_c448(x, y, z, sizeof(gf), is_z, 0);
}
/* Constant time, if (neg) x=-x; */