Skip to content

Commit

Permalink
amd-iommu: drop pointless iommu-loop in msi setup code
Browse files Browse the repository at this point in the history
It is not necessary to loop again over all IOMMUs in this code. So drop
the loop.

Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
  • Loading branch information
Joerg Roedel committed May 28, 2009
1 parent 58492e1 commit fab6afa
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions arch/x86/kernel/amd_iommu_init.c
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand All @@ -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;
Expand Down

0 comments on commit fab6afa

Please sign in to comment.