Skip to content

Commit 8386207

Browse files
ebarilanMjoergroedel
authored andcommitted
iommu/amd: Fix argument order in amd_iommu_dev_flush_pasid_all()
An incorrect argument order calling amd_iommu_dev_flush_pasid_pages() causes improper flushing of the IOMMU, leaving the old value of GCR3 from a previous process attached to the same PASID. The function has the signature: void amd_iommu_dev_flush_pasid_pages(struct iommu_dev_data *dev_data, ioasid_t pasid, u64 address, size_t size) Correct the argument order. Cc: [email protected] Fixes: 474bf01 ("iommu/amd: Add support for device based TLB invalidation") Signed-off-by: Eliav Bar-ilan <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]> Reviewed-by: Vasant Hegde <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Joerg Roedel <[email protected]>
1 parent da3ea35 commit 8386207

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

drivers/iommu/amd/iommu.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1552,8 +1552,8 @@ void amd_iommu_dev_flush_pasid_pages(struct iommu_dev_data *dev_data,
15521552
void amd_iommu_dev_flush_pasid_all(struct iommu_dev_data *dev_data,
15531553
ioasid_t pasid)
15541554
{
1555-
amd_iommu_dev_flush_pasid_pages(dev_data, 0,
1556-
CMD_INV_IOMMU_ALL_PAGES_ADDRESS, pasid);
1555+
amd_iommu_dev_flush_pasid_pages(dev_data, pasid, 0,
1556+
CMD_INV_IOMMU_ALL_PAGES_ADDRESS);
15571557
}
15581558

15591559
void amd_iommu_domain_flush_complete(struct protection_domain *domain)

0 commit comments

Comments
 (0)