Skip to content

Commit 03d2050

Browse files
LuBaolujoergroedel
authored andcommitted
iommu/vt-d: Report the right page fault address
The Address field of the Page Request Descriptor only keeps bit [63:12] of the offending address. Convert it to a full address before reporting it to device drivers. Fixes: eb8d93e ("iommu/vt-d: Report page request faults for guest SVA") Signed-off-by: Lu Baolu <baolu.lu@linux.intel.com> Link: https://lore.kernel.org/r/20210320025415.641201-2-baolu.lu@linux.intel.com Signed-off-by: Joerg Roedel <jroedel@suse.de>
1 parent 6c00612 commit 03d2050

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/iommu/intel/svm.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -852,7 +852,7 @@ intel_svm_prq_report(struct device *dev, struct page_req_dsc *desc)
852852
/* Fill in event data for device specific processing */
853853
memset(&event, 0, sizeof(struct iommu_fault_event));
854854
event.fault.type = IOMMU_FAULT_PAGE_REQ;
855-
event.fault.prm.addr = desc->addr;
855+
event.fault.prm.addr = (u64)desc->addr << VTD_PAGE_SHIFT;
856856
event.fault.prm.pasid = desc->pasid;
857857
event.fault.prm.grpid = desc->prg_index;
858858
event.fault.prm.perm = prq_to_iommu_prot(desc);

0 commit comments

Comments
 (0)