iommu/amd: Wait for completion of IOTLB flush in attach_device
authorFilippo Sironi <sironi@amazon.de>
Tue, 10 Sep 2019 17:49:21 +0000 (19:49 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 29 Jan 2020 09:24:32 +0000 (10:24 +0100)
commita9e0dcfe6b194dc5fd5703da91e0fd383419f234
treead066a39e18b9f9ac951fecb6a0e23d76b3d057c
parentcfae028fd3a9266f50fd39a0745b36d1a690af7d
iommu/amd: Wait for completion of IOTLB flush in attach_device

[ Upstream commit 0b15e02f0cc4fb34a9160de7ba6db3a4013dc1b7 ]

To make sure the domain tlb flush completes before the
function returns, explicitly wait for its completion.

Signed-off-by: Filippo Sironi <sironi@amazon.de>
Fixes: 42a49f965a8d ("amd-iommu: flush domain tlb when attaching a new device")
[joro: Added commit message and fixes tag]
Signed-off-by: Joerg Roedel <jroedel@suse.de>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/iommu/amd_iommu.c