[PATCH 14/18] Make ASYMMETRIC_KEY_TYPE depend on FIT_SIGNATURE

AKASHI Takahiro takahiro.akashi at linaro.org
Mon Mar 14 02:59:23 CET 2022


Hi Simon,

On Fri, Mar 11, 2022 at 07:25:16PM -0700, Simon Glass wrote:
> Hi Takahiro,
> 
> On Mon, 28 Feb 2022 at 21:22, AKASHI Takahiro
> <takahiro.akashi at linaro.org> wrote:
> >
> > Simon,
> >
> > On Mon, Feb 28, 2022 at 12:08:31PM -0700, Simon Glass wrote:
> > > Add this dependency to avoid a build error if FIT_SIGNATURE is not
> > > enabled.
> >
> > I doubt it.
> > With qemu_arm64_defconfig & ASYMMETRIC_KEY_TYPE & !FIT_SIGNATURE,
> > I don't see any build error on 2022.04-rc2.
> 
> This is what I see when building sandbox with Chromium OS verified
> boot (where FIT_SIGNATURE is not enabled).
> 
> /usr/bin/ld: lib/crypto/public_key.o: in function `public_key_verify_signature':
> lib/crypto/public_key.c:113: undefined reference to `image_get_padding_algo'
> /usr/bin/ld: lib/crypto/public_key.c:124: undefined reference to
> `image_get_checksum_algo'
> /usr/bin/ld: lib/crypto/public_key.c:126: undefined reference to
> `image_get_crypto_algo'

After my commit b983cc2da0ba ("lib: rsa: decouple rsa from FIT image
verification"), those symbols are independently compiled in
with CONFIG_IMAGE_SIGN_INFO.

> /usr/bin/ld: lib/crypto/public_key.c:136: undefined reference to
> `rsa_verify_with_pkey'

Likewise, please select CONFIG_RSA_VERIFY_WITH_PKEY specifically
instead of CONFIG_FIT_SIGNATURE.

-Takahiro Akashi

> collect2: error: ld returned 1 exit status
> make[1]: *** [Makefile:1901: u-boot] Error 1
> 
> 
> Regards,
> Simon
> [..]


More information about the U-Boot mailing list