QEMU, KVM and VFIO-PCI work together to passthrough HW to virtual machine.
Passthrough means virtual machine can directly access HW, no other software between virtual machine and HW.
There are two pathes from virtual machine to HW. One is DMA access HW, another is CPU access HW.
For DMA accessing, VFIO driver will setup the GPA to HPA mapping on IOMMU.
For CPU accessing, KVM will setup the GPA to HPA mapping on EPT(X86).