[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20221203005610.2927487-1-jacob.jun.pan@linux.intel.com>
Date: Fri, 2 Dec 2022 16:56:10 -0800
From: Jacob Pan <jacob.jun.pan@...ux.intel.com>
To: iommu@...ts.linux.dev, LKML <linux-kernel@...r.kernel.org>,
"Lu Baolu" <baolu.lu@...ux.intel.com>,
Joerg Roedel <joro@...tes.org>,
David Woodhouse <dwmw2@...radead.org>,
"Robin Murphy" <robin.murphy@....com>,
"Will Deacon" <will@...nel.org>
Cc: Yi Liu <yi.l.liu@...el.com>, "Tian, Kevin" <kevin.tian@...el.com>,
Raj Ashok <ashok.raj@...el.com>,
Jacob Pan <jacob.jun.pan@...ux.intel.com>,
Raghunathan Srinivasan <raghunathan.srinivasan@...el.com>
Subject: [PATCH] iommu/vt-d: Fix buggy QAT device mask
Impacted QAT device IDs that need extra dtlb flush quirk is ranging
from 0x4940 to 0x4943. After bitwise AND device ID with 0xfffc the
result should be 0x4940 instead of 0x494c to identify these devices.
Reported-by: Raghunathan Srinivasan <raghunathan.srinivasan@...el.com>
Signed-off-by: Jacob Pan <jacob.jun.pan@...ux.intel.com>
---
drivers/iommu/intel/iommu.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/iommu/intel/iommu.c b/drivers/iommu/intel/iommu.c
index d8759f445aff..0b10104c4b99 100644
--- a/drivers/iommu/intel/iommu.c
+++ b/drivers/iommu/intel/iommu.c
@@ -1401,7 +1401,7 @@ static void domain_update_iotlb(struct dmar_domain *domain)
* This quirk is exempted from risky_device() check because it applies only
* to the built-in QAT devices and it doesn't grant additional privileges.
*/
-#define BUGGY_QAT_DEVID_MASK 0x494c
+#define BUGGY_QAT_DEVID_MASK 0x4940
static bool dev_needs_extra_dtlb_flush(struct pci_dev *pdev)
{
if (pdev->vendor != PCI_VENDOR_ID_INTEL)
--
2.25.1
Powered by blists - more mailing lists