On Tue, Apr 29, 2025 at 09:41:00AM -0700, Eric Biggers wrote: > > 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 There aren't any direct dependencies but if you end up executing the code protected by those static branches things may well break. For example, fpu_state_size_dynamic() is only initialised at arch_initcall. So if you enable these lib/crypto static branches, *and* someone actually calls them early enough during arch_initcall, they may end up hitting the FPU code before it's been properly initialised. I think it's prudent to delay the initialisation of these static keys until later in the boot process, unless there is a demonstrated need for accessing them early. > use arch_initcall. (And FWIW I'll keep doing that arch/*/lib/crc*.c, even if > you decide to mess up arch/*/lib/crypto/.) I'm not going to touch the crc stuff. Cheers, -- Email: Herbert Xu <herbert@xxxxxxxxxxxxxxxxxxx> Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt