Re: [PATCH v3 4/5] iommu/hyperv: Add para-virtualized IOMMU support for Hyper-V guest

Jason Gunthorpe <[email protected]> Thu, 13 Aug 2026 10:49:36 -0300
Newsgroups org.kernel.vger.linux-hyperv,dev.linux.lists.iommu,org.kernel.vger.linux-arch,org.kernel.vger.linux-kernel,org.kernel.vger.linux-pci
Message-ID <[email protected]>
On Tue, Aug 11, 2026 at 11:50:20PM +0800, Yu Zhang wrote:

> +static void hv_iommu_release_device(struct device *dev)
> +{
> +	struct hv_iommu_endpoint *vdev = dev_iommu_priv_get(dev);
> +	struct pci_dev *pdev = to_pci_dev(dev);
> +
> +	if (pdev->ats_enabled)
> +		pci_disable_ats(pdev);

Since attaching blocking does this and you set blocking as your
release domain, this is redundant.

The new flow looks alot better, removing the detach operation entirely
makes sense if the HV can support attach on attach

Jason