intel / QAT_Engine

Intel QuickAssist Technology( QAT) OpenSSL Engine (an OpenSSL Plug-In Engine) which provides cryptographic acceleration for both hardware and optimized software using Intel QuickAssist Technology enabled Intel platforms. https://developer.intel.com/quickassist
BSD 3-Clause "New" or "Revised" License
406 stars 129 forks source link

Atom C3958 Hardware Engine Install #246

Closed jimthedj65 closed 1 year ago

jimthedj65 commented 1 year ago

Hi All, Our thinking is to roll back version? Any thoughts or direction welcomed.

Were running Ubuntu server 22.04 which has some changes from 20.04

We installed the correct libraries and we get a good result with ./autogen.sh and below this running all the latest repos intel-ipsec-mb v1.3 ipp-crypto 2021.7 QAT_Engine 1.1.0 QAT Drivers, which loads Intel_QAT_Linux_v1.7.L.4.16.0-00017.tar.gz

qat_service.service - LSB: modprobe the QAT modules, which loads dependant modules, before calling the user space utility to pass configuration parameters
     Loaded: loaded (/etc/init.d/qat_service; generated)
     Active: active (exited) since Thu 2023-05-25 07:49:43 UTC; 1s ago
       Docs: man:systemd-sysv-generator(8)
    Process: 5509 ExecStart=/etc/init.d/qat_service start (code=exited, status=0/SUCCESS)
        CPU: 259ms

May 25 07:49:42 XXXXXXXX systemd[1]: Starting LSB: modprobe the QAT modules, which loads dependant modules, before calling the user space utility to pass c>
May 25 07:49:42 XXXXXXXX  qat_service[5556]: Restarting all devices.
May 25 07:49:42 XXXXXXXX  qat_service[5556]: Processing /etc/c3xxx_dev0.conf
May 25 07:49:43 XXXXXXXX  qat_service[5568]: Checking status of all devices.
May 25 07:49:43 XXXXXXXX  qat_service[5568]: There is 1 QAT acceleration device(s) in the system:
May 25 07:49:43 XXXXXXXX  qat_service[5568]:  qat_dev0 - type: c3xxx,  inst_id: 0,  node_id: 0,  bsf: 0000:01:00.0,  #accel: 3 #engines: 6 state: up
May 25 07:49:43 XXXXXXXX  systemd[1]: Started LSB: modprobe the QAT modules, which loads dependant modules, before calling the user space utility to pass co>
openssl speed -engine qatengine -elapsed -evp aes-128-gcm
QAT_HW device not available & QAT_SW not enabled. Using OpenSSL_SW!
engine "qatengine" set.
You have chosen to measure elapsed time instead of user CPU time.
Doing aes-128-gcm for 3s on 16 size blocks: 31113188 aes-128-gcm's in 3.00s
Doing aes-128-gcm for 3s on 64 size blocks: 20543514 aes-128-gcm's in 3.00s

openssl version -a

