From 25fbe6525b00a5175ec1d2343a3dccff49ab0900 Mon Sep 17 00:00:00 2001 From: zouxiaoh Date: Wed, 23 Feb 2022 10:21:25 +0800 Subject: [PATCH] UBUNTU: SAUCE: iommu: intel-ipu: use IOMMU passthrough mode for Intel IPUs on Raptor Lake BugLink: https://bugs.launchpad.net/bugs/1989041 Intel IPU(Image Processing Unit) has its own (IO)MMU hardware, The IPU driver allocates its own page table that is not mapped via the DMA, and thus the Intel IOMMU driver blocks access giving this error: DMAR: DRHD: handling fault status reg 3 DMAR: [DMA Read] Request device [00:05.0] PASID ffffffff fault addr 76406000 [fault reason 06] PTE Read access is not set As IPU is not an external facing device which is not risky, so use IOMMU passthrough mode for Intel IPUs. (backported from https://github.com/intel/ipu6-drivers/blob/89c6b99e4bec00a04b53f37cd8c3c01ce824a4ab/patch/IOMMU-passthrough-for-intel-ipu.diff) Signed-off-by: You-Sheng Yang Signed-off-by: Andrea Righi --- drivers/iommu/intel/iommu.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/iommu/intel/iommu.c b/drivers/iommu/intel/iommu.c index a1a793223148..a1a9aeb43a88 100644 --- a/drivers/iommu/intel/iommu.c +++ b/drivers/iommu/intel/iommu.c @@ -39,7 +39,8 @@ #define IS_USB_DEVICE(pdev) ((pdev->class >> 8) == PCI_CLASS_SERIAL_USB) #define IS_ISA_DEVICE(pdev) ((pdev->class >> 8) == PCI_CLASS_BRIDGE_ISA) #define IS_INTEL_IPU(pdev) ((pdev)->vendor == PCI_VENDOR_ID_INTEL && \ - ((pdev)->device == 0x9a19 || \ + ((pdev)->device == 0xa75d || \ + (pdev)->device == 0x9a19 || \ (pdev)->device == 0x9a39 || \ (pdev)->device == 0x4e19 || \ (pdev)->device == 0x465d || \