Skip to content

Commit bb20881

Browse files
XinIZengawilliam
authored andcommitted
vfio/qat: Add vfio_pci driver for Intel QAT SR-IOV VF devices
Add vfio pci variant driver for Intel QAT SR-IOV VF devices. This driver registers to the vfio subsystem through the interfaces exposed by the subsystem. It follows the live migration protocol v2 defined in uapi/linux/vfio.h and interacts with Intel QAT PF driver through a set of interfaces defined in qat/qat_mig_dev.h to support live migration of Intel QAT VF devices. This version only covers migration for Intel QAT GEN4 VF devices. Co-developed-by: Yahui Cao <[email protected]> Signed-off-by: Yahui Cao <[email protected]> Signed-off-by: Xin Zeng <[email protected]> Reviewed-by: Giovanni Cabiddu <[email protected]> Reviewed-by: Kevin Tian <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Alex Williamson <[email protected]>
1 parent 4fefd69 commit bb20881

File tree

6 files changed

+729
-0
lines changed

6 files changed

+729
-0
lines changed

MAINTAINERS

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23280,6 +23280,14 @@ L: [email protected]
2328023280
S: Maintained
2328123281
F: drivers/vfio/platform/
2328223282

23283+
VFIO QAT PCI DRIVER
23284+
M: Xin Zeng <[email protected]>
23285+
M: Giovanni Cabiddu <[email protected]>
23286+
23287+
23288+
S: Supported
23289+
F: drivers/vfio/pci/qat/
23290+
2328323291
VFIO VIRTIO PCI DRIVER
2328423292
M: Yishai Hadas <[email protected]>
2328523293

drivers/vfio/pci/Kconfig

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,4 +69,6 @@ source "drivers/vfio/pci/virtio/Kconfig"
6969

7070
source "drivers/vfio/pci/nvgrace-gpu/Kconfig"
7171

72+
source "drivers/vfio/pci/qat/Kconfig"
73+
7274
endmenu

drivers/vfio/pci/Makefile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,3 +17,5 @@ obj-$(CONFIG_PDS_VFIO_PCI) += pds/
1717
obj-$(CONFIG_VIRTIO_VFIO_PCI) += virtio/
1818

1919
obj-$(CONFIG_NVGRACE_GPU_VFIO_PCI) += nvgrace-gpu/
20+
21+
obj-$(CONFIG_QAT_VFIO_PCI) += qat/

drivers/vfio/pci/qat/Kconfig

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# SPDX-License-Identifier: GPL-2.0-only
2+
config QAT_VFIO_PCI
3+
tristate "VFIO support for QAT VF PCI devices"
4+
select VFIO_PCI_CORE
5+
depends on CRYPTO_DEV_QAT_4XXX
6+
help
7+
This provides migration support for Intel(R) QAT Virtual Function
8+
using the VFIO framework.
9+
10+
To compile this as a module, choose M here: the module
11+
will be called qat_vfio_pci. If you don't know what to do here,
12+
say N.

drivers/vfio/pci/qat/Makefile

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# SPDX-License-Identifier: GPL-2.0-only
2+
obj-$(CONFIG_QAT_VFIO_PCI) += qat_vfio_pci.o
3+
qat_vfio_pci-y := main.o

0 commit comments

Comments
 (0)