built on: Tue May 23 22:23:33 2023 UTC
platform: linux-x86_64
options:  bn(64,64) rc4(16x,int) des(int) idea(int) blowfish(ptr)
compiler: gcc -fPIC -pthread -m64 -Wa,--noexecstack -Wall -O3 -DOPENSSL_USE_NODELETE -DL_ENDIAN -DOPENSSL_PIC -DOPENSSL_CPUID_OBJ -DOPENSSL_IA32_SSE2 -DOPENSSL_BN_ASM_MONT -DOPENSSL_BN_ASM_MONT5 -DOPENSSL_BN_ASM_GF2m -DSHA1_ASM -DSHA256_ASM -DSHA512_ASM -DKECCAK1600_ASM -DRC4_ASM -DMD5_ASM -DAESNI_ASM -DVPAES_ASM -DGHASH_ASM -DECP_NISTZ256_ASM -DX25519_ASM -DPOLY1305_ASM -DNDEBUG
OPENSSLDIR: "/usr/local/ssl"
ENGINESDIR: "/usr/local/lib64/engines-1.1"
Seeding source: os-specific 
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a race-free mkdir -p... /usr/bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking whether make supports nested variables... (cached) yes
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking how to print strings... printf
checking whether make supports the include directive... yes (GNU style)
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether the compiler supports GNU C... yes
checking whether gcc accepts -g... yes
checking for gcc option to enable C11 features... none needed
checking whether gcc understands -c and -o together... yes
checking dependency style of gcc... gcc3
checking for a sed that does not truncate output... /usr/bin/sed
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for fgrep... /usr/bin/grep -F
checking for ld used by gcc... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B
checking the name lister (/usr/bin/nm -B) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 1572864
checking how to convert x86_64-pc-linux-gnu file names to x86_64-pc-linux-gnu format... func_convert_file_noop
checking how to convert x86_64-pc-linux-gnu file names to toolchain format... func_convert_file_noop
checking for /usr/bin/ld option to reload object files... -r
checking for objdump... objdump
checking how to recognize dependent libraries... pass_all
checking for dlltool... no
checking how to associate runtime and link libraries... printf %s\n
checking for ar... ar
checking for archiver @FILE support... @
checking for strip... strip
checking for ranlib... ranlib
checking command to parse /usr/bin/nm -B output from gcc object... ok
checking for sysroot... no
checking for a working dd... /usr/bin/dd
checking how to truncate binary pipes... /usr/bin/dd bs=4096 count=1
checking for mt... mt
checking if mt is a manifest tool... no
checking for stdio.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for strings.h... yes
checking for sys/stat.h... yes
checking for sys/types.h... yes
checking for unistd.h... yes
checking for dlfcn.h... yes
checking for objdir... .libs
checking if gcc supports -fno-rtti -fno-exceptions... no
checking for gcc option to produce PIC... -fPIC -DPIC
checking if gcc PIC flag -fPIC -DPIC works... yes
checking if gcc static flag -static works... yes
checking if gcc supports -c -o file.o... yes
checking if gcc supports -c -o file.o... (cached) yes
checking whether the gcc linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes
checking whether -lc should be explicitly linked in... no
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
checking whether ln -s works... yes
checking for g++... g++
checking whether the compiler supports GNU C++... yes
checking whether g++ accepts -g... yes
checking for g++ option to enable C++11 features... none needed
checking dependency style of g++... gcc3
checking how to run the C++ preprocessor... g++ -E
checking for ld used by g++... /usr/bin/ld -m elf_x86_64
checking if the linker (/usr/bin/ld -m elf_x86_64) is GNU ld... yes
checking whether the g++ linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes
checking for g++ option to produce PIC... -fPIC -DPIC
checking if g++ PIC flag -fPIC -DPIC works... yes
checking if g++ static flag -static works... yes
checking if g++ supports -c -o file.o... yes
checking if g++ supports -c -o file.o... (cached) yes
checking whether the g++ linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes
checking dynamic linker characteristics... (cached) GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking for gcc... (cached) gcc
checking whether the compiler supports GNU C... (cached) yes
checking whether gcc accepts -g... (cached) yes
checking for gcc option to enable C11 features... (cached) none needed
checking whether gcc understands -c and -o together... (cached) yes
checking dependency style of gcc... (cached) gcc3
checking for /home/pxcghost/QAT/qat1.7/include/qat/icp_sal_versions.h... no
checking for pkg-config... /usr/bin/pkg-config
grep: /usr/include/openssl/opensslv.h: No such file or directory
configure: Install engine/provider in the system OpenSSL Path
checking for /home/pxcghost/QAT/qat1.7/quickassist/lookaside/access_layer/src/common/crypto/kpt/crypto/lac_kpt_crypto_qat_comms.c... yes
configure: QAT_HW acceleration enabled
configure: Build with existing error files without regenerating from OpenSSL source
configure: Insecure Algorithms disabled
configure: Accelerating RSA to Hardware
configure: Accelerating ECDSA to Hardware
configure: Accelerating ECDH to Hardware
configure: Accelerating X25519/X448 to Hardware
configure: Accelerating PRF to Hardware
configure: Accelerating CIPHERS to Hardware
configure: USDM enabled
checking for ldd... yes
checking for head... yes
configure: glibc version >= 2.23. glibc AVX-512 memcpy optimisation supported.
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
config.status: creating config.h
config.status: config.h is unchanged
config.status: executing depfiles commands
config.status: executing libtool commands
===========================================
Enabled Algorithms and Additional Flags
===========================================
QAT_HW ALGORITHMS : -DQAT_HW -DQAT20_OOT -DENABLE_QAT_HW_RSA -DENABLE_QAT_HW_ECDSA -DENABLE_QAT_HW_ECDH -DENABLE_QAT_HW_ECX -DENABLE_QAT_HW_PRF -DENABLE_QAT_HW_CIPHERS
QAT_SW ALGORITHMS :
ADDITIONAL FLAGS  : -Wall -Wformat -Wformat-security -D_FORTIFY_SOURCE=2 -fno-delete-null-pointer-checks -fwrapv -fstack-protector-strong
===========================================

