+49
−24
+3
−0
+13
−2
Loading
If the kernel is booted with the IOMMU enabled and Shared Memory mode enabled (which are the expected boot parameters for production servers), then the kernel idxd driver will automatically register a dedicated work queue with the PASID for the process that opens it. This means that the descriptors written into the portal for that work queue should be *virtual* addresses. If the IOMMU is enabled but Shared Memory mode is disabled, then the kernel has registered the device with the IOMMU and assigned it I/O virtual addresses. We have no way to get those addresses from user space, so we cannot use the kernel driver in this mode. Add a check to catch that. If the IOMMU is disabled, then physical addresses are used everywherre. Change-Id: I0bf079835ad4df1128ef9db54f5564050327e9f7 Signed-off-by:Ben Walker <benjamin.walker@intel.com> Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/14019 Tested-by:
SPDK CI Jenkins <sys_sgci@intel.com> Community-CI: Mellanox Build Bot Reviewed-by:
Jim Harris <james.r.harris@intel.com> Reviewed-by:
Paul Luse <paul.e.luse@intel.com> Reviewed-by:
Konrad Sztyber <konrad.sztyber@intel.com>