All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ren Zhijie <renzhijie2@huawei.com>
To: <dhowells@redhat.com>, <herbert@gondor.apana.org.au>,
	<davem@davemloft.net>, <simo@redhat.com>
Cc: <keyrings@vger.kernel.org>, <linux-crypto@vger.kernel.org>,
	<linux-kernel@vger.kernel.org>,
	Ren Zhijie <renzhijie2@huawei.com>
Subject: [PATCH -next] certs: Fix Kconfig dependency
Date: Mon, 4 Jul 2022 19:20:28 +0800	[thread overview]
Message-ID: <20220704112028.183193-1-renzhijie2@huawei.com> (raw)

If CONFIG_PKCS7_MESSAGE_PARSER=m and CONFIG_FIPS_SIGNATURE_SELFTEST=y,
make ARCH=x86_64 CROSS_COMPILE=x86_64-linux-gnu-, will be failed, like this:

crypto/asymmetric_keys/selftest.o: In function `fips_signature_selftest':
selftest.c:(.init.text+0xc3): undefined reference to `pkcs7_parse_message'
selftest.c:(.init.text+0x101): undefined reference to `pkcs7_supply_detached_data'
selftest.c:(.init.text+0x112): undefined reference to `pkcs7_verify'
selftest.c:(.init.text+0x13f): undefined reference to `pkcs7_validate_trust'
selftest.c:(.init.text+0x169): undefined reference to `pkcs7_free_message'
make: *** [vmlinux] Error 1

To fix this error, add depends on PKCS7_MESSAGE_PARSER=y to FIPS_SIGNATURE_SELFTEST

Reported-by: Hulk Robot <hulkci@huawei.com>
Fixes: 3cde3174eb91 ("certs: Add FIPS selftests")
Signed-off-by: Ren Zhijie <renzhijie2@huawei.com>
---
 crypto/asymmetric_keys/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/crypto/asymmetric_keys/Kconfig b/crypto/asymmetric_keys/Kconfig
index 3df3fe4ed95f..fe007db96c69 100644
--- a/crypto/asymmetric_keys/Kconfig
+++ b/crypto/asymmetric_keys/Kconfig
@@ -83,6 +83,6 @@ config FIPS_SIGNATURE_SELFTEST
 	  for FIPS.
 	depends on KEYS
 	depends on ASYMMETRIC_KEY_TYPE
-	depends on PKCS7_MESSAGE_PARSER
+	depends on PKCS7_MESSAGE_PARSER=y
 
 endif # ASYMMETRIC_KEY_TYPE
-- 
2.17.1


             reply	other threads:[~2022-07-04 11:22 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-04 11:20 Ren Zhijie [this message]
2022-07-11  0:36 ` [PATCH -next] certs: Fix Kconfig dependency Randy Dunlap
2022-07-25  6:19 ` Ren Zhijie

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=20220704112028.183193-1-renzhijie2@huawei.com \
    --to=renzhijie2@huawei.com \
    --cc=davem@davemloft.net \
    --cc=dhowells@redhat.com \
    --cc=herbert@gondor.apana.org.au \
    --cc=keyrings@vger.kernel.org \
    --cc=linux-crypto@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=simo@redhat.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.