diff options
author | Matt Caswell <matt@openssl.org> | 2018-01-18 12:55:23 +0000 |
---|---|---|
committer | Matt Caswell <matt@openssl.org> | 2018-02-20 12:59:30 +0000 |
commit | 094c071cbf3bca19eee73ccb8dfc0f7498f5d8e1 (patch) | |
tree | 44c29c291ced1cf7142111fe328e642e279fd146 /crypto/ec/curve448/field.h | |
parent | bb6e60adc5d02d903cbbf92cf7b1d7152fb4a905 (diff) |
Convert to C90 from C99
Reviewed-by: Bernd Edlinger <bernd.edlinger@hotmail.de>
(Merged from https://github.com/openssl/openssl/pull/5105)
Diffstat (limited to 'crypto/ec/curve448/field.h')
-rw-r--r-- | crypto/ec/curve448/field.h | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/crypto/ec/curve448/field.h b/crypto/ec/curve448/field.h index 672ee3623e..1b64b47eac 100644 --- a/crypto/ec/curve448/field.h +++ b/crypto/ec/curve448/field.h @@ -39,21 +39,21 @@ static ossl_inline void gf_sqrn ( #define gf_add_nr gf_add_RAW /** Subtract mod p. Bias by 2 and don't reduce */ -static inline void gf_sub_nr ( gf c, const gf a, const gf b ) { +static ossl_inline void gf_sub_nr ( gf c, const gf a, const gf b ) { gf_sub_RAW(c,a,b); gf_bias(c, 2); if (GF_HEADROOM < 3) gf_weak_reduce(c); } /** Subtract mod p. Bias by amt but don't reduce. */ -static inline void gf_subx_nr ( gf c, const gf a, const gf b, int amt ) { +static ossl_inline void gf_subx_nr ( gf c, const gf a, const gf b, int amt ) { gf_sub_RAW(c,a,b); gf_bias(c, amt); if (GF_HEADROOM < amt+1) gf_weak_reduce(c); } /** Mul by signed int. Not constant-time WRT the sign of that int. */ -static inline void gf_mulw(gf c, const gf a, int32_t w) { +static ossl_inline void gf_mulw(gf c, const gf a, int32_t w) { if (w>0) { gf_mulw_unsigned(c, a, w); } else { @@ -63,19 +63,19 @@ static inline void gf_mulw(gf c, const gf a, int32_t w) { } /** Constant time, x = is_z ? z : y */ -static inline void gf_cond_sel(gf x, const gf y, const gf z, mask_t is_z) { +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, if (neg) x=-x; */ -static inline void gf_cond_neg(gf x, mask_t neg) { +static ossl_inline void gf_cond_neg(gf x, mask_t neg) { gf y; gf_sub(y,ZERO,x); gf_cond_sel(x,x,y,neg); } /** Constant time, if (swap) (x,y) = (y,x); */ -static inline void +static ossl_inline void gf_cond_swap(gf x, gf_s *__restrict__ y, mask_t swap) { constant_time_cond_swap(x,y,sizeof(gf_s),swap); } @@ -89,4 +89,4 @@ static ossl_inline void gf_div_qnr(gf_s *__restrict__ out, const gf x) { } -#endif // __GF_H__ +#endif /* __GF_H__ */ |