Le 17/10/2025 à 16:42, David Howells a écrit :
Rename the arm64 sha3_* functions to have an "arm64_" prefix to avoid
conflict with generic code.

Same comment as previous patch, the functions are static, why would they conflict with generic code ?

Also generic code doesn't have such functions at the moment, are they added by a follow patch ?

Christophe



Signed-off-by: David Howells <[email protected]>
cc: Eric Biggers <[email protected]>
cc: Jason A. Donenfeld <[email protected]>
cc: Ard Biesheuvel <[email protected]>
cc: Catalin Marinas <[email protected]>
cc: Will Deacon <[email protected]>
cc: Herbert Xu <[email protected]>
cc: Stephan Mueller <[email protected]>
cc: [email protected]
cc: [email protected]
---
  arch/arm64/crypto/sha3-ce-glue.c | 22 +++++++++++-----------
  1 file changed, 11 insertions(+), 11 deletions(-)

diff --git a/arch/arm64/crypto/sha3-ce-glue.c b/arch/arm64/crypto/sha3-ce-glue.c
index b4f1001046c9..426d8044535a 100644
--- a/arch/arm64/crypto/sha3-ce-glue.c
+++ b/arch/arm64/crypto/sha3-ce-glue.c
@@ -31,7 +31,7 @@ MODULE_ALIAS_CRYPTO("sha3-512");
  asmlinkage int sha3_ce_transform(u64 *st, const u8 *data, int blocks,
                                 int md_len);
-static int sha3_update(struct shash_desc *desc, const u8 *data,
+static int arm64_sha3_update(struct shash_desc *desc, const u8 *data,
                       unsigned int len)
  {
        struct sha3_state *sctx = shash_desc_ctx(desc);
@@ -55,8 +55,8 @@ static int sha3_update(struct shash_desc *desc, const u8 
*data,
        return len;
  }
-static int sha3_finup(struct shash_desc *desc, const u8 *src, unsigned int len,
-                     u8 *out)
+static int arm64_sha3_finup(struct shash_desc *desc, const u8 *src, unsigned 
int len,
+                           u8 *out)
  {
        struct sha3_state *sctx = shash_desc_ctx(desc);
        struct crypto_shash *tfm = desc->tfm;
@@ -90,8 +90,8 @@ static int sha3_finup(struct shash_desc *desc, const u8 *src, 
unsigned int len,
  static struct shash_alg algs[] = { {
        .digestsize             = SHA3_224_DIGEST_SIZE,
        .init                   = crypto_sha3_init,
-       .update                 = sha3_update,
-       .finup                  = sha3_finup,
+       .update                 = arm64_sha3_update,
+       .finup                  = arm64_sha3_finup,
        .descsize               = SHA3_STATE_SIZE,
        .base.cra_name          = "sha3-224",
        .base.cra_driver_name   = "sha3-224-ce",
@@ -102,8 +102,8 @@ static struct shash_alg algs[] = { {
  }, {
        .digestsize             = SHA3_256_DIGEST_SIZE,
        .init                   = crypto_sha3_init,
-       .update                 = sha3_update,
-       .finup                  = sha3_finup,
+       .update                 = arm64_sha3_update,
+       .finup                  = arm64_sha3_finup,
        .descsize               = SHA3_STATE_SIZE,
        .base.cra_name          = "sha3-256",
        .base.cra_driver_name   = "sha3-256-ce",
@@ -114,8 +114,8 @@ static struct shash_alg algs[] = { {
  }, {
        .digestsize             = SHA3_384_DIGEST_SIZE,
        .init                   = crypto_sha3_init,
-       .update                 = sha3_update,
-       .finup                  = sha3_finup,
+       .update                 = arm64_sha3_update,
+       .finup                  = arm64_sha3_finup,
        .descsize               = SHA3_STATE_SIZE,
        .base.cra_name          = "sha3-384",
        .base.cra_driver_name   = "sha3-384-ce",
@@ -126,8 +126,8 @@ static struct shash_alg algs[] = { {
  }, {
        .digestsize             = SHA3_512_DIGEST_SIZE,
        .init                   = crypto_sha3_init,
-       .update                 = sha3_update,
-       .finup                  = sha3_finup,
+       .update                 = arm64_sha3_update,
+       .finup                  = arm64_sha3_finup,
        .descsize               = SHA3_STATE_SIZE,
        .base.cra_name          = "sha3-512",
        .base.cra_driver_name   = "sha3-512-ce",




Reply via email to