public inbox for linux-crypto@vger.kernel.org
 help / color / mirror / Atom feed
From: Eric Biggers <ebiggers@kernel.org>
To: Herbert Xu <herbert@gondor.apana.org.au>
Cc: Linux Crypto Mailing List <linux-crypto@vger.kernel.org>
Subject: Re: [PATCH 1/1] Revert "crypto: run initcalls for generic implementations earlier"
Date: Tue, 29 Apr 2025 09:41:00 -0700	[thread overview]
Message-ID: <20250429164100.GA1743@sol.localdomain> (raw)
In-Reply-To: <aBBoqm4u6ufapUXK@gondor.apana.org.au>

On Tue, Apr 29, 2025 at 01:50:34PM +0800, Herbert Xu wrote:
> diff --git a/arch/arm/lib/crypto/chacha-glue.c b/arch/arm/lib/crypto/chacha-glue.c
> index 12afb40cf1ff..eb73ff0eaf2e 100644
> --- a/arch/arm/lib/crypto/chacha-glue.c
> +++ b/arch/arm/lib/crypto/chacha-glue.c
> @@ -122,7 +122,7 @@ static int __init chacha_arm_mod_init(void)
>  	}
>  	return 0;
>  }
> -arch_initcall(chacha_arm_mod_init);
> +module_init(chacha_arm_mod_init);

arch/*/lib/ should be kept at arch_initcall.  It makes sense (it's arch/ code);
it's library code with no dependencies on any other initcalls; and it can be
used during initialization of other modules, notably with crypto/ depending on
*_is_arch_optimized().  I understand that this patch sets the initcall level
conditionally depending on whether each individual file uses static keys in
*_is_arch_optimized() or not, but there's no need to add that complexity.  Just
use arch_initcall.  (And FWIW I'll keep doing that arch/*/lib/crc*.c, even if
you decide to mess up arch/*/lib/crypto/.)

- Eric

  reply	other threads:[~2025-04-29 16:41 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-04-29  5:50 [PATCH 1/1] Revert "crypto: run initcalls for generic implementations earlier" Herbert Xu
2025-04-29 16:41 ` Eric Biggers [this message]
2025-04-30  2:21   ` Herbert Xu
2025-04-30  3:16     ` Eric Biggers
2025-04-30  3:18       ` Herbert Xu
2025-04-30  8:17 ` [v2 PATCH] " Herbert Xu
2025-04-30 17:52   ` Eric Biggers
2025-06-05 14:29   ` Lukas Wunner
2025-06-09  9:44     ` Herbert Xu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250429164100.GA1743@sol.localdomain \
    --to=ebiggers@kernel.org \
    --cc=herbert@gondor.apana.org.au \
    --cc=linux-crypto@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox