From 8ac6c7a54ed1b98d142dce24b11c6de6a1e239a5 Mon Sep 17 00:00:00 2001 From: hc <hc@nodka.com> Date: Tue, 22 Oct 2024 10:36:11 +0000 Subject: [PATCH] 修改4g拨号为QMI,需要在系统里后台执行quectel-CM --- kernel/arch/arm/crypto/poly1305-glue.c | 7 ++++--- 1 files changed, 4 insertions(+), 3 deletions(-) diff --git a/kernel/arch/arm/crypto/poly1305-glue.c b/kernel/arch/arm/crypto/poly1305-glue.c index 066e6a8..c31bd8f 100644 --- a/kernel/arch/arm/crypto/poly1305-glue.c +++ b/kernel/arch/arm/crypto/poly1305-glue.c @@ -12,6 +12,7 @@ #include <crypto/algapi.h> #include <crypto/internal/hash.h> #include <crypto/internal/poly1305.h> +#include <crypto/internal/simd.h> #include <linux/cpufeature.h> #include <linux/crypto.h> #include <linux/jump_label.h> @@ -28,7 +29,7 @@ static __ro_after_init DEFINE_STATIC_KEY_FALSE(have_neon); -void poly1305_init_arch(struct poly1305_desc_ctx *dctx, const u8 *key) +void poly1305_init_arch(struct poly1305_desc_ctx *dctx, const u8 key[POLY1305_KEY_SIZE]) { poly1305_init_arm(&dctx->h, key); dctx->s[0] = get_unaligned_le32(key + 16); @@ -125,7 +126,7 @@ unsigned int srclen) { struct poly1305_desc_ctx *dctx = shash_desc_ctx(desc); - bool do_neon = may_use_simd() && srclen > 128; + bool do_neon = crypto_simd_usable() && srclen > 128; if (static_branch_likely(&have_neon) && do_neon) kernel_neon_begin(); @@ -139,7 +140,7 @@ unsigned int nbytes) { bool do_neon = IS_ENABLED(CONFIG_KERNEL_MODE_NEON) && - may_use_simd(); + crypto_simd_usable(); if (unlikely(dctx->buflen)) { u32 bytes = min(nbytes, POLY1305_BLOCK_SIZE - dctx->buflen); -- Gitblit v1.6.2