linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] crypto: aspeed: fix build module error
@ 2022-08-29  7:20 Neal Liu
  2022-08-29 10:49 ` Sudip Mukherjee
  2022-09-02 10:29 ` Herbert Xu
  0 siblings, 2 replies; 4+ messages in thread
From: Neal Liu @ 2022-08-29  7:20 UTC (permalink / raw)
  To: Herbert Xu, David S . Miller, Joel Stanley, Andrew Jeffery
  Cc: linux-aspeed, linux-crypto, linux-arm-kernel, linux-kernel,
	BMC-SW, kernel test robot

If CONFIG_MODULES=y and CONFIG_CRYPTO_DEV_ASPEED=m,
build modpost would be failed.

Error messages:
  ERROR: modpost: "aspeed_register_hace_hash_algs"
  [drivers/crypto/aspeed/aspeed_crypto.ko] undefined!
  ERROR: modpost: "aspeed_unregister_hace_hash_algs"
  [drivers/crypto/aspeed/aspeed_crypto.ko] undefined!

Change build sequence to fix this.

Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Neal Liu <neal_liu@aspeedtech.com>
---
 drivers/crypto/aspeed/Makefile | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/crypto/aspeed/Makefile b/drivers/crypto/aspeed/Makefile
index 421e2ca9c53e..4cc1a7ad3652 100644
--- a/drivers/crypto/aspeed/Makefile
+++ b/drivers/crypto/aspeed/Makefile
@@ -1,9 +1,9 @@
-obj-$(CONFIG_CRYPTO_DEV_ASPEED) += aspeed_crypto.o
-aspeed_crypto-objs := aspeed-hace.o	\
-		      $(hace-hash-y)	\
-		      $(hace-crypto-y)
-
 obj-$(CONFIG_CRYPTO_DEV_ASPEED_HACE_HASH) += aspeed-hace-hash.o
 hace-hash-$(CONFIG_CRYPTO_DEV_ASPEED_HACE_HASH) := aspeed-hace-hash.o
 obj-$(CONFIG_CRYPTO_DEV_ASPEED_HACE_CRYPTO) += aspeed-hace-crypto.o
 hace-crypto-$(CONFIG_CRYPTO_DEV_ASPEED_HACE_CRYPTO) := aspeed-hace-crypto.o
+
+obj-$(CONFIG_CRYPTO_DEV_ASPEED) += aspeed_crypto.o
+aspeed_crypto-objs := aspeed-hace.o	\
+		      $(hace-hash-y)	\
+		      $(hace-crypto-y)
-- 
2.25.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* Re: [PATCH] crypto: aspeed: fix build module error
  2022-08-29  7:20 [PATCH] crypto: aspeed: fix build module error Neal Liu
@ 2022-08-29 10:49 ` Sudip Mukherjee
  2022-09-02 10:29 ` Herbert Xu
  1 sibling, 0 replies; 4+ messages in thread
From: Sudip Mukherjee @ 2022-08-29 10:49 UTC (permalink / raw)
  To: Neal Liu
  Cc: Herbert Xu, David S . Miller, Joel Stanley, Andrew Jeffery,
	linux-aspeed, linux-crypto, linux-arm-kernel, linux-kernel,
	BMC-SW, kernel test robot

On Mon, Aug 29, 2022 at 8:42 AM Neal Liu <neal_liu@aspeedtech.com> wrote:
>
> If CONFIG_MODULES=y and CONFIG_CRYPTO_DEV_ASPEED=m,
> build modpost would be failed.
>
> Error messages:
>   ERROR: modpost: "aspeed_register_hace_hash_algs"
>   [drivers/crypto/aspeed/aspeed_crypto.ko] undefined!
>   ERROR: modpost: "aspeed_unregister_hace_hash_algs"
>   [drivers/crypto/aspeed/aspeed_crypto.ko] undefined!
>
> Change build sequence to fix this.
>
> Reported-by: kernel test robot <lkp@intel.com>
> Signed-off-by: Neal Liu <neal_liu@aspeedtech.com>

