lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Thu, 13 Jul 2023 07:49:53 +0000
From:   "Tian, Kevin" <kevin.tian@...el.com>
To:     Jacob Pan <jacob.jun.pan@...ux.intel.com>,
        LKML <linux-kernel@...r.kernel.org>,
        "iommu@...ts.linux.dev" <iommu@...ts.linux.dev>,
        Lu Baolu <baolu.lu@...ux.intel.com>,
        Joerg Roedel <joro@...tes.org>,
        Jean-Philippe Brucker <jean-philippe@...aro.com>,
        "Robin Murphy" <robin.murphy@....com>
CC:     Jason Gunthorpe <jgg@...dia.com>, Will Deacon <will@...nel.org>,
        "Liu, Yi L" <yi.l.liu@...el.com>,
        "Yu, Fenghua" <fenghua.yu@...el.com>,
        "Luck, Tony" <tony.luck@...el.com>
Subject: RE: [PATCH v10 5/7] iommu/vt-d: Make prq draining code generic

> From: Jacob Pan <jacob.jun.pan@...ux.intel.com>
> Sent: Thursday, July 13, 2023 12:34 AM
> 
> -	/* Domain type specific cleanup: */
>  	domain = iommu_get_domain_for_dev_pasid(dev, pasid, 0);
> -	if (domain) {
> -		switch (domain->type) {
> -		case IOMMU_DOMAIN_SVA:
> -			intel_svm_remove_dev_pasid(dev, pasid);
> -			break;
> -		default:
> -			/* should never reach here */
> -			WARN_ON(1);
> -			break;
> -		}
> +	if (!domain)
> +		goto out_tear_down;

WARN_ON()

>  		 * large and has to be physically contiguous. So it's
>  		 * hard to be as defensive as we might like.
>  		 */
> -		intel_pasid_tear_down_entry(iommu, dev, svm->pasid,
> false);
> -		intel_svm_drain_prq(dev, svm->pasid);

after removing the 2 lines the comment above becomes stale.

> -static void intel_svm_drain_prq(struct device *dev, u32 pasid)
> +void intel_drain_pasid_prq(struct device *dev, u32 pasid)
>  {
>  	struct device_domain_info *info;
>  	struct dmar_domain *domain;

later we should move generic prq handling logic out of svm.c into
a new prq.c

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