]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
crypto: qat - allow enabling VFs in the absence of IOMMU
authorAhsan Atta <ahsan.atta@intel.com>
Wed, 4 Jun 2025 08:23:43 +0000 (09:23 +0100)
committerHerbert Xu <herbert@gondor.apana.org.au>
Fri, 13 Jun 2025 09:26:17 +0000 (17:26 +0800)
The commit ca88a2bdd4dd ("crypto: qat - allow disabling SR-IOV VFs")
introduced an unnecessary change that prevented enabling SR-IOV when
IOMMU is disabled. In certain scenarios, it is desirable to enable
SR-IOV even in the absence of IOMMU. Thus, restoring the previous
functionality to allow VFs to be enumerated in the absence of IOMMU.

Fixes: ca88a2bdd4dd ("crypto: qat - allow disabling SR-IOV VFs")
Signed-off-by: Ahsan Atta <ahsan.atta@intel.com>
Reviewed-by: Giovanni Cabiddu <giovanni.cabiddu@intel.com>
Reviewed-by: Michal Witwicki <michal.witwicki@intel.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/intel/qat/qat_common/adf_sriov.c

index c75d0b6cb0ada395f340db2f3dda71995496f421..31d1ef0cb1f52e1e672e3e6adb269e918bb78efa 100644 (file)
@@ -155,7 +155,6 @@ static int adf_do_enable_sriov(struct adf_accel_dev *accel_dev)
        if (!device_iommu_mapped(&GET_DEV(accel_dev))) {
                dev_warn(&GET_DEV(accel_dev),
                         "IOMMU should be enabled for SR-IOV to work correctly\n");
-               return -EINVAL;
        }
 
        if (adf_dev_started(accel_dev)) {