提交 fab6afa3 编写于 作者: J Joerg Roedel

amd-iommu: drop pointless iommu-loop in msi setup code

It is not necessary to loop again over all IOMMUs in this code. So drop
the loop.
Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
上级 58492e12
......@@ -826,13 +826,6 @@ static int __init iommu_setup_msix(struct amd_iommu *iommu)
static int __init iommu_setup_msi(struct amd_iommu *iommu)
{
int r;
struct amd_iommu *curr;
for_each_iommu(curr) {
if (curr->dev == iommu->dev)
curr->int_enabled = true;
}
if (pci_enable_msi(iommu->dev))
return 1;
......@@ -847,6 +840,7 @@ static int __init iommu_setup_msi(struct amd_iommu *iommu)
return 1;
}
iommu->int_enabled = true;
iommu_feature_enable(iommu, CONTROL_EVT_INT_EN);
return 0;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册