include/crypto/algapi.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Hi all,
After merging the crypto tree, today's linux-next build (powerpc
ppc64_defconfig) failed like this:
In file included from include/crypto/algapi.h:10,
from include/crypto/internal/hash.h:11,
from arch/powerpc/crypto/sha1.c:15:
arch/powerpc/include/asm/cache.h:40:9: error: unknown type name 'u32'
40 | u32 size;
| ^~~
arch/powerpc/include/asm/cache.h:41:9: error: unknown type name 'u32'
41 | u32 line_size;
| ^~~
(and so on ... lots of errors)
Caused by commit
e634ac4a8aaa ("crypto: api - Add crypto_tfm_ctx_dma")
It could be (easily) argued that arch/powerpc/include/asm/cache.h should
include linus/types.h, but it is also unusual to include an asm/... file
before all the linux/... files.
Anyway, I applied the following patch for today.
From: Stephen Rothwell <sfr@canb.auug.org.au>
Date: Mon, 5 Dec 2022 10:42:57 +1100
Subject: [PATCH] fix up for "crypto: api - Add crypto_tfm_ctx_dma"
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
---
include/crypto/algapi.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/crypto/algapi.h b/include/crypto/algapi.h
index 8722fd67f40a..fced47dbd306 100644
--- a/include/crypto/algapi.h
+++ b/include/crypto/algapi.h
@@ -7,13 +7,13 @@
#ifndef _CRYPTO_ALGAPI_H
#define _CRYPTO_ALGAPI_H
-#include <asm/cache.h>
#include <linux/align.h>
#include <linux/crypto.h>
#include <linux/kconfig.h>
#include <linux/list.h>
#include <linux/types.h>
+#include <asm/cache.h>
#include <asm/unaligned.h>
/*
--
2.35.1
--
Cheers,
Stephen Rothwell
Hi all, On Mon, 5 Dec 2022 10:48:57 +1100 Stephen Rothwell <sfr@canb.auug.org.au> wrote: > > It could be (easily) argued that arch/powerpc/include/asm/cache.h should > include linus/types.h, but it is also unusual to include an asm/... file > before all the linux/... files. Or maybe you should have included linux/cache.h instead of asm/cache.h? -- Cheers, Stephen Rothwell
On Mon, Dec 05, 2022 at 10:52:25AM +1100, Stephen Rothwell wrote:
>
> Or maybe you should have included linux/cache.h instead of asm/cache.h?
You're right Stephen. Thanks!
---8<---
Directly including asm/cache.h leads to build failures on powerpc
so replace it with linux/cache.h instead.
Fixes: e634ac4a8aaa ("crypto: api - Add crypto_tfm_ctx_dma")
Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
diff --git a/include/crypto/algapi.h b/include/crypto/algapi.h
index 8722fd67f40a..61b327206b55 100644
--- a/include/crypto/algapi.h
+++ b/include/crypto/algapi.h
@@ -7,8 +7,8 @@
#ifndef _CRYPTO_ALGAPI_H
#define _CRYPTO_ALGAPI_H
-#include <asm/cache.h>
#include <linux/align.h>
+#include <linux/cache.h>
#include <linux/crypto.h>
#include <linux/kconfig.h>
#include <linux/list.h>
--
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
© 2016 - 2025 Red Hat, Inc.