When we move to make, we get errors on below

sudo make -j
make  all-am
make[1]: Entering directory '/home/pxcghost/QAT/QAT_Engine'
  CC       e_qat.lo
  CC       qat_fork.lo
  CC       qat_events.lo
  CC       qat_utils.lo
  CC       qat_evp.lo
  CC       e_qat_err.lo
  CC       qat_hw_init.lo
  CC       qat_hw_asym_common.lo
  CC       qat_hw_polling.lo
  CC       qat_hw_callback.lo
  CC       qat_hw_rsa.lo
  CC       qat_hw_rsa_crt.lo
  CC       qat_hw_ciphers.lo
  CC       qat_hw_dh.lo
  CC       qat_hw_dsa.lo
  CC       qat_hw_ec.lo
  CC       qat_hw_prf.lo
  CC       qat_hw_gcm.lo
  CC       qat_hw_hkdf.lo
  CC       qat_hw_ecx.lo
  CC       qat_hw_sha3.lo
  CC       qat_hw_chachapoly.lo
qat_hw_ec.c: In function ‘qat_get_curve’:
qat_hw_ec.c:111:16: error: ‘CPA_CY_EC_CURVE_TYPE_WEIERSTRASS_PRIME’ undeclared (first use in this function)
  111 |         return CPA_CY_EC_CURVE_TYPE_WEIERSTRASS_PRIME;
      |                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
qat_hw_ec.c:111:16: note: each undeclared identifier is reported only once for each function it appears in
qat_hw_ec.c:113:16: error: ‘CPA_CY_EC_CURVE_TYPE_WEIERSTRASS_BINARY’ undeclared (first use in this function)
  113 |         return CPA_CY_EC_CURVE_TYPE_WEIERSTRASS_BINARY;
      |                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
qat_hw_ec.c:115:16: error: ‘CPA_CY_EC_CURVE_TYPE_WEIERSTRASS_KOBLITZ_BINARY’ undeclared (first use in this function)
  115 |         return CPA_CY_EC_CURVE_TYPE_WEIERSTRASS_KOBLITZ_BINARY;
      |                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
qat_hw_ec.c: In function ‘qat_ecdh_compute_key’:
qat_hw_ec.c:147:5: error: unknown type name ‘CpaCyEcGenericPointMultiplyOpData’; did you mean ‘CpaCyEcPointMultiplyOpData’?
  147 |     CpaCyEcGenericPointMultiplyOpData *pOpData = NULL;
      |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |     CpaCyEcPointMultiplyOpData
qat_hw_ec.c:194:16: error: ‘CpaCyEcGenericPointMultiplyOpData’ undeclared (first use in this function); did you mean ‘CpaCyEcPointMultiplyOpData’?
  194 |     pOpData = (CpaCyEcGenericPointMultiplyOpData *)
      |                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |                CpaCyEcPointMultiplyOpData
