lib/crypto: poly1305: Remove unused function poly1305_is_arch_optimized()
poly1305_is_arch_optimized() is unused, so remove it. Reviewed-by: Ard Biesheuvel <ardb@kernel.org> Link: https://lore.kernel.org/r/20250829152513.92459-2-ebiggers@kernel.org Signed-off-by: Eric Biggers <ebiggers@kernel.org>
This commit is contained in:
parent
5012bd2dc6
commit
df220cc5e6
|
|
@ -64,13 +64,4 @@ void poly1305_update(struct poly1305_desc_ctx *desc,
|
|||
const u8 *src, unsigned int nbytes);
|
||||
void poly1305_final(struct poly1305_desc_ctx *desc, u8 *digest);
|
||||
|
||||
#if IS_ENABLED(CONFIG_CRYPTO_ARCH_HAVE_LIB_POLY1305)
|
||||
bool poly1305_is_arch_optimized(void);
|
||||
#else
|
||||
static inline bool poly1305_is_arch_optimized(void)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -51,13 +51,6 @@ void poly1305_blocks_arch(struct poly1305_block_state *state, const u8 *src,
|
|||
}
|
||||
EXPORT_SYMBOL_GPL(poly1305_blocks_arch);
|
||||
|
||||
bool poly1305_is_arch_optimized(void)
|
||||
{
|
||||
/* We always can use at least the ARM scalar implementation. */
|
||||
return true;
|
||||
}
|
||||
EXPORT_SYMBOL(poly1305_is_arch_optimized);
|
||||
|
||||
static int __init arm_poly1305_mod_init(void)
|
||||
{
|
||||
if (IS_ENABLED(CONFIG_KERNEL_MODE_NEON) &&
|
||||
|
|
|
|||
|
|
@ -50,13 +50,6 @@ void poly1305_blocks_arch(struct poly1305_block_state *state, const u8 *src,
|
|||
}
|
||||
EXPORT_SYMBOL_GPL(poly1305_blocks_arch);
|
||||
|
||||
bool poly1305_is_arch_optimized(void)
|
||||
{
|
||||
/* We always can use at least the ARM64 scalar implementation. */
|
||||
return true;
|
||||
}
|
||||
EXPORT_SYMBOL(poly1305_is_arch_optimized);
|
||||
|
||||
static int __init neon_poly1305_mod_init(void)
|
||||
{
|
||||
if (cpu_have_named_feature(ASIMD))
|
||||
|
|
|
|||
|
|
@ -23,11 +23,5 @@ asmlinkage void poly1305_emit_arch(const struct poly1305_state *state,
|
|||
const u32 nonce[4]);
|
||||
EXPORT_SYMBOL_GPL(poly1305_emit_arch);
|
||||
|
||||
bool poly1305_is_arch_optimized(void)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
EXPORT_SYMBOL(poly1305_is_arch_optimized);
|
||||
|
||||
MODULE_DESCRIPTION("Poly1305 transform (MIPS accelerated");
|
||||
MODULE_LICENSE("GPL v2");
|
||||
|
|
|
|||
|
|
@ -72,12 +72,6 @@ void poly1305_emit_arch(const struct poly1305_state *state,
|
|||
}
|
||||
EXPORT_SYMBOL_GPL(poly1305_emit_arch);
|
||||
|
||||
bool poly1305_is_arch_optimized(void)
|
||||
{
|
||||
return static_key_enabled(&have_p10);
|
||||
}
|
||||
EXPORT_SYMBOL(poly1305_is_arch_optimized);
|
||||
|
||||
static int __init poly1305_p10_init(void)
|
||||
{
|
||||
if (cpu_has_feature(CPU_FTR_ARCH_31))
|
||||
|
|
|
|||
|
|
@ -141,12 +141,6 @@ void poly1305_emit_arch(const struct poly1305_state *ctx,
|
|||
}
|
||||
EXPORT_SYMBOL_GPL(poly1305_emit_arch);
|
||||
|
||||
bool poly1305_is_arch_optimized(void)
|
||||
{
|
||||
return static_key_enabled(&poly1305_use_avx);
|
||||
}
|
||||
EXPORT_SYMBOL(poly1305_is_arch_optimized);
|
||||
|
||||
static int __init poly1305_simd_mod_init(void)
|
||||
{
|
||||
if (boot_cpu_has(X86_FEATURE_AVX) &&
|
||||
|
|
|
|||
Loading…
Reference in New Issue