[PATCH v3 03/21] crypto/arm64: sm4-ce-gcm - Avoid pointless yield of the NEON unit
Eric Biggers
ebiggers at kernel.org
Fri Oct 17 10:04:56 PDT 2025
On Wed, Oct 08, 2025 at 05:45:37PM +0200, Ard Biesheuvel wrote:
> From: Ard Biesheuvel <ardb at kernel.org>
>
> Kernel mode NEON sections are now preemptible on arm64, and so there is
> no need to yield it when calling APIs that may sleep.
>
> Also, move the calls to kernel_neon_end() to the same scope as
> kernel_neon_begin(). This is needed for a subsequent change where a
> stack buffer is allocated transparently and passed to
> kernel_neon_begin().
>
> While at it, simplify the logic.
>
> Acked-by: Eric Biggers <ebiggers at kernel.org>
> [ardb: Simplify convoluted logic]
> Signed-off-by: Ard Biesheuvel <ardb at kernel.org>
> ---
> arch/arm64/crypto/sm4-ce-gcm-glue.c | 25 +++++---------------
> 1 file changed, 6 insertions(+), 19 deletions(-)
Reviewed-by: Eric Biggers <ebiggers at kernel.org>
- Eric
More information about the linux-arm-kernel
mailing list