qat_hw_ec.c:194:51: error: expected expression before ‘)’ token
  194 |     pOpData = (CpaCyEcGenericPointMultiplyOpData *)
      |                                                   ^
qat_hw_ec.c:201:12: error: request for member ‘pCurve’ in something not a structure or union
  201 |     pOpData->pCurve = (CpaCyEcCurve *) qaeCryptoMemAlloc(sizeof(CpaCyEcCurve),
      |            ^~
qat_hw_ec.c:201:24: error: ‘CpaCyEcCurve’ undeclared (first use in this function)
  201 |     pOpData->pCurve = (CpaCyEcCurve *) qaeCryptoMemAlloc(sizeof(CpaCyEcCurve),
      |                        ^~~~~~~~~~~~
qat_hw_ec.c:201:38: error: expected expression before ‘)’ token
  201 |     pOpData->pCurve = (CpaCyEcCurve *) qaeCryptoMemAlloc(sizeof(CpaCyEcCurve),
      |                                      ^
qat_hw_ec.c:203:16: error: request for member ‘pCurve’ in something not a structure or union
  203 |     if (pOpData->pCurve == NULL) {
      |                ^~
qat_hw_ec.c:211:16: error: request for member ‘generator’ in something not a structure or union
  211 |         pOpData->generator = CPA_TRUE;
      |                ^~
qat_hw_ec.c:213:16: error: request for member ‘generator’ in something not a structure or union
  213 |         pOpData->generator = CPA_FALSE;
      |                ^~
qat_hw_ec.c:215:12: error: request for member ‘k’ in something not a structure or union
  215 |     pOpData->k.pData = NULL;
      |            ^~
qat_hw_ec.c:216:12: error: request for member ‘xP’ in something not a structure or union
  216 |     pOpData->xP.pData = NULL;
      |            ^~
qat_hw_ec.c:217:12: error: request for member ‘yP’ in something not a structure or union
  217 |     pOpData->yP.pData = NULL;
      |            ^~
qat_hw_ec.c:218:12: error: request for member ‘pCurve’ in something not a structure or union
  218 |     pOpData->pCurve->parameters.weierstrassParameters.a.pData = NULL;
      |            ^~
qat_hw_ec.c:219:12: error: request for member ‘pCurve’ in something not a structure or union
  219 |     pOpData->pCurve->parameters.weierstrassParameters.b.pData = NULL;
      |            ^~
qat_hw_ec.c:220:12: error: request for member ‘pCurve’ in something not a structure or union
  220 |     pOpData->pCurve->parameters.weierstrassParameters.p.pData = NULL;
      |            ^~
qat_hw_ec.c:221:12: error: request for member ‘pCurve’ in something not a structure or union
  221 |     pOpData->pCurve->parameters.weierstrassParameters.h.pData = NULL;
      |            ^~
qat_hw_ec.c:222:12: error: request for member ‘pCurve’ in something not a structure or union
  222 |     pOpData->pCurve->parameters.weierstrassParameters.h.dataLenInBytes = 0;
      |            ^~
qat_hw_ec.c:310:12: error: request for member ‘pCurve’ in something not a structure or union
  310 |     pOpData->pCurve->parameters.weierstrassParameters.fieldType = qat_get_field_type(group);
      |            ^~
qat_hw_ec.c:311:12: error: request for member ‘pCurve’ in something not a structure or union
  311 |     pOpData->pCurve->curveType = qat_get_curve(pOpData->pCurve->parameters.weierstrassParameters.fieldType);
      |            ^~
qat_hw_ec.c:311:55: error: request for member ‘pCurve’ in something not a structure or union
  311 |     pOpData->pCurve->curveType = qat_get_curve(pOpData->pCurve->parameters.weierstrassParameters.fieldType);
      |                                                       ^~
qat_hw_ec.c:313:32: error: request for member ‘k’ in something not a structure or union
  313 |     if ((qat_BN_to_FB(&(pOpData->k), (BIGNUM *)priv_key) != 1) ||
      |                                ^~
qat_hw_ec.c:314:32: error: request for member ‘xP’ in something not a structure or union
  314 |         (qat_BN_to_FB(&(pOpData->xP), xP) != 1) ||
      |                                ^~
qat_hw_ec.c:315:32: error: request for member ‘yP’ in something not a structure or union
  315 |         (qat_BN_to_FB(&(pOpData->yP), yP) != 1) ||
      |                                ^~
qat_hw_ec.c:316:32: error: request for member ‘pCurve’ in something not a structure or union
  316 |         (qat_BN_to_FB(&(pOpData->pCurve->parameters.weierstrassParameters.a), a) != 1) ||
      |                                ^~
qat_hw_ec.c:317:32: error: request for member ‘pCurve’ in something not a structure or union
  317 |         (qat_BN_to_FB(&(pOpData->pCurve->parameters.weierstrassParameters.b), b) != 1) ||
      |                                ^~
qat_hw_ec.c:318:32: error: request for member ‘pCurve’ in something not a structure or union
  318 |         (qat_BN_to_FB(&(pOpData->pCurve->parameters.weierstrassParameters.p), p) != 1)) {
      |                                ^~
qat_hw_ec.c:325:17: error: request for member ‘pCurve’ in something not a structure or union
  325 |      if (pOpData->pCurve->parameters.weierstrassParameters.fieldType
      |                 ^~
qat_hw_ec.c:327:36: error: request for member ‘pCurve’ in something not a structure or union
  327 |          if (qat_BN_to_FB(&(pOpData->pCurve->parameters.weierstrassParameters.h), h) != 1) {
      |                                    ^~
qat_hw_ec.c:341:16: error: request for member ‘pCurve’ in something not a structure or union
  341 |     if (pOpData->pCurve->parameters.weierstrassParameters.a.pData == NULL &&
      |                ^~
qat_hw_ec.c:342:16: error: request for member ‘pCurve’ in something not a structure or union
  342 |         pOpData->pCurve->parameters.weierstrassParameters.a.dataLenInBytes == 0) {
      |                ^~
qat_hw_ec.c:343:16: error: request for member ‘pCurve’ in something not a structure or union
  343 |         pOpData->pCurve->parameters.weierstrassParameters.a.pData =
      |                ^~
qat_hw_ec.c:345:20: error: request for member ‘pCurve’ in something not a structure or union
  345 |         if (pOpData->pCurve->parameters.weierstrassParameters.a.pData == NULL) {
      |                    ^~
qat_hw_ec.c:350:16: error: request for member ‘pCurve’ in something not a structure or union
  350 |         pOpData->pCurve->parameters.weierstrassParameters.a.dataLenInBytes = 1;
      |                ^~
qat_hw_ec.c:351:16: error: request for member ‘pCurve’ in something not a structure or union
  351 |         pOpData->pCurve->parameters.weierstrassParameters.a.pData[0] = 0;
      |                ^~
qat_hw_ec.c:436:18: warning: implicit declaration of function ‘cpaCyEcGenericPointMultiply’; did you mean ‘cpaCyEcPointMultiply’? [-Wimplicit-function-declaration]
  436 |         status = cpaCyEcGenericPointMultiply(qat_instance_handles[inst_num],
      |                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~
      |                  cpaCyEcPointMultiply
In file included from qat_hw_ec.c:75:
qat_hw_ec.c:638:54: error: request for member ‘k’ in something not a structure or union
  638 |         QAT_CHK_CLNSE_QMFREE_NONZERO_FLATBUFF(pOpData->k);
      |                                                      ^~
e_qat.h:213:22: note: in definition of macro ‘QAT_CHK_CLNSE_QMFREE_NONZERO_FLATBUFF’
  213 |                 if ((b).pData != NULL)                        \
      |                      ^
qat_hw_ec.c:638:54: error: request for member ‘k’ in something not a structure or union
  638 |         QAT_CHK_CLNSE_QMFREE_NONZERO_FLATBUFF(pOpData->k);
      |                                                      ^~
e_qat.h:191:30: note: in definition of macro ‘QAT_CLEANSE_FLATBUFF’
  191 |             OPENSSL_cleanse((b).pData, (b).dataLenInBytes)
      |                              ^
e_qat.h:214:21: note: in expansion of macro ‘QAT_CLEANSE_QMEMFREE_NONZERO_FLATBUFF’
  214 |                     QAT_CLEANSE_QMEMFREE_NONZERO_FLATBUFF(b); \
      |                     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
qat_hw_ec.c:638:9: note: in expansion of macro ‘QAT_CHK_CLNSE_QMFREE_NONZERO_FLATBUFF’
  638 |         QAT_CHK_CLNSE_QMFREE_NONZERO_FLATBUFF(pOpData->k);
      |         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
qat_hw_ec.c:638:54: error: request for member ‘k’ in something not a structure or union
  638 |         QAT_CHK_CLNSE_QMFREE_NONZERO_FLATBUFF(pOpData->k);
      |                                                      ^~
e_qat.h:191:41: note: in definition of macro ‘QAT_CLEANSE_FLATBUFF’
  191 |             OPENSSL_cleanse((b).pData, (b).dataLenInBytes)
      |                                         ^
e_qat.h:214:21: note: in expansion of macro ‘QAT_CLEANSE_QMEMFREE_NONZERO_FLATBUFF’
  214 |                     QAT_CLEANSE_QMEMFREE_NONZERO_FLATBUFF(b); \
      |                     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
qat_hw_ec.c:638:9: note: in expansion of macro ‘QAT_CHK_CLNSE_QMFREE_NONZERO_FLATBUFF’
  638 |         QAT_CHK_CLNSE_QMFREE_NONZERO_FLATBUFF(pOpData->k);
      |         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
qat_hw_ec.c:638:54: error: request for member ‘k’ in something not a structure or union
  638 |         QAT_CHK_CLNSE_QMFREE_NONZERO_FLATBUFF(pOpData->k);
      |                                                      ^~
e_qat.h:197:38: note: in definition of macro ‘QAT_QMEM_FREE_NONZERO_FLATBUFF’
  197 |             qaeCryptoMemFreeNonZero((b).pData)
      |                                      ^
e_qat.h:214:21: note: in expansion of macro ‘QAT_CLEANSE_QMEMFREE_NONZERO_FLATBUFF’
  214 |                     QAT_CLEANSE_QMEMFREE_NONZERO_FLATBUFF(b); \
      |                     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
qat_hw_ec.c:638:9: note: in expansion of macro ‘QAT_CHK_CLNSE_QMFREE_NONZERO_FLATBUFF’
  638 |         QAT_CHK_CLNSE_QMFREE_NONZERO_FLATBUFF(pOpData->k);
      |         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
qat_hw_ec.c:639:40: error: request for member ‘xP’ in something not a structure or union
  639 |         QAT_CHK_QMFREE_FLATBUFF(pOpData->xP);
      |                                        ^~
e_qat.h:225:22: note: in definition of macro ‘QAT_CHK_QMFREE_FLATBUFF’
  225 |                 if ((b).pData != NULL)         \
      |                      ^
qat_hw_ec.c:639:40: error: request for member ‘xP’ in something not a structure or union
  639 |         QAT_CHK_QMFREE_FLATBUFF(pOpData->xP);
      |                                        ^~
e_qat.h:194:31: note: in definition of macro ‘QAT_QMEM_FREE_FLATBUFF’
  194 |             qaeCryptoMemFree((b).pData)
      |                               ^
qat_hw_ec.c:639:9: note: in expansion of macro ‘QAT_CHK_QMFREE_FLATBUFF’
  639 |         QAT_CHK_QMFREE_FLATBUFF(pOpData->xP);
      |         ^~~~~~~~~~~~~~~~~~~~~~~
qat_hw_ec.c:640:40: error: request for member ‘yP’ in something not a structure or union
  640 |         QAT_CHK_QMFREE_FLATBUFF(pOpData->yP);
      |                                        ^~
e_qat.h:225:22: note: in definition of macro ‘QAT_CHK_QMFREE_FLATBUFF’
  225 |                 if ((b).pData != NULL)         \
      |                      ^
qat_hw_ec.c:640:40: error: request for member ‘yP’ in something not a structure or union
  640 |         QAT_CHK_QMFREE_FLATBUFF(pOpData->yP);
      |                                        ^~
e_qat.h:194:31: note: in definition of macro ‘QAT_QMEM_FREE_FLATBUFF’
  194 |             qaeCryptoMemFree((b).pData)
      |                               ^
qat_hw_ec.c:640:9: note: in expansion of macro ‘QAT_CHK_QMFREE_FLATBUFF’
  640 |         QAT_CHK_QMFREE_FLATBUFF(pOpData->yP);
      |         ^~~~~~~~~~~~~~~~~~~~~~~
qat_hw_ec.c:641:40: error: request for member ‘pCurve’ in something not a structure or union
  641 |         QAT_CHK_QMFREE_FLATBUFF(pOpData->pCurve->parameters.weierstrassParameters.a);
      |                                        ^~
e_qat.h:225:22: note: in definition of macro ‘QAT_CHK_QMFREE_FLATBUFF’
  225 |                 if ((b).pData != NULL)         \
      |                      ^
qat_hw_ec.c:641:40: error: request for member ‘pCurve’ in something not a structure or union
  641 |         QAT_CHK_QMFREE_FLATBUFF(pOpData->pCurve->parameters.weierstrassParameters.a);
      |                                        ^~
e_qat.h:194:31: note: in definition of macro ‘QAT_QMEM_FREE_FLATBUFF’
  194 |             qaeCryptoMemFree((b).pData)
      |                               ^
qat_hw_ec.c:641:9: note: in expansion of macro ‘QAT_CHK_QMFREE_FLATBUFF’
  641 |         QAT_CHK_QMFREE_FLATBUFF(pOpData->pCurve->parameters.weierstrassParameters.a);
      |         ^~~~~~~~~~~~~~~~~~~~~~~
qat_hw_ec.c:642:40: error: request for member ‘pCurve’ in something not a structure or union
  642 |         QAT_CHK_QMFREE_FLATBUFF(pOpData->pCurve->parameters.weierstrassParameters.b);
      |                                        ^~
e_qat.h:225:22: note: in definition of macro ‘QAT_CHK_QMFREE_FLATBUFF’
  225 |                 if ((b).pData != NULL)         \
      |                      ^
qat_hw_ec.c:642:40: error: request for member ‘pCurve’ in something not a structure or union
  642 |         QAT_CHK_QMFREE_FLATBUFF(pOpData->pCurve->parameters.weierstrassParameters.b);
      |                                        ^~
e_qat.h:194:31: note: in definition of macro ‘QAT_QMEM_FREE_FLATBUFF’
  194 |             qaeCryptoMemFree((b).pData)
      |                               ^
qat_hw_ec.c:642:9: note: in expansion of macro ‘QAT_CHK_QMFREE_FLATBUFF’
  642 |         QAT_CHK_QMFREE_FLATBUFF(pOpData->pCurve->parameters.weierstrassParameters.b);
      |         ^~~~~~~~~~~~~~~~~~~~~~~
qat_hw_ec.c:643:40: error: request for member ‘pCurve’ in something not a structure or union
  643 |         QAT_CHK_QMFREE_FLATBUFF(pOpData->pCurve->parameters.weierstrassParameters.p);
      |                                        ^~
e_qat.h:225:22: note: in definition of macro ‘QAT_CHK_QMFREE_FLATBUFF’
  225 |                 if ((b).pData != NULL)         \
      |                      ^
qat_hw_ec.c:643:40: error: request for member ‘pCurve’ in something not a structure or union
  643 |         QAT_CHK_QMFREE_FLATBUFF(pOpData->pCurve->parameters.weierstrassParameters.p);
      |                                        ^~
e_qat.h:194:31: note: in definition of macro ‘QAT_QMEM_FREE_FLATBUFF’
  194 |             qaeCryptoMemFree((b).pData)
      |                               ^
qat_hw_ec.c:643:9: note: in expansion of macro ‘QAT_CHK_QMFREE_FLATBUFF’
  643 |         QAT_CHK_QMFREE_FLATBUFF(pOpData->pCurve->parameters.weierstrassParameters.p);
      |         ^~~~~~~~~~~~~~~~~~~~~~~
qat_hw_ec.c:644:40: error: request for member ‘pCurve’ in something not a structure or union
  644 |         QAT_CHK_QMFREE_FLATBUFF(pOpData->pCurve->parameters.weierstrassParameters.h);
      |                                        ^~
e_qat.h:225:22: note: in definition of macro ‘QAT_CHK_QMFREE_FLATBUFF’
  225 |                 if ((b).pData != NULL)         \
      |                      ^
qat_hw_ec.c:644:40: error: request for member ‘pCurve’ in something not a structure or union
  644 |         QAT_CHK_QMFREE_FLATBUFF(pOpData->pCurve->parameters.weierstrassParameters.h);
      |                                        ^~
e_qat.h:194:31: note: in definition of macro ‘QAT_QMEM_FREE_FLATBUFF’
  194 |             qaeCryptoMemFree((b).pData)
      |                               ^
qat_hw_ec.c:644:9: note: in expansion of macro ‘QAT_CHK_QMFREE_FLATBUFF’
  644 |         QAT_CHK_QMFREE_FLATBUFF(pOpData->pCurve->parameters.weierstrassParameters.h);
      |         ^~~~~~~~~~~~~~~~~~~~~~~
qat_hw_ec.c:645:34: error: request for member ‘pCurve’ in something not a structure or union
  645 |         QAT_QMEMFREE_BUFF(pOpData->pCurve);
      |                                  ^~
e_qat.h:166:21: note: in definition of macro ‘QAT_QMEMFREE_BUFF’
  166 |                 if (b != NULL) {         \
      |                     ^
qat_hw_ec.c:645:34: error: request for member ‘pCurve’ in something not a structure or union
  645 |         QAT_QMEMFREE_BUFF(pOpData->pCurve);
      |                                  ^~
e_qat.h:167:38: note: in definition of macro ‘QAT_QMEMFREE_BUFF’
  167 |                     qaeCryptoMemFree(b); \
      |                                      ^
qat_hw_ec.c:645:34: error: request for member ‘pCurve’ in something not a structure or union
  645 |         QAT_QMEMFREE_BUFF(pOpData->pCurve);
      |                                  ^~
e_qat.h:168:21: note: in definition of macro ‘QAT_QMEMFREE_BUFF’
  168 |                     b = NULL;            \
      |                     ^
qat_hw_ec.c: In function ‘qat_get_curve’:
qat_hw_ec.c:116:1: warning: control reaches end of non-void function [-Wreturn-type]
  116 | }
      | ^
make[1]: *** [Makefile:1221: qat_hw_ec.lo] Error 1
make[1]: *** Waiting for unfinished jobs....
make[1]: Leaving directory '/home/pxcghost/QAT/QAT_Engine'
make: *** [Makefile:889: all] Error 2
jimthedj65 commented 1 year ago

tried rolling back various versions still no joy. same error on QAT_Engine hardware. Given that vpp supports ipsecmb internally and our drivers are ok, we should be ok for QAT.

jimthedj65 commented 10 months ago

I managed to resolve this by building with the intree driver https://github.com/intel/qatlib