linux-crypto.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 5.10 0/4] Fix built-in testing dependency failures
@ 2023-04-15 10:11 Gaosheng Cui
  2023-04-15 10:11 ` [PATCH 5.10 1/4] crypto: api - " Gaosheng Cui
                   ` (3 more replies)
  0 siblings, 4 replies; 8+ messages in thread
From: Gaosheng Cui @ 2023-04-15 10:11 UTC (permalink / raw)
  To: stable, cuigaosheng1; +Cc: herbert, davem, gregkh, linux-crypto

When complex algorithms that depend on other algorithms are built
into the kernel, the order of registration must be done such that
the underlying algorithms are ready before the ones on top are
registered. As otherwise they would fail during the self-test
which is required during registration.

We can enable fips=1 and ecdh, the calltrace like below:

alg: ecdh: test failed on vector 2, err=-14
Kernel panic - not syncing: alg: self-tests for ecdh-generic (ecdh)
failed in fips mode!
Call Trace:
 dump_stack+0x57/0x6e
 panic+0x109/0x2ca
 alg_test+0x414/0x420
 ? __switch_to_asm+0x3a/0x60
 ? __switch_to_asm+0x34/0x60
 ? __schedule+0x263/0x640
 ? crypto_acomp_scomp_free_ctx+0x30/0x30
 cryptomgr_test+0x22/0x40
 kthread+0xf9/0x130
 ? kthread_park+0x90/0x90
 ret_from_fork+0x22/0x30

adad556efcd ("crypto: api - Fix built-in testing dependency failures") will
fix the issue, and others fix its bugs.

So we can merge them into linux-5.10-y to fix it, thanks!

Herbert Xu (4):
  crypto: api - Fix built-in testing dependency failures
  crypto: api - Do not create test larvals if manager is disabled
  crypto: api - Export crypto_boot_test_finished
  crypto: api - Fix boot-up crash when crypto manager is disabled

 crypto/algapi.c   | 125 +++++++++++++++++++++++++++++++---------------
 crypto/api.c      |  50 +++++++++++++++++--
 crypto/internal.h |  10 ++++
 3 files changed, 141 insertions(+), 44 deletions(-)

-- 
2.25.1


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

end of thread, other threads:[~2023-04-18 13:51 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-04-15 10:11 [PATCH 5.10 0/4] Fix built-in testing dependency failures Gaosheng Cui
2023-04-15 10:11 ` [PATCH 5.10 1/4] crypto: api - " Gaosheng Cui
2023-04-15 15:07   ` Greg KH
     [not found]     ` <3f6315cc-4684-2121-3556-0ace47c29b35@huawei.com>
2023-04-18  9:28       ` Greg KH
2023-04-18 13:51         ` cuigaosheng
2023-04-15 10:11 ` [PATCH 5.10 2/4] crypto: api - Do not create test larvals if manager is disabled Gaosheng Cui
2023-04-15 10:11 ` [PATCH 5.10 3/4] crypto: api - Export crypto_boot_test_finished Gaosheng Cui
2023-04-15 10:11 ` [PATCH 5.10 4/4] crypto: api - Fix boot-up crash when crypto manager is disabled Gaosheng Cui

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