linux-crypto.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] crypto: x86/sha256 - Include asm/fpu/api.h directly
@ 2025-04-23 16:25 Arnd Bergmann
  2025-04-24  0:56 ` Herbert Xu
  0 siblings, 1 reply; 2+ messages in thread
From: Arnd Bergmann @ 2025-04-23 16:25 UTC (permalink / raw)
  To: Herbert Xu, David S. Miller, Thomas Gleixner, Ingo Molnar,
	Borislav Petkov, Dave Hansen, x86
  Cc: Arnd Bergmann, H. Peter Anvin, Uros Bizjak, Eric Biggers,
	linux-crypto, linux-kernel

From: Arnd Bergmann <arnd@arndb.de>

This was previously included through another header, but now causes
a build failure in some configurations:

arch/x86/crypto/sha256_ssse3_glue.c:63:2: error: call to undeclared function 'kernel_fpu_begin'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
   63 |         kernel_fpu_begin();
      |         ^
arch/x86/crypto/sha256_ssse3_glue.c:65:2: error: call to undeclared function 'kernel_fpu_end'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
   65 |         kernel_fpu_end();
      |         ^

Include the header directly to make it build again.

Fixes: 8e7547473875 ("crypto: x86/sha256 - Use API partial block handling")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 arch/x86/crypto/sha256_ssse3_glue.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/x86/crypto/sha256_ssse3_glue.c b/arch/x86/crypto/sha256_ssse3_glue.c
index b3115e207a9f..42b0bb6c8caf 100644
--- a/arch/x86/crypto/sha256_ssse3_glue.c
+++ b/arch/x86/crypto/sha256_ssse3_glue.c
@@ -36,6 +36,8 @@
 #include <linux/kernel.h>
 #include <linux/module.h>
 
+#include <asm/fpu/api.h>
+
 asmlinkage void sha256_transform_ssse3(struct crypto_sha256_state *state,
 				       const u8 *data, int blocks);
 
-- 
2.39.5


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] crypto: x86/sha256 - Include asm/fpu/api.h directly
  2025-04-23 16:25 [PATCH] crypto: x86/sha256 - Include asm/fpu/api.h directly Arnd Bergmann
@ 2025-04-24  0:56 ` Herbert Xu
  0 siblings, 0 replies; 2+ messages in thread
From: Herbert Xu @ 2025-04-24  0:56 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: David S. Miller, Thomas Gleixner, Ingo Molnar, Borislav Petkov,
	Dave Hansen, x86, Arnd Bergmann, H. Peter Anvin, Uros Bizjak,
	Eric Biggers, linux-crypto, linux-kernel

On Wed, Apr 23, 2025 at 06:25:45PM +0200, Arnd Bergmann wrote:
> From: Arnd Bergmann <arnd@arndb.de>
> 
> This was previously included through another header, but now causes
> a build failure in some configurations:
> 
> arch/x86/crypto/sha256_ssse3_glue.c:63:2: error: call to undeclared function 'kernel_fpu_begin'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
>    63 |         kernel_fpu_begin();
>       |         ^
> arch/x86/crypto/sha256_ssse3_glue.c:65:2: error: call to undeclared function 'kernel_fpu_end'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
>    65 |         kernel_fpu_end();
>       |         ^
> 
> Include the header directly to make it build again.
> 
> Fixes: 8e7547473875 ("crypto: x86/sha256 - Use API partial block handling")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
>  arch/x86/crypto/sha256_ssse3_glue.c | 2 ++
>  1 file changed, 2 insertions(+)

Sorry, I had pushed out the wrong tree.  It should be fixed in
cryptodev already:

https://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6.git/commit/?id=eba187a6e7141a1166a68c4d27b4ee5a27670b3b

Thanks,
-- 
Email: Herbert Xu <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2025-04-24  0:57 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-04-23 16:25 [PATCH] crypto: x86/sha256 - Include asm/fpu/api.h directly Arnd Bergmann
2025-04-24  0:56 ` Herbert Xu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).