Skip to content

[RHEL9.1 BZ2100482] Revert dmaengine: idxd: Separate user and kernel pasid enabling

Jerry Snitselaar requested to merge jsnitsel/centos-stream-9:bz2100482 into main

Merge Request Required Information

Testing: Tested booting Sapphire Rapids with various intel_iommu options (no kernel parameter, intel_iommu=on, and intel_iommu=on,sm_on). For non-scalable mode cases I verified idxd legacy support functioned with dmatest, and with scalable-mode ran dsa_user_test_runner.sh.

Summary of Changes

The commit a13e10b7 ("dmaengine: idxd: Separate user and kernel pasid enabling"), made a change where iommu_sva_bind_device was now being called whether or not iommu_dev_feature_enable succeeded in enabling the SVA feature. This results in a null pointer deref in iommu_sva_bind_device if intel_iommu hasn't been enabled.

With looking further at the commit while trying to determine what the solution should be, I decided that there are potentially more issues with it, and until there is clarification and resolution of the issues upstream I am reverting it. This also pulls in a couple other commits that were fixing up some things, and fixes up an issue that was cleaned up in a merge commit by Linus.

Jerry Snitselaar (6):
      Revert "dmaengine: idxd: Separate user and kernel pasid enabling"
      dmaengine: idxd: fix device cleanup on disable
      dmaengine: idxd: add RO check for wq max_batch_size write
      dmaengine: idxd: add RO check for wq max_transfer_size write
      dmaengine: idxd: skip clearing device context when device is read-only
      dmaengine: idxd: Fixup upstream merge conflict resolution

Approved Bugzilla Ticket

All submissions to CentOS Stream must reference an approved ticket in Red Hat Bugzilla. Please follow the CentOS Stream contribution documentation for how to file this ticket and have it approved.

Bugzilla: https://bugzilla.redhat.com/2100482

Signed-off-by: Jerry Snitselaar jsnitsel@redhat.com

Edited by Jerry Snitselaar

Merge request reports