diff options
author | Tudor-Dan Ambarus <tudor.ambarus@microchip.com> | 2017-05-30 15:37:56 +0300 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2017-06-10 12:04:26 +0800 |
commit | 7380c56d2fcaa882a0809aad075c3f9fdc3b3c50 (patch) | |
tree | 1cd2fc5ea63a74f05017378f953cd0124e2ec4f7 | |
parent | ad269597107e6dde4810987eebbd075778d0262c (diff) | |
download | linux-7380c56d2fcaa882a0809aad075c3f9fdc3b3c50.tar.gz linux-7380c56d2fcaa882a0809aad075c3f9fdc3b3c50.tar.bz2 linux-7380c56d2fcaa882a0809aad075c3f9fdc3b3c50.zip |
crypto: ecc - rename ecdh_make_pub_key()
Rename ecdh_make_pub_key() to ecc_make_pub_key().
ecdh_make_pub_key() is not dh specific and the reference
to dh is wrong.
Signed-off-by: Tudor Ambarus <tudor.ambarus@microchip.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
-rw-r--r-- | crypto/ecc.c | 4 | ||||
-rw-r--r-- | crypto/ecc.h | 6 | ||||
-rw-r--r-- | crypto/ecdh.c | 4 |
3 files changed, 7 insertions, 7 deletions
diff --git a/crypto/ecc.c b/crypto/ecc.c index e3a2b8f78a38..6c33c4323d6a 100644 --- a/crypto/ecc.c +++ b/crypto/ecc.c @@ -927,8 +927,8 @@ int ecc_is_key_valid(unsigned int curve_id, unsigned int ndigits, return 0; } -int ecdh_make_pub_key(unsigned int curve_id, unsigned int ndigits, - const u64 *private_key, u64 *public_key) +int ecc_make_pub_key(unsigned int curve_id, unsigned int ndigits, + const u64 *private_key, u64 *public_key) { int ret = 0; struct ecc_point *pk; diff --git a/crypto/ecc.h b/crypto/ecc.h index af2ffdb2dcd6..e13fe8800ee8 100644 --- a/crypto/ecc.h +++ b/crypto/ecc.h @@ -44,7 +44,7 @@ int ecc_is_key_valid(unsigned int curve_id, unsigned int ndigits, const u64 *private_key, unsigned int private_key_len); /** - * ecdh_make_pub_key() - Compute an ECC public key + * ecc_make_pub_key() - Compute an ECC public key * * @curve_id: id representing the curve to use * @ndigits: curve's number of digits @@ -54,8 +54,8 @@ int ecc_is_key_valid(unsigned int curve_id, unsigned int ndigits, * Returns 0 if the public key was generated successfully, a negative value * if an error occurred. */ -int ecdh_make_pub_key(const unsigned int curve_id, unsigned int ndigits, - const u64 *private_key, u64 *public_key); +int ecc_make_pub_key(const unsigned int curve_id, unsigned int ndigits, + const u64 *private_key, u64 *public_key); /** * crypto_ecdh_shared_secret() - Compute a shared secret diff --git a/crypto/ecdh.c b/crypto/ecdh.c index c1f01630faad..ed1464a5ce1b 100644 --- a/crypto/ecdh.c +++ b/crypto/ecdh.c @@ -87,8 +87,8 @@ static int ecdh_compute_value(struct kpp_request *req) buf = ctx->shared_secret; } else { - ret = ecdh_make_pub_key(ctx->curve_id, ctx->ndigits, - ctx->private_key, ctx->public_key); + ret = ecc_make_pub_key(ctx->curve_id, ctx->ndigits, + ctx->private_key, ctx->public_key); buf = ctx->public_key; /* Public part is a point thus it has both coordinates */ nbytes *= 2; |