mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Guenter Roeck <linux@roeck-us.net>
To: Ard Biesheuvel <ardb@kernel.org>
Cc: Eric Biggers <ebiggers@kernel.org>,
	linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	linux-crypto@vger.kernel.org, linuxppc-dev@lists.ozlabs.org,
	x86@kernel.org, Zhihang Shao <zhihang.shao.iscas@gmail.com>,
	Vinicius Peixoto <vpeixoto@lkcamp.dev>,
	"Martin K. Petersen" <martin.petersen@oracle.com>
Subject: Re: [PATCH v2 08/12] lib/crc_kunit.c: add KUnit test suite for CRC library functions
Date: Sun, 23 Mar 2025 09:18:58 -0700	[thread overview]
Message-ID: <22812c03-1b64-4e1c-b260-cddc14ea3e8f@roeck-us.net> (raw)
In-Reply-To: <CAMj1kXHAktbQ-605wfqXCWtn8bP-yEv8sYKWAykajeAX2m1hEA@mail.gmail.com>

On 3/23/25 08:35, Ard Biesheuvel wrote:
[ ... ]
>> kernel_neon_end() calls local_bh_enable() which apparently conflicts with
>> the local_irq_disable() in above code.
>>
> 
> This seems to be an oversight on my part. Can you try the below please?
> 
> diff --git a/arch/arm/include/asm/simd.h b/arch/arm/include/asm/simd.h
> index 82191dbd7e78..56ddbd3c4997 100644
> --- a/arch/arm/include/asm/simd.h
> +++ b/arch/arm/include/asm/simd.h
> @@ -4,5 +4,6 @@
> 
>   static __must_check inline bool may_use_simd(void)
>   {
> -       return IS_ENABLED(CONFIG_KERNEL_MODE_NEON) && !in_hardirq();
> +       return IS_ENABLED(CONFIG_KERNEL_MODE_NEON) &&
> +              !in_hardirq() && !irqs_disabled();
>   }
> 
Yes, that fixes the problem.

Thanks,
Guenter


  reply	other threads:[~2025-03-23 16:19 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-02  1:20 [PATCH v2 00/12] Wire up CRC-T10DIF library functions to arch-optimized code Eric Biggers
2024-12-02  1:20 ` [PATCH v2 01/12] lib/crc-t10dif: stop wrapping the crypto API Eric Biggers
2024-12-02  1:20 ` [PATCH v2 02/12] lib/crc-t10dif: add support for arch overrides Eric Biggers
2024-12-02  1:20 ` [PATCH v2 03/12] crypto: crct10dif - expose arch-optimized lib function Eric Biggers
2024-12-02  1:20 ` [PATCH v2 04/12] x86/crc-t10dif: expose CRC-T10DIF function through lib Eric Biggers
2024-12-02  1:20 ` [PATCH v2 05/12] arm/crc-t10dif: " Eric Biggers
2024-12-02  1:20 ` [PATCH v2 06/12] arm64/crc-t10dif: " Eric Biggers
2024-12-02  1:20 ` [PATCH v2 07/12] powerpc/crc-t10dif: " Eric Biggers
2024-12-02  1:20 ` [PATCH v2 08/12] lib/crc_kunit.c: add KUnit test suite for CRC library functions Eric Biggers
2025-03-22 14:33   ` Guenter Roeck
2025-03-23 15:35     ` Ard Biesheuvel
2025-03-23 16:18       ` Guenter Roeck [this message]
2025-03-23 17:12       ` Eric Biggers
2025-03-23 18:17         ` Ard Biesheuvel
2024-12-02  1:20 ` [PATCH v2 09/12] lib/crc16_kunit: delete obsolete crc16_kunit.c Eric Biggers
2024-12-02  1:20 ` [PATCH v2 10/12] lib/crc32test: delete obsolete crc32test.c Eric Biggers
2024-12-02  8:33   ` Geert Uytterhoeven
2024-12-02  1:20 ` [PATCH v2 11/12] powerpc/crc: delete obsolete crc-vpmsum_test.c Eric Biggers
2024-12-02  1:20 ` [PATCH v2 12/12] MAINTAINERS: add entry for CRC library Eric Biggers
2024-12-12 21:36 ` [PATCH v2 00/12] Wire up CRC-T10DIF library functions to arch-optimized code Eric Biggers

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=22812c03-1b64-4e1c-b260-cddc14ea3e8f@roeck-us.net \
    --to=linux@roeck-us.net \
    --cc=ardb@kernel.org \
    --cc=ebiggers@kernel.org \
    --cc=linux-arch@vger.kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-crypto@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=martin.petersen@oracle.com \
    --cc=vpeixoto@lkcamp.dev \
    --cc=x86@kernel.org \
    --cc=zhihang.shao.iscas@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®