Re: [PATCH v4 2/5] iommu/vt-d: Remove the pasid present check in prq_event_thread

From: Baolu Lu
Date: Mon Oct 28 2024 - 04:23:54 EST


On 2024/10/28 15:50, Yi Liu wrote:
On 2024/10/16 05:08, Joel Granados wrote:
From: Klaus Jensen <k.jensen@xxxxxxxxxxx>

PASID is not strictly needed when handling a PRQ event; remove the check
for the pasid present bit in the request. This change was not included
in the creation of prq.c to emphasize the change in capability checks
when handing PRQ events.

Signed-off-by: Klaus Jensen <k.jensen@xxxxxxxxxxx>
Reviewed-by: Kevin Tian <kevin.tian@xxxxxxxxx>
Signed-off-by: Joel Granados <joel.granados@xxxxxxxxxx>

looks like the PRQ draining is missed for the PRI usage. When a pasid
entry is destroyed, it might need to add helper similar to the
intel_drain_pasid_prq() to drain PRQ for the non-pasid usage.

Perhaps we can move intel_drain_pasid_prq() into
intel_pasid_tear_down_entry(), indicating that once a translation is
removed from the pasid and PRI is enabled on the device, the page
requests for the pasid should be flushed.

Thanks,
baolu