intel / QATzip

Compression Library accelerated by Intel® QuickAssist Technology
https://developer.intel.com/quickassist
Other
140 stars 51 forks source link

If I want to use hardware acceleration, and I don't want to turn off iommu of host, is there any other way #115

Open yangni2017 opened 3 months ago

yangni2017 commented 3 months ago

qzip version: QATzip-QATzip_1.1.2_release card info: Intel Corporation C62x Chipset QuickAssist Technology driver info:QAT.L.4.25.0-00001 cpu:Intel(R) Xeon(R) CPU E5-2650 v3 @ 2.30GHz

hi. I want to use the qzip hardware acceleration, after i install the driver, exec qzip and i get the error: # qzip -O 7z CentOS-8-x86_64-1905-dvd1.iso -o result.7z Error no hardware, switch to SW if permitted

driver install: # export ICP_ROOT=/home/hcitos/qat_driver; ./configure --enable-icp-sriov=host ;make -j install

qzip install # ./configure --with-ICP_ROOT=$ICP_ROOT ;make clean ; make ;make install

the dmesg get ther error: # dmesg -T | grep PF [Mon Jul 29 15:08:34 2024] c6xx 0000:0c:00.0: Cannot use PF with IOMMU enabled

after i disable iommu of host, and qzip can work well with using hardware acceleration. But i need to keep iommu on, Is there any other way to use hardware acceleration and not disable iommu .

yangni2017 commented 3 months ago

i wan to know whether qzip can use vf to hardware acceleration? whan can i do to config it.

XingHongChenIntel commented 3 months ago

hello,yangni, it seems you are using the OOT driver of QAT, it require the IOMMU disable. you could use the intree driver(qatlib) to solve this issue, QAT intree driver could use the VF of QAT HW. please refer to document
https://intel.github.io/quickassist/qatlib/qatzip.html https://intel.github.io/quickassist/qatlib/index.html https://intel.github.io/quickassist/qatlib/install.html

yangni2017 commented 3 months ago

QAT intree driver

hi,thank you very much for your help. but i install the qatlib follow the document,but my qat service can't start,and get the error:

Jul 30 15:34:37 TOS-10021 qat_init.sh[637454]: lspci: No PFs found, so assume qatlib is running on a VM
Jul 30 15:34:38 TOS-10021 qatmgr[638053]: No devices found
Jul 30 15:34:38 TOS-10021 qatmgr[638051]: No QAT device found

my card info as follow: image

my card seems not in The support list is mentioned in the documentation: https://github.com/intel/qatlib/blob/main/INSTALL https://github.com/intel/qatlib/issues/78 image

i can't get the pci info because my card is not 4xxx image

So, have any other ways?