[PATCH 0/2] Fix Qualcomm Crypto engine self tests failures
From: Kuldeep Singh
Date: Wed Jun 10 2026 - 01:55:16 EST
QCE currents fails with crypto_sefltests for below 2 ciphers.
xts-aes qce and ctr-aes-qce.
Failure log snippet:
[ 5.599170] alg: skcipher: xts-aes-qce setkey failed on test vector 0; expected_error=0, actual_error=-126, flags=0x1
[ 5.599184] alg: self-tests for xts(aes) using xts-aes-qce failed (rc=-126)
[ 5.599187] ------------[ cut here ]------------
[ 5.599189] alg: self-tests for xts(aes) using xts-aes-qce failed (rc=-126)
[ 5.599222] WARNING: crypto/testmgr.c:5804 at alg_test+0x2a0/0x3bc, CPU#3: cryptomgr_test/150
[ 5.606169] alg: skcipher: ctr-aes-qce encryption test failed (wrong output IV) on test vector 4, cfg="in-place (one sglist)"
[ 5.606176] 00000000: e7 82 1d b8 53 11 ac 47 e2 7d 18 d6 71 0c a7 61
[ 5.606192] alg: self-tests for ctr(aes) using ctr-aes-qce failed (rc=-22)
[ 5.606196] ------------[ cut here ]------------
[ 5.606198] alg: self-tests for ctr(aes) using ctr-aes-qce failed (rc=-22)
[ 5.606231] WARNING: crypto/testmgr.c:5804 at alg_test+0x2a0/0x3bc, CPU#3: cryptomgr_test/149
This patch series attempt to stabilize QCE and stabilize selftest
framework. The failures are common for all targets and is currently
validated on sm8750-mtp and qcs6490-rb3gen2 device.
Steps followed:
- Enable EXPERT and CRYPTO_SEFLTESTS config.
- Bootup validation and confirm selftests is triggered.
Signed-off-by: Kuldeep Singh <kuldeep.singh@xxxxxxxxxxxxxxxx>
---
Kuldeep Singh (2):
crypto: qce: Fix xts-aes-qce for weak keys
crypto: qce: Fix CTR-AES for partial block requests
drivers/crypto/qce/cipher.h | 1 +
drivers/crypto/qce/skcipher.c | 29 ++++++++++++++++++++++-------
2 files changed, 23 insertions(+), 7 deletions(-)
---
base-commit: 49e02880ec0a8c378e811bc9d85da188d7c6204c
change-id: 20260610-qce_selftest_fix-2e0b66148651
Best regards,
--
Kuldeep Singh <kuldeep.singh@xxxxxxxxxxxxxxxx>