Skip to content

Commit 4402e8f

Browse files
LuBaolujoergroedel
authored andcommitted
iommu/vt-d: Remove LPIG from page group response descriptor
Bit 66 in the page group response descriptor used to be the LPIG (Last Page in Group), but it was marked as Reserved since Specification 4.0. Remove programming on this bit to make it consistent with the latest specification. Existing hardware all treats bit 66 of the page group response descriptor as "ignored", therefore this change doesn't break any existing hardware. Signed-off-by: Lu Baolu <baolu.lu@linux.intel.com> Link: https://lore.kernel.org/r/20250901053943.1708490-1-baolu.lu@linux.intel.com Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
1 parent 4c48101 commit 4402e8f

2 files changed

Lines changed: 2 additions & 6 deletions

File tree

drivers/iommu/intel/iommu.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -460,7 +460,6 @@ enum {
460460
#define QI_PGRP_PASID(pasid) (((u64)(pasid)) << 32)
461461

462462
/* Page group response descriptor QW1 */
463-
#define QI_PGRP_LPIG(x) (((u64)(x)) << 2)
464463
#define QI_PGRP_IDX(idx) (((u64)(idx)) << 3)
465464

466465

drivers/iommu/intel/prq.c

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -151,8 +151,7 @@ static void handle_bad_prq_event(struct intel_iommu *iommu,
151151
QI_PGRP_PASID_P(req->pasid_present) |
152152
QI_PGRP_RESP_CODE(result) |
153153
QI_PGRP_RESP_TYPE;
154-
desc.qw1 = QI_PGRP_IDX(req->prg_index) |
155-
QI_PGRP_LPIG(req->lpig);
154+
desc.qw1 = QI_PGRP_IDX(req->prg_index);
156155

157156
qi_submit_sync(iommu, &desc, 1, 0);
158157
}
@@ -379,19 +378,17 @@ void intel_iommu_page_response(struct device *dev, struct iopf_fault *evt,
379378
struct iommu_fault_page_request *prm;
380379
struct qi_desc desc;
381380
bool pasid_present;
382-
bool last_page;
383381
u16 sid;
384382

385383
prm = &evt->fault.prm;
386384
sid = PCI_DEVID(bus, devfn);
387385
pasid_present = prm->flags & IOMMU_FAULT_PAGE_REQUEST_PASID_VALID;
388-
last_page = prm->flags & IOMMU_FAULT_PAGE_REQUEST_LAST_PAGE;
389386

390387
desc.qw0 = QI_PGRP_PASID(prm->pasid) | QI_PGRP_DID(sid) |
391388
QI_PGRP_PASID_P(pasid_present) |
392389
QI_PGRP_RESP_CODE(msg->code) |
393390
QI_PGRP_RESP_TYPE;
394-
desc.qw1 = QI_PGRP_IDX(prm->grpid) | QI_PGRP_LPIG(last_page);
391+
desc.qw1 = QI_PGRP_IDX(prm->grpid);
395392
desc.qw2 = 0;
396393
desc.qw3 = 0;
397394

0 commit comments

Comments
 (0)