linux-stable/drivers
Lucas Segarra Fernandez 7ce515e636 crypto: qat - add qat_zlib_deflate
The ZLIB format (RFC 1950) is made of deflate compressed data surrounded
by a header and a footer. The QAT accelerators support only the deflate
algorithm, therefore the header and the footer need to be inserted in
software.

This adds logic in the QAT driver to support the ZLIB format. In
particular:
  * Generalize the function qat_comp_alg_compress_decompress() to allow
    skipping an initial region (header) of the source and/or destination
    scatter lists.
  * Add logic to register the qat_zlib_deflate algorithm into the acomp
    framework.
  * For ZLIB compression, skip the initial portion of the destination
    buffer before sending the job to the QAT accelerator and insert the
    ZLIB header and footer in the callback, after the QAT request has
    been processed.
  * For ZLIB decompression, parse the header in the input buffer
    provided by the user and verify its validity before attempting the
    decompression of the buffer with QAT. Then submit the buffer to QAT
    for decompression. In the callback verify the correctness of the
    footer by comparing the value of the ADLER produced by QAT with the
    one in the destination buffer.

Signed-off-by: Lucas Segarra Fernandez <lucas.segarra.fernandez@intel.com>
Reviewed-by: Giovanni Cabiddu <giovanni.cabiddu@intel.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
2023-02-03 12:54:54 +08:00
..
accel Fix mismerge due to devnode now taking a 'const *' device 2022-12-16 13:04:15 -06:00
accessibility
acpi treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
amba
android
ata
atm treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
auxdisplay
base Kbuild updates for v6.2 2022-12-19 12:33:32 -06:00
bcma
block treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
bluetooth treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
bus
cdrom
char hwrng: starfive - Add TRNG driver for StarFive SoC 2023-01-27 18:58:09 +08:00
clk
clocksource
comedi
connector
counter
cpufreq
cpuidle powerpc updates for 6.2 2022-12-19 07:13:33 -06:00
crypto crypto: qat - add qat_zlib_deflate 2023-02-03 12:54:54 +08:00
cxl
dax
dca
devfreq
dio
dma dmaengine updates for v6.2 2022-12-19 08:54:17 -06:00
dma-buf
edac
eisa
extcon
firewire
firmware remoteproc updates for v6.2 2022-12-21 09:37:14 -08:00
fpga
fsi
gnss
gpio pwm: Changes for v6.2-rc1 2022-12-21 09:41:28 -08:00
gpu treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
greybus
hid treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
hsi
hte
hv
hwmon
hwspinlock
hwtracing
i2c
i3c
idle
iio
infiniband v6.2 merge window 2nd pull request 2022-12-17 08:23:42 -06:00
input treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
interconnect
iommu IOMMU Updates for Linux v6.2 2022-12-19 08:34:39 -06:00
ipack
irqchip
isdn treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
leds treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
macintosh
mailbox - qcom: enable sc8280xp, sm8550 and sm4250 support 2022-12-21 09:31:18 -08:00
mcb
md
media treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
memory
memstick
message
mfd - New Drivers 2022-12-21 09:19:24 -08:00
misc kernel hardening fixes for v6.2-rc1 2022-12-23 12:00:24 -08:00
mmc
most
mtd
mux
net treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
nfc treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
ntb
nubus
nvdimm
nvme SCSI misc on 20221222 2022-12-22 11:22:31 -08:00
nvmem
of Devicetree updates for v6.2, part 2: 2022-12-20 08:48:24 -06:00
opp
parisc parisc: led: Fix potential null-ptr-deref in start_task() 2022-12-17 23:19:38 +01:00
parport
pci phy-for-6.2 2022-12-19 08:40:58 -06:00
pcmcia treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
peci
perf
phy phy-for-6.2 2022-12-19 08:40:58 -06:00
pinctrl
platform
pnp
power power supply and reset changes for the v6.2 series 2022-12-17 08:39:31 -06:00
powercap
pps
ps3
ptp
pwm pwm: Changes for v6.2-rc1 2022-12-21 09:41:28 -08:00
rapidio
ras
regulator regulator: Fixes for v6.2 2022-12-23 14:38:00 -08:00
remoteproc
reset
rpmsg
rtc - New Drivers 2022-12-21 09:19:24 -08:00
s390
sbus
scsi treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
sh
siox
slimbus
soc ARM: SoC fixes for 6.2 2022-12-19 16:07:59 -06:00
soundwire soundwire updates for 6.2 2022-12-19 08:47:33 -06:00
spi spi: Fix for v6.2 2022-12-23 14:44:08 -08:00
spmi
ssb
staging treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
target
tc
tee
thermal
thunderbolt
tty treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
ufs
uio
usb treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
vdpa
vfio
vhost
video - Fix-ups 2022-12-21 09:24:39 -08:00
virt
virtio
vlynq
w1
watchdog linux-watchdog 6.2-rc1 tag 2022-12-17 08:34:01 -06:00
xen
zorro
Kconfig
Makefile