Tested-by: Sudip Mukherjee <sudipm.mukherjee@gmail.com>

-- 
Regards
Sudip

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* Re: [PATCH] crypto: aspeed: fix build module error
  2022-08-29  7:20 [PATCH] crypto: aspeed: fix build module error Neal Liu
  2022-08-29 10:49 ` Sudip Mukherjee
@ 2022-09-02 10:29 ` Herbert Xu
  2022-09-05  2:39   ` Neal Liu
  1 sibling, 1 reply; 4+ messages in thread
From: Herbert Xu @ 2022-09-02 10:29 UTC (permalink / raw)
  To: Neal Liu
  Cc: David S . Miller, Joel Stanley, Andrew Jeffery, linux-aspeed,
	linux-crypto, linux-arm-kernel, linux-kernel, BMC-SW,
	kernel test robot

On Mon, Aug 29, 2022 at 03:20:35PM +0800, Neal Liu wrote:
>
>  obj-$(CONFIG_CRYPTO_DEV_ASPEED_HACE_HASH) += aspeed-hace-hash.o
>  hace-hash-$(CONFIG_CRYPTO_DEV_ASPEED_HACE_HASH) := aspeed-hace-hash.o
>  obj-$(CONFIG_CRYPTO_DEV_ASPEED_HACE_CRYPTO) += aspeed-hace-crypto.o
>  hace-crypto-$(CONFIG_CRYPTO_DEV_ASPEED_HACE_CRYPTO) := aspeed-hace-crypto.o

Why are these two files being included twice? I think the obj-
lines should be deleted.

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

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* RE: [PATCH] crypto: aspeed: fix build module error
  2022-09-02 10:29 ` Herbert Xu
@ 2022-09-05  2:39   ` Neal Liu
  0 siblings, 0 replies; 4+ messages in thread
From: Neal Liu @ 2022-09-05  2:39 UTC (permalink / raw)
  To: Herbert Xu
  Cc: David S . Miller, Joel Stanley, Andrew Jeffery, linux-aspeed,
	linux-crypto, linux-arm-kernel, linux-kernel, BMC-SW,
	kernel test robot

> -----Original Message-----
> From: Herbert Xu <herbert@gondor.apana.org.au>
> Sent: Friday, September 2, 2022 6:29 PM
> To: Neal Liu <neal_liu@aspeedtech.com>
> Cc: David S . Miller <davem@davemloft.net>; Joel Stanley <joel@jms.id.au>;
> Andrew Jeffery <andrew@aj.id.au>; linux-aspeed@lists.ozlabs.org;
> linux-crypto@vger.kernel.org; linux-arm-kernel@lists.infradead.org;
> linux-kernel@vger.kernel.org; BMC-SW <BMC-SW@aspeedtech.com>; kernel
> test robot <lkp@intel.com>
> Subject: Re: [PATCH] crypto: aspeed: fix build module error
> 
> On Mon, Aug 29, 2022 at 03:20:35PM +0800, Neal Liu wrote:
> >
> >  obj-$(CONFIG_CRYPTO_DEV_ASPEED_HACE_HASH) += aspeed-hace-hash.o
> >  hace-hash-$(CONFIG_CRYPTO_DEV_ASPEED_HACE_HASH) :=
> aspeed-hace-hash.o
> >  obj-$(CONFIG_CRYPTO_DEV_ASPEED_HACE_CRYPTO) +=
> aspeed-hace-crypto.o
> >  hace-crypto-$(CONFIG_CRYPTO_DEV_ASPEED_HACE_CRYPTO) :=
> > aspeed-hace-crypto.o
> 
> Why are these two files being included twice? I think the obj- lines should be
> deleted.
> 
> Thanks,

I'll send new patch within removing the redundant obj- lines.
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

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

end of thread, other threads:[~2022-09-05 19:22 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-08-29  7:20 [PATCH] crypto: aspeed: fix build module error Neal Liu
2022-08-29 10:49 ` Sudip Mukherjee
2022-09-02 10:29 ` Herbert Xu
2022-09-05  2:39   ` Neal Liu

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).