intel / intel/QAT_Engine

Can't build anymore after upgrade due to missing sm4_ccm.h

Open
#234 4 comments 0 reactions 0 assignees View on GitHub
Dominant language
C
Stars
443
Forks
137
PR merge metrics
No merged PRs in 30d

Description

Hello,

I'm currently reinstalling all the QAT setup from scratch. I've installed all the usual stuff (ipsec-mb, ipp-crypto etc) from github directly, but I'm stuck with an error indicating that crypto_mb/sm4_ccm.h is not found. And indeed, I don't have it in the ipp-crypto package:

```
willy@sdp:~/src/QAT_Engine$ ll ../ipp-crypto/sources/ippcp/crypto_mb/include/crypto_mb/
total 112
drwxrwxr-x 2 willy willy 4096 Mar 13 07:24 ./
drwxrwxr-x 4 willy willy 4096 Mar 13 07:24 ../
-rw-rw-r-- 1 willy willy 8222 Mar 13 07:24 cpu_features.h
-rw-rw-r-- 1 willy willy 1673 Mar 13 07:24 defs.h
-rw-rw-r-- 1 willy willy 9546 Mar 13 07:24 ec_nistp256.h
-rw-rw-r-- 1 willy willy 9570 Mar 13 07:24 ec_nistp384.h
-rw-rw-r-- 1 willy willy 9573 Mar 13 07:24 ec_nistp521.h
-rw-rw-r-- 1 willy willy 8189 Mar 13 07:24 ec_sm2.h
-rw-rw-r-- 1 willy willy 3064 Mar 13 07:24 ed25519.h
-rw-rw-r-- 1 willy willy 2622 Mar 13 07:24 exp.h
-rw-rw-r-- 1 willy willy 5069 Mar 13 07:24 rsa.h
-rw-rw-r-- 1 willy willy 2736 Mar 13 07:24 sm3.h
-rw-rw-r-- 1 willy willy 3297 Mar 13 07:24 sm4.h
-rw-rw-r-- 1 willy willy 5544 Mar 13 07:24 sm4_gcm.h
-rw-rw-r-- 1 willy willy 3835 Mar 13 07:24 status.h
-rw-rw-r-- 1 willy willy 1536 Mar 13 07:24 version.h
-rw-rw-r-- 1 willy willy 1221 Mar 13 07:24 x25519.h
```

I remember that it used to build around 0.6.16 or 0.6.17. I noticed that this new dependency was added by this recent commit:
```
commit d8c5c8dd4117b4a59805a46f123f4d8b249ddb1b
Author: Amit Kumar
Date: Fri Feb 3 22:55:20 2023 +0530

Add QAT_SW SM4-CCM support.

Signed-off-by: Yogaraj Alamenda
```

It introduced a new config option ENABLE_QAT_SW_SM4_CCM, but seems to be missing it at various places, for example:
```
+++ b/e_qat.c
@@ -112,6 +112,7 @@
# include "crypto_mb/cpu_features.h"
# include "crypto_mb/sm4.h"
# include "crypto_mb/sm4_gcm.h"
+# include "crypto_mb/sm4_ccm.h"
#endif
```

I tried to fix 3 of them and ran into further issues with types being declared in function prototypes etc. I could revert the commit and then it goes further. I think someone should have a look, and try to build it against publicly available crypto_mb.

Thanks!
Willy

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.