Re: [PATCH 8/9] crypto: x86/chacha - remove the skcipher algorithms

From: Eric Biggers
Date: Thu Apr 17 2025 - 23:38:42 EST


On Fri, Apr 18, 2025 at 11:24:01AM +0800, Herbert Xu wrote:
> Eric Biggers <ebiggers@xxxxxxxxxx> wrote:
> >
> > -static void __exit chacha_simd_mod_fini(void)
> > -{
> > - if (IS_REACHABLE(CONFIG_CRYPTO_SKCIPHER) && boot_cpu_has(X86_FEATURE_SSSE3))
> > - crypto_unregister_skciphers(algs, ARRAY_SIZE(algs));
> > -}
> > -
> > arch_initcall(chacha_simd_mod_init);
> > -module_exit(chacha_simd_mod_fini);
>
> Why did you remove the ability to remove the module?
>

Well, I forgot that an empty module_exit needs to be kept around for the module
to be removable. I'll send a patch that adds these back in, though I'm doubtful
that anyone ever removes these modules in practice.

- Eric