On 3/5/21 3:59 PM, Stefan Berger wrote:
diff --git a/crypto/Kconfig b/crypto/Kconfig
index a367fcfeb5d4..a31df40591f5 100644
--- a/crypto/Kconfig
+++ b/crypto/Kconfig
@@ -247,6 +247,16 @@ config CRYPTO_ECDH
        help
          Generic implementation of the ECDH algorithm
@@ -70,6 +72,30 @@ struct ecc_curve {
        u64 *b;
  };
+/**
+ * ecc_swap_digits() - Copy ndigits from big endian array to native array
+ * @in:       Input array
+ * @out:      Output array
+ * @ndigits:  Number of digits to copy
+ */
+static inline void ecc_swap_digits(const u64 *in, u64 *out, unsigned int 
ndigits)
+{
+       const __be64 *src = (__force __be64 *)in;
+       int i;
+
+       for (i = 0; i < ndigits; i++)
+               out[i] = be64_to_cpu(src[ndigits - 1 - i]);
+}
+
+/**
+ * ecc_get_curve()  - Get a curve given its curve_id
+ *

There's still an additional empty line here (as is the case with other existing functions in this file). I will fix this one in v12.


Reply via email to